diff --git a/.gitignore b/.gitignore
index 838d9c1..9c0185e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -41,4 +41,3 @@ yarn-error.log
/.opencode
/build.sh
/.junie
-/.agents
diff --git a/Dockerfile b/Dockerfile
index 5af7b33..2d761ed 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -18,7 +18,7 @@ ENV TRMNL_LIQUID_ENABLED=1
# Switch to the root user so we can do root things
USER root
-COPY --chown=www-data:www-data --from=bnussbau/trmnl-liquid-cli:0.2.0 /usr/local/bin/trmnl-liquid-cli /usr/local/bin/
+COPY --chown=www-data:www-data --from=bnussbau/trmnl-liquid-cli:0.1.0 /usr/local/bin/trmnl-liquid-cli /usr/local/bin/
# Set the working directory
WORKDIR /var/www/html
diff --git a/README.md b/README.md
index 670b62c..2231b24 100644
--- a/README.md
+++ b/README.md
@@ -122,7 +122,6 @@ php artisan db:seed --class=ExampleRecipesSeeder
| `REGISTRATION_ENABLED` | Allow user registration via Webinterface | 1 |
| `SSL_MODE` | SSL Mode, if not using a Reverse Proxy ([docs](https://serversideup.net/open-source/docker-php/docs/customizing-the-image/configuring-ssl)) | `off` |
| `FORCE_HTTPS` | If your server handles SSL termination, enforce HTTPS. | 0 |
-| `TRUSTED_PROXIES` | If your server handles SSL termination, allow mixed mode. e.g. `"172.0.0.0/8"` or `*` | null |
| `PHP_OPCACHE_ENABLE` | Enable PHP Opcache | 0 |
| `TRMNL_IMAGE_URL_TIMEOUT` | How long TRMNL waits for a response on the display endpoint. (sec) | 30 |
| `APP_TIMEZONE` | Default timezone, which will be used by the PHP date functions | UTC |
diff --git a/app/Models/Plugin.php b/app/Models/Plugin.php
index 5eeeb6b..bc46559 100644
--- a/app/Models/Plugin.php
+++ b/app/Models/Plugin.php
@@ -60,14 +60,8 @@ class Plugin extends Model
});
static::updating(function ($model): void {
- // Reset image cache when any markup changes
- if ($model->isDirty([
- 'render_markup',
- 'render_markup_half_horizontal',
- 'render_markup_half_vertical',
- 'render_markup_quadrant',
- 'render_markup_shared',
- ])) {
+ // Reset image cache when markup changes
+ if ($model->isDirty('render_markup')) {
$model->current_image = null;
}
});
@@ -427,9 +421,7 @@ class Plugin extends Model
throw new InvalidArgumentException('Render method is only applicable for recipe plugins.');
}
- $markup = $this->getMarkupForSize($size);
-
- if ($markup) {
+ if ($this->render_markup) {
$renderedContent = '';
if ($this->markup_language === 'liquid') {
@@ -479,7 +471,7 @@ class Plugin extends Model
// Check if external renderer should be used
if ($this->preferred_renderer === 'trmnl-liquid' && config('services.trmnl.liquid_enabled')) {
// Use external Ruby renderer - pass raw template without preprocessing
- $renderedContent = $this->renderWithExternalLiquidRenderer($markup, $context);
+ $renderedContent = $this->renderWithExternalLiquidRenderer($this->render_markup, $context);
} else {
// Use PHP keepsuit/liquid renderer
// Create a custom environment with inline templates support
@@ -501,14 +493,14 @@ class Plugin extends Model
$environment->tagRegistry->register(TemplateTag::class);
// Apply Liquid replacements (including 'with' syntax conversion)
- $processedMarkup = $this->applyLiquidReplacements($markup);
+ $processedMarkup = $this->applyLiquidReplacements($this->render_markup);
$template = $environment->parseString($processedMarkup);
$liquidContext = $environment->newRenderContext(data: $context);
$renderedContent = $template->render($liquidContext);
}
} else {
- $renderedContent = Blade::render($markup, [
+ $renderedContent = Blade::render($this->render_markup, [
'size' => $size,
'data' => $this->data_payload,
'config' => $this->configuration ?? [],
@@ -589,30 +581,6 @@ class Plugin extends Model
return $this->configuration[$key] ?? $default;
}
- /**
- * Get the appropriate markup for a given size, including shared prepending logic
- *
- * @param string $size The layout size (full, half_horizontal, half_vertical, quadrant)
- * @return string|null The markup code for the given size, with shared prepended if available
- */
- public function getMarkupForSize(string $size): ?string
- {
- $markup = match ($size) {
- 'full' => $this->render_markup,
- 'half_horizontal' => $this->render_markup_half_horizontal ?? $this->render_markup,
- 'half_vertical' => $this->render_markup_half_vertical ?? $this->render_markup,
- 'quadrant' => $this->render_markup_quadrant ?? $this->render_markup,
- default => $this->render_markup,
- };
-
- // Prepend shared markup if it exists
- if ($markup && $this->render_markup_shared) {
- $markup = $this->render_markup_shared."\n".$markup;
- }
-
- return $markup;
- }
-
public function getPreviewMashupLayoutForSize(string $size): string
{
return match ($size) {
diff --git a/app/Services/PluginExportService.php b/app/Services/PluginExportService.php
index be98461..241764d 100644
--- a/app/Services/PluginExportService.php
+++ b/app/Services/PluginExportService.php
@@ -51,35 +51,17 @@ class PluginExportService
$settings = $this->generateSettingsYaml($plugin);
$settingsYaml = Yaml::dump($settings, 10, 2, Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK);
File::put($tempDir.'/settings.yml', $settingsYaml);
-
+ // Generate full template content
+ $fullTemplate = $this->generateFullTemplate($plugin);
$extension = $plugin->markup_language === 'liquid' ? 'liquid' : 'blade.php';
-
- // Export full template if it exists
- if ($plugin->render_markup) {
- $fullTemplate = $this->generateLayoutTemplate($plugin->render_markup);
- File::put($tempDir.'/full.'.$extension, $fullTemplate);
- }
-
- // Export layout-specific templates if they exist
- if ($plugin->render_markup_half_horizontal) {
- $halfHorizontalTemplate = $this->generateLayoutTemplate($plugin->render_markup_half_horizontal);
- File::put($tempDir.'/half_horizontal.'.$extension, $halfHorizontalTemplate);
- }
-
- if ($plugin->render_markup_half_vertical) {
- $halfVerticalTemplate = $this->generateLayoutTemplate($plugin->render_markup_half_vertical);
- File::put($tempDir.'/half_vertical.'.$extension, $halfVerticalTemplate);
- }
-
- if ($plugin->render_markup_quadrant) {
- $quadrantTemplate = $this->generateLayoutTemplate($plugin->render_markup_quadrant);
- File::put($tempDir.'/quadrant.'.$extension, $quadrantTemplate);
- }
-
- // Export shared template if it exists
- if ($plugin->render_markup_shared) {
- $sharedTemplate = $this->generateLayoutTemplate($plugin->render_markup_shared);
- File::put($tempDir.'/shared.'.$extension, $sharedTemplate);
+ File::put($tempDir.'/full.'.$extension, $fullTemplate);
+ // Generate shared.liquid if needed (for liquid templates)
+ if ($plugin->markup_language === 'liquid') {
+ $sharedTemplate = $this->generateSharedTemplate();
+ /** @phpstan-ignore-next-line */
+ if ($sharedTemplate) {
+ File::put($tempDir.'/shared.liquid', $sharedTemplate);
+ }
}
// Create ZIP file
$zipPath = $tempDir.'/plugin_'.$plugin->trmnlp_id.'.zip';
@@ -142,21 +124,29 @@ class PluginExportService
}
/**
- * Generate template content from markup, removing wrapper divs if present
+ * Generate the full template content
*/
- private function generateLayoutTemplate(?string $markup): string
+ private function generateFullTemplate(Plugin $plugin): string
{
- if (! $markup) {
- return '';
- }
+ $markup = $plugin->render_markup;
- // Remove the wrapper div if it exists (it will be added during import for liquid)
+ // Remove the wrapper div if it exists (it will be added during import)
$markup = preg_replace('/^
\s*/', '', $markup);
$markup = preg_replace('/\s*<\/div>\s*$/', '', $markup);
return mb_trim($markup);
}
+ /**
+ * Generate the shared template content (for liquid templates)
+ */
+ private function generateSharedTemplate(): null
+ {
+ // For now, we don't have a way to store shared templates separately
+ // TODO - add support for shared templates
+ return null;
+ }
+
/**
* Add a directory and its contents to a ZIP file
*/
diff --git a/app/Services/PluginImportService.php b/app/Services/PluginImportService.php
index f3e7a5c..51a9aee 100644
--- a/app/Services/PluginImportService.php
+++ b/app/Services/PluginImportService.php
@@ -93,59 +93,37 @@ class PluginImportService
$settings = Yaml::parse($settingsYaml);
$this->validateYAML($settings);
- // Determine markup language from the first available file
+ // Determine which template file to use and read its content
+ $templatePath = null;
$markupLanguage = 'blade';
- $firstTemplatePath = $filePaths['fullLiquidPath']
- ?? ($filePaths['halfHorizontalLiquidPath'] ?? null)
- ?? ($filePaths['halfVerticalLiquidPath'] ?? null)
- ?? ($filePaths['quadrantLiquidPath'] ?? null)
- ?? ($filePaths['sharedLiquidPath'] ?? null)
- ?? ($filePaths['sharedBladePath'] ?? null);
- if ($firstTemplatePath && pathinfo((string) $firstTemplatePath, PATHINFO_EXTENSION) === 'liquid') {
- $markupLanguage = 'liquid';
- }
+ if ($filePaths['fullLiquidPath']) {
+ $templatePath = $filePaths['fullLiquidPath'];
+ $fullLiquid = File::get($templatePath);
- // Read full markup (don't prepend shared - it will be prepended at render time)
- $fullLiquid = null;
- if (isset($filePaths['fullLiquidPath']) && $filePaths['fullLiquidPath']) {
- $fullLiquid = File::get($filePaths['fullLiquidPath']);
- if ($markupLanguage === 'liquid') {
+ // Prepend shared.liquid or shared.blade.php content if available
+ if ($filePaths['sharedLiquidPath'] && File::exists($filePaths['sharedLiquidPath'])) {
+ $sharedLiquid = File::get($filePaths['sharedLiquidPath']);
+ $fullLiquid = $sharedLiquid."\n".$fullLiquid;
+ } elseif ($filePaths['sharedBladePath'] && File::exists($filePaths['sharedBladePath'])) {
+ $sharedBlade = File::get($filePaths['sharedBladePath']);
+ $fullLiquid = $sharedBlade."\n".$fullLiquid;
+ }
+
+ // Check if the file ends with .liquid to set markup language
+ if (pathinfo((string) $templatePath, PATHINFO_EXTENSION) === 'liquid') {
+ $markupLanguage = 'liquid';
$fullLiquid = '
'."\n".$fullLiquid."\n".'
';
}
- }
-
- // Read shared markup separately
- $sharedMarkup = null;
- if (isset($filePaths['sharedLiquidPath']) && $filePaths['sharedLiquidPath'] && File::exists($filePaths['sharedLiquidPath'])) {
- $sharedMarkup = File::get($filePaths['sharedLiquidPath']);
- } elseif (isset($filePaths['sharedBladePath']) && $filePaths['sharedBladePath'] && File::exists($filePaths['sharedBladePath'])) {
- $sharedMarkup = File::get($filePaths['sharedBladePath']);
- }
-
- // Read layout-specific markups
- $halfHorizontalMarkup = null;
- if (isset($filePaths['halfHorizontalLiquidPath']) && $filePaths['halfHorizontalLiquidPath'] && File::exists($filePaths['halfHorizontalLiquidPath'])) {
- $halfHorizontalMarkup = File::get($filePaths['halfHorizontalLiquidPath']);
- if ($markupLanguage === 'liquid') {
- $halfHorizontalMarkup = '
'."\n".$halfHorizontalMarkup."\n".'
';
- }
- }
-
- $halfVerticalMarkup = null;
- if (isset($filePaths['halfVerticalLiquidPath']) && $filePaths['halfVerticalLiquidPath'] && File::exists($filePaths['halfVerticalLiquidPath'])) {
- $halfVerticalMarkup = File::get($filePaths['halfVerticalLiquidPath']);
- if ($markupLanguage === 'liquid') {
- $halfVerticalMarkup = '
'."\n".$halfVerticalMarkup."\n".'
';
- }
- }
-
- $quadrantMarkup = null;
- if (isset($filePaths['quadrantLiquidPath']) && $filePaths['quadrantLiquidPath'] && File::exists($filePaths['quadrantLiquidPath'])) {
- $quadrantMarkup = File::get($filePaths['quadrantLiquidPath']);
- if ($markupLanguage === 'liquid') {
- $quadrantMarkup = '
'."\n".$quadrantMarkup."\n".'
';
- }
+ } elseif ($filePaths['sharedLiquidPath']) {
+ $templatePath = $filePaths['sharedLiquidPath'];
+ $fullLiquid = File::get($templatePath);
+ $markupLanguage = 'liquid';
+ $fullLiquid = '
'."\n".$fullLiquid."\n".'
';
+ } elseif ($filePaths['sharedBladePath']) {
+ $templatePath = $filePaths['sharedBladePath'];
+ $fullLiquid = File::get($templatePath);
+ $markupLanguage = 'blade';
}
// Ensure custom_fields is properly formatted
@@ -182,10 +160,6 @@ class PluginImportService
'polling_body' => $settings['polling_body'] ?? null,
'markup_language' => $markupLanguage,
'render_markup' => $fullLiquid ?? null,
- 'render_markup_half_horizontal' => $halfHorizontalMarkup,
- 'render_markup_half_vertical' => $halfVerticalMarkup,
- 'render_markup_quadrant' => $quadrantMarkup,
- 'render_markup_shared' => $sharedMarkup,
'configuration_template' => $configurationTemplate,
'data_payload' => json_decode($settings['static_data'] ?? '{}', true),
]);
@@ -272,59 +246,37 @@ class PluginImportService
$settings = Yaml::parse($settingsYaml);
$this->validateYAML($settings);
- // Determine markup language from the first available file
+ // Determine which template file to use and read its content
+ $templatePath = null;
$markupLanguage = 'blade';
- $firstTemplatePath = $filePaths['fullLiquidPath']
- ?? ($filePaths['halfHorizontalLiquidPath'] ?? null)
- ?? ($filePaths['halfVerticalLiquidPath'] ?? null)
- ?? ($filePaths['quadrantLiquidPath'] ?? null)
- ?? ($filePaths['sharedLiquidPath'] ?? null)
- ?? ($filePaths['sharedBladePath'] ?? null);
- if ($firstTemplatePath && pathinfo((string) $firstTemplatePath, PATHINFO_EXTENSION) === 'liquid') {
- $markupLanguage = 'liquid';
- }
+ if ($filePaths['fullLiquidPath']) {
+ $templatePath = $filePaths['fullLiquidPath'];
+ $fullLiquid = File::get($templatePath);
- // Read full markup (don't prepend shared - it will be prepended at render time)
- $fullLiquid = null;
- if (isset($filePaths['fullLiquidPath']) && $filePaths['fullLiquidPath']) {
- $fullLiquid = File::get($filePaths['fullLiquidPath']);
- if ($markupLanguage === 'liquid') {
+ // Prepend shared.liquid or shared.blade.php content if available
+ if ($filePaths['sharedLiquidPath'] && File::exists($filePaths['sharedLiquidPath'])) {
+ $sharedLiquid = File::get($filePaths['sharedLiquidPath']);
+ $fullLiquid = $sharedLiquid."\n".$fullLiquid;
+ } elseif ($filePaths['sharedBladePath'] && File::exists($filePaths['sharedBladePath'])) {
+ $sharedBlade = File::get($filePaths['sharedBladePath']);
+ $fullLiquid = $sharedBlade."\n".$fullLiquid;
+ }
+
+ // Check if the file ends with .liquid to set markup language
+ if (pathinfo((string) $templatePath, PATHINFO_EXTENSION) === 'liquid') {
+ $markupLanguage = 'liquid';
$fullLiquid = '
'."\n".$fullLiquid."\n".'
';
}
- }
-
- // Read shared markup separately
- $sharedMarkup = null;
- if (isset($filePaths['sharedLiquidPath']) && $filePaths['sharedLiquidPath'] && File::exists($filePaths['sharedLiquidPath'])) {
- $sharedMarkup = File::get($filePaths['sharedLiquidPath']);
- } elseif (isset($filePaths['sharedBladePath']) && $filePaths['sharedBladePath'] && File::exists($filePaths['sharedBladePath'])) {
- $sharedMarkup = File::get($filePaths['sharedBladePath']);
- }
-
- // Read layout-specific markups
- $halfHorizontalMarkup = null;
- if (isset($filePaths['halfHorizontalLiquidPath']) && $filePaths['halfHorizontalLiquidPath'] && File::exists($filePaths['halfHorizontalLiquidPath'])) {
- $halfHorizontalMarkup = File::get($filePaths['halfHorizontalLiquidPath']);
- if ($markupLanguage === 'liquid') {
- $halfHorizontalMarkup = '
'."\n".$halfHorizontalMarkup."\n".'
';
- }
- }
-
- $halfVerticalMarkup = null;
- if (isset($filePaths['halfVerticalLiquidPath']) && $filePaths['halfVerticalLiquidPath'] && File::exists($filePaths['halfVerticalLiquidPath'])) {
- $halfVerticalMarkup = File::get($filePaths['halfVerticalLiquidPath']);
- if ($markupLanguage === 'liquid') {
- $halfVerticalMarkup = '
'."\n".$halfVerticalMarkup."\n".'
';
- }
- }
-
- $quadrantMarkup = null;
- if (isset($filePaths['quadrantLiquidPath']) && $filePaths['quadrantLiquidPath'] && File::exists($filePaths['quadrantLiquidPath'])) {
- $quadrantMarkup = File::get($filePaths['quadrantLiquidPath']);
- if ($markupLanguage === 'liquid') {
- $quadrantMarkup = '
'."\n".$quadrantMarkup."\n".'
';
- }
+ } elseif ($filePaths['sharedLiquidPath']) {
+ $templatePath = $filePaths['sharedLiquidPath'];
+ $fullLiquid = File::get($templatePath);
+ $markupLanguage = 'liquid';
+ $fullLiquid = '
'."\n".$fullLiquid."\n".'
';
+ } elseif ($filePaths['sharedBladePath']) {
+ $templatePath = $filePaths['sharedBladePath'];
+ $fullLiquid = File::get($templatePath);
+ $markupLanguage = 'blade';
}
// Ensure custom_fields is properly formatted
@@ -370,10 +322,6 @@ class PluginImportService
'polling_body' => $settings['polling_body'] ?? null,
'markup_language' => $markupLanguage,
'render_markup' => $fullLiquid ?? null,
- 'render_markup_half_horizontal' => $halfHorizontalMarkup,
- 'render_markup_half_vertical' => $halfVerticalMarkup,
- 'render_markup_quadrant' => $quadrantMarkup,
- 'render_markup_shared' => $sharedMarkup,
'configuration_template' => $configurationTemplate,
'data_payload' => json_decode($settings['static_data'] ?? '{}', true),
'preferred_renderer' => $preferredRenderer,
@@ -409,9 +357,6 @@ class PluginImportService
$fullLiquidPath = null;
$sharedLiquidPath = null;
$sharedBladePath = null;
- $halfHorizontalLiquidPath = null;
- $halfVerticalLiquidPath = null;
- $quadrantLiquidPath = null;
// If zipEntryPath is specified, look for files in that specific directory first
if ($zipEntryPath) {
@@ -432,25 +377,6 @@ class PluginImportService
} elseif (File::exists($targetDir.'/shared.blade.php')) {
$sharedBladePath = $targetDir.'/shared.blade.php';
}
-
- // Check for layout-specific files
- if (File::exists($targetDir.'/half_horizontal.liquid')) {
- $halfHorizontalLiquidPath = $targetDir.'/half_horizontal.liquid';
- } elseif (File::exists($targetDir.'/half_horizontal.blade.php')) {
- $halfHorizontalLiquidPath = $targetDir.'/half_horizontal.blade.php';
- }
-
- if (File::exists($targetDir.'/half_vertical.liquid')) {
- $halfVerticalLiquidPath = $targetDir.'/half_vertical.liquid';
- } elseif (File::exists($targetDir.'/half_vertical.blade.php')) {
- $halfVerticalLiquidPath = $targetDir.'/half_vertical.blade.php';
- }
-
- if (File::exists($targetDir.'/quadrant.liquid')) {
- $quadrantLiquidPath = $targetDir.'/quadrant.liquid';
- } elseif (File::exists($targetDir.'/quadrant.blade.php')) {
- $quadrantLiquidPath = $targetDir.'/quadrant.blade.php';
- }
}
// Check if files are in src subdirectory of target directory
@@ -468,25 +394,6 @@ class PluginImportService
} elseif (File::exists($targetDir.'/src/shared.blade.php')) {
$sharedBladePath = $targetDir.'/src/shared.blade.php';
}
-
- // Check for layout-specific files in src
- if (File::exists($targetDir.'/src/half_horizontal.liquid')) {
- $halfHorizontalLiquidPath = $targetDir.'/src/half_horizontal.liquid';
- } elseif (File::exists($targetDir.'/src/half_horizontal.blade.php')) {
- $halfHorizontalLiquidPath = $targetDir.'/src/half_horizontal.blade.php';
- }
-
- if (File::exists($targetDir.'/src/half_vertical.liquid')) {
- $halfVerticalLiquidPath = $targetDir.'/src/half_vertical.liquid';
- } elseif (File::exists($targetDir.'/src/half_vertical.blade.php')) {
- $halfVerticalLiquidPath = $targetDir.'/src/half_vertical.blade.php';
- }
-
- if (File::exists($targetDir.'/src/quadrant.liquid')) {
- $quadrantLiquidPath = $targetDir.'/src/quadrant.liquid';
- } elseif (File::exists($targetDir.'/src/quadrant.blade.php')) {
- $quadrantLiquidPath = $targetDir.'/src/quadrant.blade.php';
- }
}
// If we found the required files in the target directory, return them
@@ -518,25 +425,6 @@ class PluginImportService
} elseif (File::exists($tempDir.'/src/shared.blade.php')) {
$sharedBladePath = $tempDir.'/src/shared.blade.php';
}
-
- // Check for layout-specific files
- if (File::exists($tempDir.'/src/half_horizontal.liquid')) {
- $halfHorizontalLiquidPath = $tempDir.'/src/half_horizontal.liquid';
- } elseif (File::exists($tempDir.'/src/half_horizontal.blade.php')) {
- $halfHorizontalLiquidPath = $tempDir.'/src/half_horizontal.blade.php';
- }
-
- if (File::exists($tempDir.'/src/half_vertical.liquid')) {
- $halfVerticalLiquidPath = $tempDir.'/src/half_vertical.liquid';
- } elseif (File::exists($tempDir.'/src/half_vertical.blade.php')) {
- $halfVerticalLiquidPath = $tempDir.'/src/half_vertical.blade.php';
- }
-
- if (File::exists($tempDir.'/src/quadrant.liquid')) {
- $quadrantLiquidPath = $tempDir.'/src/quadrant.liquid';
- } elseif (File::exists($tempDir.'/src/quadrant.blade.php')) {
- $quadrantLiquidPath = $tempDir.'/src/quadrant.blade.php';
- }
} else {
// Search for the files in the extracted directory structure
$directories = new RecursiveDirectoryIterator($tempDir, RecursiveDirectoryIterator::SKIP_DOTS);
@@ -554,12 +442,6 @@ class PluginImportService
$sharedLiquidPath = $filepath;
} elseif ($filename === 'shared.blade.php') {
$sharedBladePath = $filepath;
- } elseif ($filename === 'half_horizontal.liquid' || $filename === 'half_horizontal.blade.php') {
- $halfHorizontalLiquidPath = $filepath;
- } elseif ($filename === 'half_vertical.liquid' || $filename === 'half_vertical.blade.php') {
- $halfVerticalLiquidPath = $filepath;
- } elseif ($filename === 'quadrant.liquid' || $filename === 'quadrant.blade.php') {
- $quadrantLiquidPath = $filepath;
}
}
@@ -603,25 +485,6 @@ class PluginImportService
$sharedBladePath = $newSrcDir.'/shared.blade.php';
}
- // Copy layout-specific files if they exist
- if ($halfHorizontalLiquidPath) {
- $extension = pathinfo((string) $halfHorizontalLiquidPath, PATHINFO_EXTENSION);
- File::copy($halfHorizontalLiquidPath, $newSrcDir.'/half_horizontal.'.$extension);
- $halfHorizontalLiquidPath = $newSrcDir.'/half_horizontal.'.$extension;
- }
-
- if ($halfVerticalLiquidPath) {
- $extension = pathinfo((string) $halfVerticalLiquidPath, PATHINFO_EXTENSION);
- File::copy($halfVerticalLiquidPath, $newSrcDir.'/half_vertical.'.$extension);
- $halfVerticalLiquidPath = $newSrcDir.'/half_vertical.'.$extension;
- }
-
- if ($quadrantLiquidPath) {
- $extension = pathinfo((string) $quadrantLiquidPath, PATHINFO_EXTENSION);
- File::copy($quadrantLiquidPath, $newSrcDir.'/quadrant.'.$extension);
- $quadrantLiquidPath = $newSrcDir.'/quadrant.'.$extension;
- }
-
// Update the paths
$settingsYamlPath = $newSrcDir.'/settings.yml';
}
@@ -633,9 +496,6 @@ class PluginImportService
'fullLiquidPath' => $fullLiquidPath,
'sharedLiquidPath' => $sharedLiquidPath,
'sharedBladePath' => $sharedBladePath,
- 'halfHorizontalLiquidPath' => $halfHorizontalLiquidPath,
- 'halfVerticalLiquidPath' => $halfVerticalLiquidPath,
- 'quadrantLiquidPath' => $quadrantLiquidPath,
];
}
diff --git a/composer.json b/composer.json
index 96e0079..d856e75 100644
--- a/composer.json
+++ b/composer.json
@@ -15,7 +15,7 @@
"ext-imagick": "*",
"ext-simplexml": "*",
"ext-zip": "*",
- "bnussbau/laravel-trmnl-blade": "2.1.1",
+ "bnussbau/laravel-trmnl-blade": "2.2.*",
"bnussbau/trmnl-pipeline-php": "^0.6.0",
"keepsuit/laravel-liquid": "^0.5.2",
"laravel/fortify": "^1.30",
diff --git a/composer.lock b/composer.lock
index a61b132..ec617d3 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "60a7e51edd8408cffdb901e4a1c1684a",
+ "content-hash": "581bacf794841fc11c540e152c704d16",
"packages": [
{
"name": "aws/aws-crt-php",
@@ -62,16 +62,16 @@
},
{
"name": "aws/aws-sdk-php",
- "version": "3.369.29",
+ "version": "3.369.27",
"source": {
"type": "git",
"url": "https://github.com/aws/aws-sdk-php.git",
- "reference": "068195b2980cf5cf4ade2515850d461186db3310"
+ "reference": "f844afab2a74eb3cf881970a9c31de460510eb74"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/068195b2980cf5cf4ade2515850d461186db3310",
- "reference": "068195b2980cf5cf4ade2515850d461186db3310",
+ "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/f844afab2a74eb3cf881970a9c31de460510eb74",
+ "reference": "f844afab2a74eb3cf881970a9c31de460510eb74",
"shasum": ""
},
"require": {
@@ -153,9 +153,9 @@
"support": {
"forum": "https://github.com/aws/aws-sdk-php/discussions",
"issues": "https://github.com/aws/aws-sdk-php/issues",
- "source": "https://github.com/aws/aws-sdk-php/tree/3.369.29"
+ "source": "https://github.com/aws/aws-sdk-php/tree/3.369.27"
},
- "time": "2026-02-06T19:08:50+00:00"
+ "time": "2026-02-04T19:07:08+00:00"
},
{
"name": "bacon/bacon-qr-code",
@@ -214,16 +214,16 @@
},
{
"name": "bnussbau/laravel-trmnl-blade",
- "version": "2.1.1",
+ "version": "2.2.1",
"source": {
"type": "git",
"url": "https://github.com/bnussbau/laravel-trmnl-blade.git",
- "reference": "6ad96eba917ebc30ebe550e6fce4a995e94f6b35"
+ "reference": "6db8a82a15ccedcaaffd3b37d0d337d276a26669"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/bnussbau/laravel-trmnl-blade/zipball/6ad96eba917ebc30ebe550e6fce4a995e94f6b35",
- "reference": "6ad96eba917ebc30ebe550e6fce4a995e94f6b35",
+ "url": "https://api.github.com/repos/bnussbau/laravel-trmnl-blade/zipball/6db8a82a15ccedcaaffd3b37d0d337d276a26669",
+ "reference": "6db8a82a15ccedcaaffd3b37d0d337d276a26669",
"shasum": ""
},
"require": {
@@ -278,7 +278,7 @@
],
"support": {
"issues": "https://github.com/bnussbau/laravel-trmnl-blade/issues",
- "source": "https://github.com/bnussbau/laravel-trmnl-blade/tree/2.1.1"
+ "source": "https://github.com/bnussbau/laravel-trmnl-blade/tree/2.2.1"
},
"funding": [
{
@@ -294,7 +294,7 @@
"type": "github"
}
],
- "time": "2026-01-29T20:40:42+00:00"
+ "time": "2026-02-05T17:57:37+00:00"
},
{
"name": "bnussbau/trmnl-pipeline-php",
@@ -3194,16 +3194,16 @@
},
{
"name": "livewire/livewire",
- "version": "v4.1.3",
+ "version": "v4.1.2",
"source": {
"type": "git",
"url": "https://github.com/livewire/livewire.git",
- "reference": "69c871cb15fb95f10cda5acd1ee7e63cd3c494c8"
+ "reference": "8adef21f35f4ffa87fd2f3655b350236df0c39a8"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/livewire/livewire/zipball/69c871cb15fb95f10cda5acd1ee7e63cd3c494c8",
- "reference": "69c871cb15fb95f10cda5acd1ee7e63cd3c494c8",
+ "url": "https://api.github.com/repos/livewire/livewire/zipball/8adef21f35f4ffa87fd2f3655b350236df0c39a8",
+ "reference": "8adef21f35f4ffa87fd2f3655b350236df0c39a8",
"shasum": ""
},
"require": {
@@ -3258,7 +3258,7 @@
"description": "A front-end framework for Laravel.",
"support": {
"issues": "https://github.com/livewire/livewire/issues",
- "source": "https://github.com/livewire/livewire/tree/v4.1.3"
+ "source": "https://github.com/livewire/livewire/tree/v4.1.2"
},
"funding": [
{
@@ -3266,7 +3266,7 @@
"type": "github"
}
],
- "time": "2026-02-06T12:19:55+00:00"
+ "time": "2026-02-03T03:01:29+00:00"
},
{
"name": "maennchen/zipstream-php",
@@ -9066,16 +9066,16 @@
},
{
"name": "laravel/boost",
- "version": "v2.1.1",
+ "version": "v2.0.6",
"source": {
"type": "git",
"url": "https://github.com/laravel/boost.git",
- "reference": "1c7d6f44c96937a961056778b9143218b1183302"
+ "reference": "1e1cb76e8e87ca3dd3c3d64deccbc97f4de38215"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/laravel/boost/zipball/1c7d6f44c96937a961056778b9143218b1183302",
- "reference": "1c7d6f44c96937a961056778b9143218b1183302",
+ "url": "https://api.github.com/repos/laravel/boost/zipball/1e1cb76e8e87ca3dd3c3d64deccbc97f4de38215",
+ "reference": "1e1cb76e8e87ca3dd3c3d64deccbc97f4de38215",
"shasum": ""
},
"require": {
@@ -9128,7 +9128,7 @@
"issues": "https://github.com/laravel/boost/issues",
"source": "https://github.com/laravel/boost"
},
- "time": "2026-02-06T10:41:29+00:00"
+ "time": "2026-02-04T10:10:48+00:00"
},
{
"name": "laravel/mcp",
@@ -10484,16 +10484,16 @@
},
{
"name": "phpunit/php-code-coverage",
- "version": "12.5.3",
+ "version": "12.5.2",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
- "reference": "b015312f28dd75b75d3422ca37dff2cd1a565e8d"
+ "reference": "4a9739b51cbcb355f6e95659612f92e282a7077b"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/b015312f28dd75b75d3422ca37dff2cd1a565e8d",
- "reference": "b015312f28dd75b75d3422ca37dff2cd1a565e8d",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/4a9739b51cbcb355f6e95659612f92e282a7077b",
+ "reference": "4a9739b51cbcb355f6e95659612f92e282a7077b",
"shasum": ""
},
"require": {
@@ -10549,7 +10549,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/php-code-coverage/issues",
"security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy",
- "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/12.5.3"
+ "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/12.5.2"
},
"funding": [
{
@@ -10569,7 +10569,7 @@
"type": "tidelift"
}
],
- "time": "2026-02-06T06:01:44+00:00"
+ "time": "2025-12-24T07:03:04+00:00"
},
{
"name": "phpunit/php-file-iterator",
@@ -10935,21 +10935,21 @@
},
{
"name": "rector/rector",
- "version": "2.3.6",
+ "version": "2.3.5",
"source": {
"type": "git",
"url": "https://github.com/rectorphp/rector.git",
- "reference": "ca9ebb81d280cd362ea39474dabd42679e32ca6b"
+ "reference": "9442f4037de6a5347ae157fe8e6c7cda9d909070"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/rectorphp/rector/zipball/ca9ebb81d280cd362ea39474dabd42679e32ca6b",
- "reference": "ca9ebb81d280cd362ea39474dabd42679e32ca6b",
+ "url": "https://api.github.com/repos/rectorphp/rector/zipball/9442f4037de6a5347ae157fe8e6c7cda9d909070",
+ "reference": "9442f4037de6a5347ae157fe8e6c7cda9d909070",
"shasum": ""
},
"require": {
"php": "^7.4|^8.0",
- "phpstan/phpstan": "^2.1.38"
+ "phpstan/phpstan": "^2.1.36"
},
"conflict": {
"rector/rector-doctrine": "*",
@@ -10983,7 +10983,7 @@
],
"support": {
"issues": "https://github.com/rectorphp/rector/issues",
- "source": "https://github.com/rectorphp/rector/tree/2.3.6"
+ "source": "https://github.com/rectorphp/rector/tree/2.3.5"
},
"funding": [
{
@@ -10991,7 +10991,7 @@
"type": "github"
}
],
- "time": "2026-02-06T14:25:06+00:00"
+ "time": "2026-01-28T15:22:48+00:00"
},
{
"name": "sebastian/cli-parser",
diff --git a/database/migrations/2026_01_28_143142_add_layout_markup_columns_to_plugins_table.php b/database/migrations/2026_01_28_143142_add_layout_markup_columns_to_plugins_table.php
deleted file mode 100644
index e56751c..0000000
--- a/database/migrations/2026_01_28_143142_add_layout_markup_columns_to_plugins_table.php
+++ /dev/null
@@ -1,38 +0,0 @@
-text('render_markup_half_horizontal')->nullable()->after('render_markup');
- $table->text('render_markup_half_vertical')->nullable()->after('render_markup_half_horizontal');
- $table->text('render_markup_quadrant')->nullable()->after('render_markup_half_vertical');
- $table->text('render_markup_shared')->nullable()->after('render_markup_quadrant');
- $table->text('transform_code')->nullable()->after('render_markup_shared');
- });
- }
-
- /**
- * Reverse the migrations.
- */
- public function down(): void
- {
- Schema::table('plugins', function (Blueprint $table) {
- $table->dropColumn([
- 'render_markup_half_horizontal',
- 'render_markup_half_vertical',
- 'render_markup_quadrant',
- 'render_markup_shared',
- 'transform_code',
- ]);
- });
- }
-};
diff --git a/resources/views/livewire/device-models/index.blade.php b/resources/views/livewire/device-models/index.blade.php
index 1aebeb1..6ec4014 100644
--- a/resources/views/livewire/device-models/index.blade.php
+++ b/resources/views/livewire/device-models/index.blade.php
@@ -1,6 +1,5 @@
deviceModels = DeviceModel::all();
- $this->devicePalettes = DevicePalette::all();
- session()->flash('message', 'Device models updated from API.');
- }
-
public function openDeviceModelModal(?string $deviceModelId = null, bool $viewOnly = false): void
{
if ($deviceModelId) {
@@ -238,17 +229,9 @@ new class extends Component
-
diff --git a/resources/views/livewire/device-palettes/index.blade.php b/resources/views/livewire/device-palettes/index.blade.php
index 4e96c31..6640545 100644
--- a/resources/views/livewire/device-palettes/index.blade.php
+++ b/resources/views/livewire/device-palettes/index.blade.php
@@ -1,6 +1,5 @@
devicePalettes = DevicePalette::all();
- session()->flash('message', 'Device palettes updated from API.');
- }
-
public function openDevicePaletteModal(?string $devicePaletteId = null, bool $viewOnly = false): void
{
if ($devicePaletteId) {
@@ -210,17 +202,9 @@ new class extends Component
-