Files
udo 930e23d3b0 Add workspace components and routing enhancements
- Introduced new workspace components including app-frame, empty-state, icon-button, list-state, mobile-bar, panel-header, panel, section-head, section, sidebar-shell, sidebar-toolbar, and status-pill for improved UI structure.
- Implemented directory index routing and parent-path fallback in index.php for better navigation.
- Updated README.md to reflect new workspace features and patterns.
- Added workspace.css for styling the new components and layout.
- Enhanced settings.php to include workspace in the navigation structure.
- Created views/workspace/index.php to serve as the main workspace interface with dynamic sections and navigation.
2026-04-18 12:32:59 +00:00

24 lines
1.2 KiB
PHP

<?php return [
'render' => function($prop) {
$id = trim((string)($prop['id'] ?? ''));
$class = trim((string)($prop['class'] ?? ''));
$buttonId = trim((string)($prop['button_id'] ?? ''));
$buttonClass = trim((string)($prop['button_class'] ?? ''));
$titleId = trim((string)($prop['title_id'] ?? ''));
$titleClass = trim((string)($prop['title_class'] ?? ''));
$title = (string)($prop['title'] ?? '');
$icon = trim((string)($prop['icon_class'] ?? 'fas fa-bars'));
ob_start();
?>
<div<?= $id !== '' ? ' id="' . asafe($id) . '"' : '' ?> class="ws-mobile-bar<?= $class !== '' ? ' ' . asafe($class) : '' ?>">
<button<?= $buttonId !== '' ? ' id="' . asafe($buttonId) . '"' : '' ?> class="ws-mobile-toggle<?= $buttonClass !== '' ? ' ' . asafe($buttonClass) : '' ?>" title="Toggle sidebar" type="button">
<i class="<?= asafe($icon) ?>"></i>
</button>
<span<?= $titleId !== '' ? ' id="' . asafe($titleId) . '"' : '' ?> class="ws-mobile-title<?= $titleClass !== '' ? ' ' . asafe($titleClass) : '' ?>"><?= safe($title) ?></span>
</div>
<?php
return ob_get_clean();
},
'about' => 'Compact mobile header bar for workspace layouts with a sidebar toggle',
];