@rakeyshgidwani/roger-ui-bank-theme-stan-design 0.2.7 → 0.2.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +1 -1
- package/dist/components/ui/accessibility-demo.d.ts +259 -0
- package/dist/components/ui/accessibility-demo.esm.js +265 -0
- package/dist/components/ui/accessibility-demo.js +265 -0
- package/dist/components/ui/advanced-component-architecture-demo.d.ts +718 -0
- package/dist/components/ui/advanced-component-architecture-demo.esm.js +860 -0
- package/dist/components/ui/advanced-component-architecture-demo.js +860 -0
- package/dist/components/ui/advanced-transition-system-demo.d.ts +660 -0
- package/dist/components/ui/advanced-transition-system-demo.esm.js +624 -0
- package/dist/components/ui/advanced-transition-system-demo.js +624 -0
- package/dist/components/ui/advanced-transition-system.d.ts +391 -0
- package/dist/components/ui/advanced-transition-system.esm.js +351 -0
- package/dist/components/ui/advanced-transition-system.js +351 -0
- package/dist/components/ui/animation/animated-container.d.ts +162 -0
- package/dist/components/ui/animation/animated-container.esm.js +143 -0
- package/dist/components/ui/animation/animated-container.js +143 -0
- package/dist/components/ui/animation/index.d.ts +9 -0
- package/dist/components/ui/animation/index.esm.js +19 -0
- package/dist/components/ui/animation/index.js +19 -0
- package/dist/components/ui/animation/staggered-container.d.ts +64 -0
- package/dist/components/ui/animation/staggered-container.esm.js +59 -0
- package/dist/components/ui/animation/staggered-container.js +59 -0
- package/dist/components/ui/animation-demo.d.ts +238 -0
- package/dist/components/ui/animation-demo.esm.js +218 -0
- package/dist/components/ui/animation-demo.js +218 -0
- package/dist/components/ui/badge.d.ts +28 -0
- package/dist/components/ui/badge.esm.js +30 -0
- package/dist/components/ui/badge.js +30 -0
- package/dist/components/ui/battery-conscious-animation-demo.d.ts +561 -0
- package/dist/components/ui/battery-conscious-animation-demo.esm.js +533 -0
- package/dist/components/ui/battery-conscious-animation-demo.js +533 -0
- package/dist/components/ui/border-radius-shadow-demo.d.ts +183 -0
- package/dist/components/ui/border-radius-shadow-demo.esm.js +176 -0
- package/dist/components/ui/border-radius-shadow-demo.js +176 -0
- package/dist/components/ui/button.d.ts +33 -0
- package/dist/components/ui/button.esm.js +30 -0
- package/dist/components/ui/button.js +30 -0
- package/dist/components/ui/card.d.ts +205 -0
- package/dist/components/ui/card.esm.js +182 -0
- package/dist/components/ui/card.js +182 -0
- package/dist/components/ui/checkbox.d.ts +26 -0
- package/dist/components/ui/checkbox.esm.js +30 -0
- package/dist/components/ui/checkbox.js +30 -0
- package/dist/components/ui/color-preview.d.ts +402 -0
- package/dist/components/ui/color-preview.esm.js +388 -0
- package/dist/components/ui/color-preview.js +388 -0
- package/dist/components/ui/data-display/chart.d.ts +646 -0
- package/dist/components/ui/data-display/chart.esm.js +625 -0
- package/dist/components/ui/data-display/chart.js +625 -0
- package/dist/components/ui/data-display/data-grid-simple.d.ts +73 -0
- package/dist/components/ui/data-display/data-grid-simple.esm.js +76 -0
- package/dist/components/ui/data-display/data-grid-simple.js +76 -0
- package/dist/components/ui/data-display/data-grid.d.ts +670 -0
- package/dist/components/ui/data-display/data-grid.esm.js +667 -0
- package/dist/components/ui/data-display/data-grid.js +667 -0
- package/dist/components/ui/data-display/list.d.ts +448 -0
- package/dist/components/ui/data-display/list.esm.js +448 -0
- package/dist/components/ui/data-display/list.js +448 -0
- package/dist/components/ui/data-display/table.d.ts +472 -0
- package/dist/components/ui/data-display/table.esm.js +474 -0
- package/dist/components/ui/data-display/table.js +474 -0
- package/dist/components/ui/data-display/timeline.d.ts +433 -0
- package/dist/components/ui/data-display/timeline.esm.js +436 -0
- package/dist/components/ui/data-display/timeline.js +436 -0
- package/dist/components/ui/data-display/tree.d.ts +594 -0
- package/dist/components/ui/data-display/tree.esm.js +570 -0
- package/dist/components/ui/data-display/tree.js +570 -0
- package/dist/components/ui/data-display/types.d.ts +534 -0
- package/dist/components/ui/data-display/types.esm.js +511 -0
- package/dist/components/ui/data-display/types.js +511 -0
- package/dist/components/ui/enterprise-mobile-experience-demo.d.ts +735 -0
- package/dist/components/ui/enterprise-mobile-experience-demo.esm.js +699 -0
- package/dist/components/ui/enterprise-mobile-experience-demo.js +699 -0
- package/dist/components/ui/enterprise-mobile-experience.d.ts +461 -0
- package/dist/components/ui/enterprise-mobile-experience.esm.js +413 -0
- package/dist/components/ui/enterprise-mobile-experience.js +413 -0
- package/dist/components/ui/feedback/alert.d.ts +154 -0
- package/dist/components/ui/feedback/alert.esm.js +150 -0
- package/dist/components/ui/feedback/alert.js +150 -0
- package/dist/components/ui/feedback/progress.d.ts +288 -0
- package/dist/components/ui/feedback/progress.esm.js +269 -0
- package/dist/components/ui/feedback/progress.js +269 -0
- package/dist/components/ui/feedback/skeleton.d.ts +182 -0
- package/dist/components/ui/feedback/skeleton.esm.js +175 -0
- package/dist/components/ui/feedback/skeleton.js +175 -0
- package/dist/components/ui/feedback/toast.d.ts +277 -0
- package/dist/components/ui/feedback/toast.esm.js +256 -0
- package/dist/components/ui/feedback/toast.js +256 -0
- package/dist/components/ui/feedback/types.d.ts +123 -0
- package/dist/components/ui/feedback/types.esm.js +125 -0
- package/dist/components/ui/feedback/types.js +125 -0
- package/dist/components/ui/font-preview.d.ts +282 -0
- package/dist/components/ui/font-preview.esm.js +286 -0
- package/dist/components/ui/font-preview.js +286 -0
- package/dist/components/ui/form-demo.d.ts +544 -0
- package/dist/components/ui/form-demo.esm.js +516 -0
- package/dist/components/ui/form-demo.js +516 -0
- package/dist/components/ui/hardware-acceleration-demo.d.ts +540 -0
- package/dist/components/ui/hardware-acceleration-demo.esm.js +497 -0
- package/dist/components/ui/hardware-acceleration-demo.js +497 -0
- package/dist/components/ui/input.d.ts +33 -0
- package/dist/components/ui/input.esm.js +32 -0
- package/dist/components/ui/input.js +32 -0
- package/dist/components/ui/label.d.ts +13 -0
- package/dist/components/ui/label.esm.js +16 -0
- package/dist/components/ui/label.js +16 -0
- package/dist/components/ui/layout-demo.d.ts +352 -0
- package/dist/components/ui/layout-demo.esm.js +342 -0
- package/dist/components/ui/layout-demo.js +342 -0
- package/dist/components/ui/layouts/adaptive-layout.d.ts +132 -0
- package/dist/components/ui/layouts/adaptive-layout.esm.js +120 -0
- package/dist/components/ui/layouts/adaptive-layout.js +120 -0
- package/dist/components/ui/layouts/desktop-layout.d.ts +219 -0
- package/dist/components/ui/layouts/desktop-layout.esm.js +204 -0
- package/dist/components/ui/layouts/desktop-layout.js +204 -0
- package/dist/components/ui/layouts/index.d.ts +5 -0
- package/dist/components/ui/layouts/index.esm.js +10 -0
- package/dist/components/ui/layouts/index.js +10 -0
- package/dist/components/ui/layouts/mobile-layout.d.ts +158 -0
- package/dist/components/ui/layouts/mobile-layout.esm.js +152 -0
- package/dist/components/ui/layouts/mobile-layout.js +152 -0
- package/dist/components/ui/layouts/tablet-layout.d.ts +192 -0
- package/dist/components/ui/layouts/tablet-layout.esm.js +183 -0
- package/dist/components/ui/layouts/tablet-layout.js +183 -0
- package/dist/components/ui/mobile-form-validation.d.ts +439 -0
- package/dist/components/ui/mobile-form-validation.esm.js +418 -0
- package/dist/components/ui/mobile-form-validation.js +418 -0
- package/dist/components/ui/mobile-input-demo.d.ts +197 -0
- package/dist/components/ui/mobile-input-demo.esm.js +195 -0
- package/dist/components/ui/mobile-input-demo.js +195 -0
- package/dist/components/ui/mobile-input.d.ts +273 -0
- package/dist/components/ui/mobile-input.esm.js +216 -0
- package/dist/components/ui/mobile-input.js +216 -0
- package/dist/components/ui/mobile-skeleton-loading-demo.d.ts +628 -0
- package/dist/components/ui/mobile-skeleton-loading-demo.esm.js +621 -0
- package/dist/components/ui/mobile-skeleton-loading-demo.js +621 -0
- package/dist/components/ui/navigation/breadcrumb.d.ts +149 -0
- package/dist/components/ui/navigation/breadcrumb.esm.js +155 -0
- package/dist/components/ui/navigation/breadcrumb.js +155 -0
- package/dist/components/ui/navigation/index.d.ts +25 -0
- package/dist/components/ui/navigation/index.esm.js +14 -0
- package/dist/components/ui/navigation/index.js +14 -0
- package/dist/components/ui/navigation/menu.d.ts +366 -0
- package/dist/components/ui/navigation/menu.esm.js +360 -0
- package/dist/components/ui/navigation/menu.js +360 -0
- package/dist/components/ui/navigation/navigation-demo.d.ts +169 -0
- package/dist/components/ui/navigation/navigation-demo.esm.js +317 -0
- package/dist/components/ui/navigation/navigation-demo.js +317 -0
- package/dist/components/ui/navigation/pagination.d.ts +261 -0
- package/dist/components/ui/navigation/pagination.esm.js +260 -0
- package/dist/components/ui/navigation/pagination.js +260 -0
- package/dist/components/ui/navigation/sidebar.d.ts +375 -0
- package/dist/components/ui/navigation/sidebar.esm.js +369 -0
- package/dist/components/ui/navigation/sidebar.js +369 -0
- package/dist/components/ui/navigation/stepper.d.ts +294 -0
- package/dist/components/ui/navigation/stepper.esm.js +292 -0
- package/dist/components/ui/navigation/stepper.js +292 -0
- package/dist/components/ui/navigation/tabs.d.ts +196 -0
- package/dist/components/ui/navigation/tabs.esm.js +194 -0
- package/dist/components/ui/navigation/tabs.js +194 -0
- package/dist/components/ui/navigation/types.d.ts +293 -0
- package/dist/components/ui/navigation/types.esm.js +298 -0
- package/dist/components/ui/navigation/types.js +298 -0
- package/dist/components/ui/overlay/backdrop.d.ts +79 -0
- package/dist/components/ui/overlay/backdrop.esm.js +80 -0
- package/dist/components/ui/overlay/backdrop.js +80 -0
- package/dist/components/ui/overlay/focus-manager.d.ts +141 -0
- package/dist/components/ui/overlay/focus-manager.esm.js +141 -0
- package/dist/components/ui/overlay/focus-manager.js +141 -0
- package/dist/components/ui/overlay/index.d.ts +27 -0
- package/dist/components/ui/overlay/index.esm.js +16 -0
- package/dist/components/ui/overlay/index.js +16 -0
- package/dist/components/ui/overlay/modal.d.ts +262 -0
- package/dist/components/ui/overlay/modal.esm.js +266 -0
- package/dist/components/ui/overlay/modal.js +266 -0
- package/dist/components/ui/overlay/overlay-manager.d.ts +107 -0
- package/dist/components/ui/overlay/overlay-manager.esm.js +105 -0
- package/dist/components/ui/overlay/overlay-manager.js +105 -0
- package/dist/components/ui/overlay/popover.d.ts +450 -0
- package/dist/components/ui/overlay/popover.esm.js +446 -0
- package/dist/components/ui/overlay/popover.js +446 -0
- package/dist/components/ui/overlay/portal.d.ts +75 -0
- package/dist/components/ui/overlay/portal.esm.js +79 -0
- package/dist/components/ui/overlay/portal.js +79 -0
- package/dist/components/ui/overlay/tooltip.d.ts +298 -0
- package/dist/components/ui/overlay/tooltip.esm.js +288 -0
- package/dist/components/ui/overlay/tooltip.js +288 -0
- package/dist/components/ui/overlay/types.d.ts +194 -0
- package/dist/components/ui/overlay/types.esm.js +195 -0
- package/dist/components/ui/overlay/types.js +195 -0
- package/dist/components/ui/performance-demo.d.ts +583 -0
- package/dist/components/ui/performance-demo.esm.js +549 -0
- package/dist/components/ui/performance-demo.js +549 -0
- package/dist/components/ui/semantic-input-system-demo.d.ts +490 -0
- package/dist/components/ui/semantic-input-system-demo.esm.js +465 -0
- package/dist/components/ui/semantic-input-system-demo.js +465 -0
- package/dist/components/ui/theme-customizer.d.ts +378 -0
- package/dist/components/ui/theme-customizer.esm.js +354 -0
- package/dist/components/ui/theme-customizer.js +354 -0
- package/dist/components/ui/theme-preview.d.ts +305 -0
- package/dist/components/ui/theme-preview.esm.js +258 -0
- package/dist/components/ui/theme-preview.js +258 -0
- package/dist/components/ui/theme-switcher.d.ts +259 -0
- package/dist/components/ui/theme-switcher.esm.js +238 -0
- package/dist/components/ui/theme-switcher.js +238 -0
- package/dist/components/ui/theme-toggle.d.ts +34 -0
- package/dist/components/ui/theme-toggle.esm.js +38 -0
- package/dist/components/ui/theme-toggle.js +38 -0
- package/dist/components/ui/token-demo.d.ts +188 -0
- package/dist/components/ui/token-demo.esm.js +183 -0
- package/dist/components/ui/token-demo.js +183 -0
- package/dist/components/ui/touch-demo.d.ts +455 -0
- package/dist/components/ui/touch-demo.esm.js +433 -0
- package/dist/components/ui/touch-demo.js +433 -0
- package/dist/components/ui/touch-friendly-interface-demo.d.ts +512 -0
- package/dist/components/ui/touch-friendly-interface-demo.esm.js +481 -0
- package/dist/components/ui/touch-friendly-interface-demo.js +481 -0
- package/dist/components/ui/touch-friendly-interface.d.ts +292 -0
- package/dist/components/ui/touch-friendly-interface.esm.js +272 -0
- package/dist/components/ui/touch-friendly-interface.js +272 -0
- package/dist/hooks/index.d.ts +161 -0
- package/dist/hooks/index.esm.js +190 -0
- package/dist/hooks/index.js +190 -0
- package/dist/hooks/use-accessibility-support.d.ts +516 -0
- package/dist/hooks/use-accessibility-support.esm.js +488 -0
- package/dist/hooks/use-accessibility-support.js +488 -0
- package/dist/hooks/use-adaptive-layout.d.ts +287 -0
- package/dist/hooks/use-adaptive-layout.esm.js +266 -0
- package/dist/hooks/use-adaptive-layout.js +266 -0
- package/dist/hooks/use-advanced-patterns.d.ts +292 -0
- package/dist/hooks/use-advanced-patterns.esm.js +279 -0
- package/dist/hooks/use-advanced-patterns.js +279 -0
- package/dist/hooks/use-advanced-transition-system.d.ts +390 -0
- package/dist/hooks/use-advanced-transition-system.esm.js +352 -0
- package/dist/hooks/use-advanced-transition-system.js +352 -0
- package/dist/hooks/use-animation-profile.d.ts +285 -0
- package/dist/hooks/use-animation-profile.esm.js +259 -0
- package/dist/hooks/use-animation-profile.js +259 -0
- package/dist/hooks/use-battery-animations.d.ts +382 -0
- package/dist/hooks/use-battery-animations.esm.js +359 -0
- package/dist/hooks/use-battery-animations.js +359 -0
- package/dist/hooks/use-battery-conscious-loading.d.ts +473 -0
- package/dist/hooks/use-battery-conscious-loading.esm.js +432 -0
- package/dist/hooks/use-battery-conscious-loading.js +432 -0
- package/dist/hooks/use-battery-optimization.d.ts +328 -0
- package/dist/hooks/use-battery-optimization.esm.js +307 -0
- package/dist/hooks/use-battery-optimization.js +307 -0
- package/dist/hooks/use-battery-status.d.ts +297 -0
- package/dist/hooks/use-battery-status.esm.js +277 -0
- package/dist/hooks/use-battery-status.js +277 -0
- package/dist/hooks/use-component-performance.d.ts +342 -0
- package/dist/hooks/use-component-performance.esm.js +329 -0
- package/dist/hooks/use-component-performance.js +329 -0
- package/dist/hooks/use-device-loading-states.d.ts +456 -0
- package/dist/hooks/use-device-loading-states.esm.js +416 -0
- package/dist/hooks/use-device-loading-states.js +416 -0
- package/dist/hooks/use-device.d.ts +104 -0
- package/dist/hooks/use-device.esm.js +99 -0
- package/dist/hooks/use-device.js +99 -0
- package/dist/hooks/use-enterprise-mobile-experience.d.ts +486 -0
- package/dist/hooks/use-enterprise-mobile-experience.esm.js +439 -0
- package/dist/hooks/use-enterprise-mobile-experience.js +439 -0
- package/dist/hooks/use-form-feedback.d.ts +401 -0
- package/dist/hooks/use-form-feedback.esm.js +360 -0
- package/dist/hooks/use-form-feedback.js +360 -0
- package/dist/hooks/use-form-performance.d.ts +511 -0
- package/dist/hooks/use-form-performance.esm.js +478 -0
- package/dist/hooks/use-form-performance.js +478 -0
- package/dist/hooks/use-frame-rate.d.ts +249 -0
- package/dist/hooks/use-frame-rate.esm.js +232 -0
- package/dist/hooks/use-frame-rate.js +232 -0
- package/dist/hooks/use-gestures.d.ts +336 -0
- package/dist/hooks/use-gestures.esm.js +314 -0
- package/dist/hooks/use-gestures.js +314 -0
- package/dist/hooks/use-hardware-acceleration.d.ts +339 -0
- package/dist/hooks/use-hardware-acceleration.esm.js +313 -0
- package/dist/hooks/use-hardware-acceleration.js +313 -0
- package/dist/hooks/use-input-accessibility.d.ts +451 -0
- package/dist/hooks/use-input-accessibility.esm.js +417 -0
- package/dist/hooks/use-input-accessibility.js +417 -0
- package/dist/hooks/use-input-performance.d.ts +503 -0
- package/dist/hooks/use-input-performance.esm.js +471 -0
- package/dist/hooks/use-input-performance.js +471 -0
- package/dist/hooks/use-layout-performance.d.ts +317 -0
- package/dist/hooks/use-layout-performance.esm.js +298 -0
- package/dist/hooks/use-layout-performance.js +298 -0
- package/dist/hooks/use-loading-accessibility.d.ts +532 -0
- package/dist/hooks/use-loading-accessibility.esm.js +495 -0
- package/dist/hooks/use-loading-accessibility.js +495 -0
- package/dist/hooks/use-loading-performance.d.ts +471 -0
- package/dist/hooks/use-loading-performance.esm.js +449 -0
- package/dist/hooks/use-loading-performance.js +449 -0
- package/dist/hooks/use-memory-usage.d.ts +285 -0
- package/dist/hooks/use-memory-usage.esm.js +268 -0
- package/dist/hooks/use-memory-usage.js +268 -0
- package/dist/hooks/use-mobile-form-layout.d.ts +462 -0
- package/dist/hooks/use-mobile-form-layout.esm.js +427 -0
- package/dist/hooks/use-mobile-form-layout.js +427 -0
- package/dist/hooks/use-mobile-form-validation.d.ts +516 -0
- package/dist/hooks/use-mobile-form-validation.esm.js +451 -0
- package/dist/hooks/use-mobile-form-validation.js +451 -0
- package/dist/hooks/use-mobile-keyboard-optimization.d.ts +469 -0
- package/dist/hooks/use-mobile-keyboard-optimization.esm.js +431 -0
- package/dist/hooks/use-mobile-keyboard-optimization.js +431 -0
- package/dist/hooks/use-mobile-layout.d.ts +300 -0
- package/dist/hooks/use-mobile-layout.esm.js +280 -0
- package/dist/hooks/use-mobile-layout.js +280 -0
- package/dist/hooks/use-mobile-optimization.d.ts +404 -0
- package/dist/hooks/use-mobile-optimization.esm.js +378 -0
- package/dist/hooks/use-mobile-optimization.js +378 -0
- package/dist/hooks/use-mobile-skeleton.d.ts +399 -0
- package/dist/hooks/use-mobile-skeleton.esm.js +369 -0
- package/dist/hooks/use-mobile-skeleton.js +369 -0
- package/dist/hooks/use-mobile-touch.d.ts +412 -0
- package/dist/hooks/use-mobile-touch.esm.js +379 -0
- package/dist/hooks/use-mobile-touch.js +379 -0
- package/dist/hooks/use-performance-throttling.d.ts +346 -0
- package/dist/hooks/use-performance-throttling.esm.js +324 -0
- package/dist/hooks/use-performance-throttling.js +324 -0
- package/dist/hooks/use-performance.d.ts +314 -0
- package/dist/hooks/use-performance.esm.js +278 -0
- package/dist/hooks/use-performance.js +278 -0
- package/dist/hooks/use-reusable-architecture.d.ts +412 -0
- package/dist/hooks/use-reusable-architecture.esm.js +385 -0
- package/dist/hooks/use-reusable-architecture.js +385 -0
- package/dist/hooks/use-semantic-input-types.d.ts +354 -0
- package/dist/hooks/use-semantic-input-types.esm.js +315 -0
- package/dist/hooks/use-semantic-input-types.js +315 -0
- package/dist/hooks/use-semantic-input.d.ts +563 -0
- package/dist/hooks/use-semantic-input.esm.js +513 -0
- package/dist/hooks/use-semantic-input.js +513 -0
- package/dist/hooks/use-tablet-layout.d.ts +382 -0
- package/dist/hooks/use-tablet-layout.esm.js +355 -0
- package/dist/hooks/use-tablet-layout.js +355 -0
- package/dist/hooks/use-touch-friendly-input.d.ts +520 -0
- package/dist/hooks/use-touch-friendly-input.esm.js +480 -0
- package/dist/hooks/use-touch-friendly-input.js +480 -0
- package/dist/hooks/use-touch-friendly-interface.d.ts +329 -0
- package/dist/hooks/use-touch-friendly-interface.esm.js +299 -0
- package/dist/hooks/use-touch-friendly-interface.js +299 -0
- package/dist/hooks/use-touch-optimization.d.ts +373 -0
- package/dist/hooks/use-touch-optimization.esm.js +348 -0
- package/dist/hooks/use-touch-optimization.js +348 -0
- package/dist/lib/utils.d.ts +3 -0
- package/dist/lib/utils.esm.js +6 -0
- package/dist/lib/utils.js +6 -0
- package/dist/plugins/theme-css-generator.d.ts +345 -0
- package/dist/plugins/theme-css-generator.esm.js +305 -0
- package/dist/plugins/theme-css-generator.js +305 -0
- package/dist/styles.css +1 -1
- package/dist/themes/ThemeContext.d.ts +27 -0
- package/dist/themes/ThemeContext.esm.js +31 -0
- package/dist/themes/ThemeContext.js +31 -0
- package/dist/themes/ThemeProvider.d.ts +222 -0
- package/dist/themes/ThemeProvider.esm.js +229 -0
- package/dist/themes/ThemeProvider.js +229 -0
- package/dist/themes/accessibility/index.d.ts +7 -0
- package/dist/themes/accessibility/index.esm.js +27 -0
- package/dist/themes/accessibility/index.js +27 -0
- package/dist/themes/accessibility.d.ts +259 -0
- package/dist/themes/accessibility.esm.js +220 -0
- package/dist/themes/accessibility.js +220 -0
- package/dist/themes/aria-patterns.d.ts +418 -0
- package/dist/themes/aria-patterns.esm.js +384 -0
- package/dist/themes/aria-patterns.js +384 -0
- package/dist/themes/base-themes.d.ts +34 -0
- package/dist/themes/base-themes.esm.js +52 -0
- package/dist/themes/base-themes.js +52 -0
- package/dist/themes/colorManager.d.ts +327 -0
- package/dist/themes/colorManager.esm.js +362 -0
- package/dist/themes/colorManager.js +362 -0
- package/dist/themes/examples/dark-theme.d.ts +139 -0
- package/dist/themes/examples/dark-theme.esm.js +124 -0
- package/dist/themes/examples/dark-theme.js +124 -0
- package/dist/themes/examples/minimal-theme.d.ts +93 -0
- package/dist/themes/examples/minimal-theme.esm.js +86 -0
- package/dist/themes/examples/minimal-theme.js +86 -0
- package/dist/themes/focus-management.d.ts +699 -0
- package/dist/themes/focus-management.esm.js +642 -0
- package/dist/themes/focus-management.js +642 -0
- package/dist/themes/fontLoader.d.ts +163 -0
- package/dist/themes/fontLoader.esm.js +192 -0
- package/dist/themes/fontLoader.js +192 -0
- package/dist/themes/high-contrast.d.ts +619 -0
- package/dist/themes/high-contrast.esm.js +573 -0
- package/dist/themes/high-contrast.js +573 -0
- package/dist/themes/index.d.ts +11 -0
- package/dist/themes/index.esm.js +19 -0
- package/dist/themes/index.js +19 -0
- package/dist/themes/inheritance.d.ts +160 -0
- package/dist/themes/inheritance.esm.js +219 -0
- package/dist/themes/inheritance.js +219 -0
- package/dist/themes/keyboard-navigation.d.ts +550 -0
- package/dist/themes/keyboard-navigation.esm.js +521 -0
- package/dist/themes/keyboard-navigation.js +521 -0
- package/dist/themes/motion-reduction.d.ts +660 -0
- package/dist/themes/motion-reduction.esm.js +602 -0
- package/dist/themes/motion-reduction.js +602 -0
- package/dist/themes/navigation.d.ts +232 -0
- package/dist/themes/navigation.esm.js +238 -0
- package/dist/themes/navigation.js +238 -0
- package/dist/themes/screen-reader.d.ts +645 -0
- package/dist/themes/screen-reader.esm.js +580 -0
- package/dist/themes/screen-reader.js +580 -0
- package/dist/themes/systemThemeDetector.d.ts +148 -0
- package/dist/themes/systemThemeDetector.esm.js +174 -0
- package/dist/themes/systemThemeDetector.js +174 -0
- package/dist/themes/themeCSSUpdater.d.ts +229 -0
- package/dist/themes/themeCSSUpdater.esm.js +250 -0
- package/dist/themes/themeCSSUpdater.js +250 -0
- package/dist/themes/themePersistence.d.ts +192 -0
- package/dist/themes/themePersistence.esm.js +217 -0
- package/dist/themes/themePersistence.js +217 -0
- package/dist/themes/themes/stan-design.d.ts +678 -0
- package/dist/themes/themes/stan-design.esm.js +518 -0
- package/dist/themes/themes/stan-design.js +518 -0
- package/dist/themes/types.d.ts +454 -0
- package/dist/themes/types.esm.js +446 -0
- package/dist/themes/types.js +446 -0
- package/dist/themes/useSystemTheme.d.ts +43 -0
- package/dist/themes/useSystemTheme.esm.js +48 -0
- package/dist/themes/useSystemTheme.js +48 -0
- package/dist/themes/useTheme.d.ts +20 -0
- package/dist/themes/useTheme.esm.js +87 -0
- package/dist/themes/useTheme.js +87 -0
- package/dist/themes/validation.d.ts +406 -0
- package/dist/themes/validation.esm.js +411 -0
- package/dist/themes/validation.js +411 -0
- package/dist/tokens/index.d.ts +25 -0
- package/dist/tokens/index.esm.js +23 -0
- package/dist/tokens/index.js +23 -0
- package/dist/tokens/tokenExporter.d.ts +336 -0
- package/dist/tokens/tokenExporter.esm.js +371 -0
- package/dist/tokens/tokenExporter.js +371 -0
- package/dist/tokens/tokenGenerator.d.ts +250 -0
- package/dist/tokens/tokenGenerator.esm.js +267 -0
- package/dist/tokens/tokenGenerator.js +267 -0
- package/dist/tokens/tokenManager.d.ts +194 -0
- package/dist/tokens/tokenManager.esm.js +235 -0
- package/dist/tokens/tokenManager.js +235 -0
- package/dist/tokens/tokenValidator.d.ts +488 -0
- package/dist/tokens/tokenValidator.esm.js +497 -0
- package/dist/tokens/tokenValidator.js +497 -0
- package/dist/tokens/types.d.ts +78 -0
- package/dist/tokens/types.esm.js +64 -0
- package/dist/tokens/types.js +64 -0
- package/dist/utils/bundle-analyzer.d.ts +260 -0
- package/dist/utils/bundle-analyzer.esm.js +242 -0
- package/dist/utils/bundle-analyzer.js +242 -0
- package/dist/utils/bundle-splitting.d.ts +483 -0
- package/dist/utils/bundle-splitting.esm.js +458 -0
- package/dist/utils/bundle-splitting.js +458 -0
- package/dist/utils/lazy-loading.d.ts +437 -0
- package/dist/utils/lazy-loading.esm.js +415 -0
- package/dist/utils/lazy-loading.js +415 -0
- package/dist/utils/performance-monitor.d.ts +513 -0
- package/dist/utils/performance-monitor.esm.js +472 -0
- package/dist/utils/performance-monitor.js +472 -0
- package/dist/utils/tree-shaking.d.ts +274 -0
- package/dist/utils/tree-shaking.esm.js +266 -0
- package/dist/utils/tree-shaking.js +266 -0
- package/package.json +1 -1
|
@@ -0,0 +1,860 @@
|
|
|
1
|
+
import React, { useState, useCallback, useEffect } from 'react'
|
|
2
|
+
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from './card'
|
|
3
|
+
import { Badge } from './badge'
|
|
4
|
+
import { Button } from './button'
|
|
5
|
+
import { useAdvancedPatterns } from '../../hooks/use-advanced-patterns'
|
|
6
|
+
import { useComponentPerformance } from '../../hooks/use-component-performance'
|
|
7
|
+
import { useMobileOptimization } from '../../hooks/use-mobile-optimization'
|
|
8
|
+
import { useReusableArchitecture } from '../../hooks/use-reusable-architecture'
|
|
9
|
+
import { useAccessibilitySupport } from '../../hooks/use-accessibility-support'
|
|
10
|
+
|
|
11
|
+
export const AdvancedComponentArchitectureDemo= () => {
|
|
12
|
+
const [activeTab, setActiveTab] = useState<'patterns' | 'performance' | 'mobile' | 'architecture' | 'accessibility'>('patterns')
|
|
13
|
+
const [showPatternDemo, setShowPatternDemo] = useState(true)
|
|
14
|
+
const [showPerformanceDemo, setShowPerformanceDemo] = useState(true)
|
|
15
|
+
const [showMobileDemo, setShowMobileDemo] = useState(true)
|
|
16
|
+
const [showArchitectureDemo, setShowArchitectureDemo] = useState(true)
|
|
17
|
+
const [showAccessibilityDemo, setShowAccessibilityDemo] = useState(true)
|
|
18
|
+
|
|
19
|
+
// Hooks
|
|
20
|
+
const advancedPatterns = useAdvancedPatterns({
|
|
21
|
+
enableCompoundComponents,
|
|
22
|
+
enableRenderProps,
|
|
23
|
+
enableHigherOrderComponents,
|
|
24
|
+
enableCustomHooks,
|
|
25
|
+
enablePerformanceOptimization,
|
|
26
|
+
enableAccessibilitySupport}, {
|
|
27
|
+
onPatternApplied, component) => console.log('Pattern applied, pattern, component),
|
|
28
|
+
onPerformanceOptimized) => console.log('Performance optimized, optimization),
|
|
29
|
+
onAccessibilityEnhanced) => console.log('Accessibility enhanced, feature)
|
|
30
|
+
})
|
|
31
|
+
|
|
32
|
+
const componentPerformance = useComponentPerformance({
|
|
33
|
+
enableMemoization,
|
|
34
|
+
enableLazyLoading,
|
|
35
|
+
enableVirtualization,
|
|
36
|
+
enablePerformanceMonitoring,
|
|
37
|
+
enableAutoOptimization}, {
|
|
38
|
+
onPerformanceWarning) => console.log('Performance warning, metrics),
|
|
39
|
+
onOptimizationApplied, component) => console.log('Optimization applied, type, component),
|
|
40
|
+
onPerformanceImproved) => console.log('Performance improved, improvement),
|
|
41
|
+
onMemoryWarning) => console.log('Memory warning, usage)
|
|
42
|
+
})
|
|
43
|
+
|
|
44
|
+
const mobileOptimization = useMobileOptimization({
|
|
45
|
+
enableTouchOptimization,
|
|
46
|
+
enablePerformanceOptimization,
|
|
47
|
+
enableBatteryOptimization,
|
|
48
|
+
enableAccessibilityOptimization,
|
|
49
|
+
enableResponsiveOptimization}, {
|
|
50
|
+
onMobileOptimized) => console.log('Mobile optimized, optimization),
|
|
51
|
+
onTouchOptimized) => console.log('Touch optimized, feature),
|
|
52
|
+
onPerformanceOptimized) => console.log('Performance optimized, improvement),
|
|
53
|
+
onBatteryOptimized) => console.log('Battery optimized, strategy),
|
|
54
|
+
onAccessibilityEnhanced) => console.log('Accessibility enhanced, feature)
|
|
55
|
+
})
|
|
56
|
+
|
|
57
|
+
const reusableArchitecture = useReusableArchitecture({
|
|
58
|
+
enableComponentComposition,
|
|
59
|
+
enablePatternSharing,
|
|
60
|
+
enableStyleSharing,
|
|
61
|
+
enableBehaviorSharing,
|
|
62
|
+
enableTemplateSystem,
|
|
63
|
+
enableComponentRegistry}, {
|
|
64
|
+
onTemplateCreated) => console.log('Template created, template),
|
|
65
|
+
onPatternShared) => console.log('Pattern shared, pattern),
|
|
66
|
+
onStyleShared) => console.log('Style shared, style),
|
|
67
|
+
onBehaviorShared) => console.log('Behavior shared, behavior),
|
|
68
|
+
onArchitectureOptimized) => console.log('Architecture optimized, optimization)
|
|
69
|
+
})
|
|
70
|
+
|
|
71
|
+
const accessibilitySupport = useAccessibilitySupport({
|
|
72
|
+
enableAriaSupport,
|
|
73
|
+
enableKeyboardNavigation,
|
|
74
|
+
enableScreenReaderSupport,
|
|
75
|
+
enableFocusManagement,
|
|
76
|
+
enableHighContrast,
|
|
77
|
+
enableReducedMotion,
|
|
78
|
+
enableVoiceControl}, {
|
|
79
|
+
onAriaEnhanced) => console.log('ARIA enhanced, feature),
|
|
80
|
+
onKeyboardNavigationEnabled) => console.log('Keyboard navigation enabled, feature),
|
|
81
|
+
onScreenReaderEnhanced) => console.log('Screen reader enhanced, feature),
|
|
82
|
+
onFocusManagementImproved) => console.log('Focus management improved, feature),
|
|
83
|
+
onAccessibilityWarning) => console.log('Accessibility warning, warning)
|
|
84
|
+
})
|
|
85
|
+
|
|
86
|
+
// Demo functions
|
|
87
|
+
const demonstratePatterns = useCallback(() => {
|
|
88
|
+
// Demonstrate compound components
|
|
89
|
+
const BaseComponent = () => <div>Base Component</div>
|
|
90
|
+
const SubComponent = () => <div>Sub Component</div>
|
|
91
|
+
|
|
92
|
+
const compoundComponent = advancedPatterns.createCompoundComponent(BaseComponent, {
|
|
93
|
+
Sub})
|
|
94
|
+
|
|
95
|
+
// Demonstrate render props
|
|
96
|
+
const renderPropsData = { message}
|
|
97
|
+
const renderPropsComponent = advancedPatterns.createRenderPropsComponent({
|
|
98
|
+
data,
|
|
99
|
+
loading,
|
|
100
|
+
error,
|
|
101
|
+
render) => <div>Render Props}</div>
|
|
102
|
+
})
|
|
103
|
+
|
|
104
|
+
// Demonstrate higher-order components
|
|
105
|
+
const enhancedComponent = advancedPatterns.createHigherOrderComponent({
|
|
106
|
+
component,
|
|
107
|
+
props},
|
|
108
|
+
enhancers) => (props) => <div className="enhanced"><Component {...props} /></div>
|
|
109
|
+
]
|
|
110
|
+
})
|
|
111
|
+
|
|
112
|
+
// Demonstrate custom hooks
|
|
113
|
+
const customHookResult = advancedPatterns.createCustomHook('DemoHook', () => 'Custom Hook Result')
|
|
114
|
+
|
|
115
|
+
console.log('Patterns demonstrated, {
|
|
116
|
+
compoundComponent,
|
|
117
|
+
renderPropsComponent,
|
|
118
|
+
enhancedComponent,
|
|
119
|
+
customHookResult
|
|
120
|
+
})
|
|
121
|
+
}, [advancedPatterns])
|
|
122
|
+
|
|
123
|
+
const demonstratePerformance = useCallback(() => {
|
|
124
|
+
// Demonstrate memoization
|
|
125
|
+
const memoizedValue = componentPerformance.memoizeValue('demo', 'expensive calculation result', ['dependency1', 'dependency2'])
|
|
126
|
+
|
|
127
|
+
// Demonstrate lazy loading
|
|
128
|
+
const lazyComponent = componentPerformance.lazyLoadComponent('DemoComponent', () =>
|
|
129
|
+
Promise.resolve({ default) => <div>Lazy Loaded Component</div> })
|
|
130
|
+
)
|
|
131
|
+
|
|
132
|
+
// Demonstrate virtualization
|
|
133
|
+
const items = Array.from({ length}, (_, i) => `Item ${i}`)
|
|
134
|
+
const virtualizedList = componentPerformance.createVirtualizedList(
|
|
135
|
+
items,
|
|
136
|
+
50,
|
|
137
|
+
400,
|
|
138
|
+
(item, index) => <div key={index} className="p-2 border">{item}</div>
|
|
139
|
+
)
|
|
140
|
+
|
|
141
|
+
// Demonstrate performance measurement
|
|
142
|
+
const stopMeasurement = componentPerformance.startRenderMeasurement()
|
|
143
|
+
setTimeout(stopMeasurement, 100)
|
|
144
|
+
|
|
145
|
+
// Demonstrate auto-optimization
|
|
146
|
+
componentPerformance.autoOptimize('DemoComponent')
|
|
147
|
+
|
|
148
|
+
console.log('Performance optimizations demonstrated, {
|
|
149
|
+
memoizedValue,
|
|
150
|
+
lazyComponent,
|
|
151
|
+
virtualizedList
|
|
152
|
+
})
|
|
153
|
+
}, [componentPerformance])
|
|
154
|
+
|
|
155
|
+
const demonstrateMobileOptimization = useCallback(() => {
|
|
156
|
+
// Demonstrate touch optimization
|
|
157
|
+
mobileOptimization.optimizeTouchTargets()
|
|
158
|
+
|
|
159
|
+
// Demonstrate performance optimization
|
|
160
|
+
mobileOptimization.optimizePerformance()
|
|
161
|
+
|
|
162
|
+
// Demonstrate battery optimization
|
|
163
|
+
mobileOptimization.optimizeBattery()
|
|
164
|
+
|
|
165
|
+
// Demonstrate accessibility optimization
|
|
166
|
+
mobileOptimization.optimizeAccessibility()
|
|
167
|
+
|
|
168
|
+
// Demonstrate responsive optimization
|
|
169
|
+
mobileOptimization.optimizeResponsive()
|
|
170
|
+
|
|
171
|
+
// Demonstrate component-specific optimization
|
|
172
|
+
mobileOptimization.optimizeComponentForMobile('DemoComponent', 'touch')
|
|
173
|
+
mobileOptimization.optimizeComponentForMobile('DemoComponent', 'performance')
|
|
174
|
+
mobileOptimization.optimizeComponentForMobile('DemoComponent', 'battery')
|
|
175
|
+
mobileOptimization.optimizeComponentForMobile('DemoComponent', 'accessibility')
|
|
176
|
+
mobileOptimization.optimizeComponentForMobile('DemoComponent', 'responsive')
|
|
177
|
+
}, [mobileOptimization])
|
|
178
|
+
|
|
179
|
+
const demonstrateArchitecture = useCallback(() => {
|
|
180
|
+
// Demonstrate component composition
|
|
181
|
+
const BaseComponent = () => <div>Base Component</div>
|
|
182
|
+
const enhancedComponent = reusableArchitecture.composeComponent(BaseComponent, [
|
|
183
|
+
(Component) => (props) => <div className="enhanced"><Component {...props} /></div>,
|
|
184
|
+
(Component) => (props) => <div className="wrapped"><Component {...props} /></div>
|
|
185
|
+
])
|
|
186
|
+
|
|
187
|
+
// Demonstrate template creation
|
|
188
|
+
const templateId = reusableArchitecture.createTemplate({
|
|
189
|
+
name,
|
|
190
|
+
component,
|
|
191
|
+
props},
|
|
192
|
+
styles},
|
|
193
|
+
behaviors, 'hoverable'],
|
|
194
|
+
patterns, 'enhanced']
|
|
195
|
+
})
|
|
196
|
+
|
|
197
|
+
// Demonstrate pattern sharing
|
|
198
|
+
const patternId = reusableArchitecture.sharePattern({
|
|
199
|
+
name,
|
|
200
|
+
description,
|
|
201
|
+
implementation,
|
|
202
|
+
usage, 'Component2'],
|
|
203
|
+
category})
|
|
204
|
+
|
|
205
|
+
// Demonstrate style sharing
|
|
206
|
+
const styleId = reusableArchitecture.shareStyle({
|
|
207
|
+
name,
|
|
208
|
+
css; }',
|
|
209
|
+
variables},
|
|
210
|
+
breakpoints},
|
|
211
|
+
usage]
|
|
212
|
+
})
|
|
213
|
+
|
|
214
|
+
// Demonstrate behavior sharing
|
|
215
|
+
const behaviorId = reusableArchitecture.shareBehavior({
|
|
216
|
+
name,
|
|
217
|
+
description,
|
|
218
|
+
hook,
|
|
219
|
+
dependencies],
|
|
220
|
+
usage]
|
|
221
|
+
})
|
|
222
|
+
|
|
223
|
+
// Demonstrate component registry
|
|
224
|
+
reusableArchitecture.registerComponent('DemoComponent', BaseComponent, {
|
|
225
|
+
name,
|
|
226
|
+
description,
|
|
227
|
+
category,
|
|
228
|
+
tags, 'example']
|
|
229
|
+
})
|
|
230
|
+
|
|
231
|
+
console.log('Architecture demonstrated, {
|
|
232
|
+
enhancedComponent,
|
|
233
|
+
templateId,
|
|
234
|
+
patternId,
|
|
235
|
+
styleId,
|
|
236
|
+
behaviorId
|
|
237
|
+
})
|
|
238
|
+
}, [reusableArchitecture])
|
|
239
|
+
|
|
240
|
+
const demonstrateAccessibility = useCallback(() => {
|
|
241
|
+
// Demonstrate ARIA support
|
|
242
|
+
accessibilitySupport.enhanceAriaSupport('DemoElement', {
|
|
243
|
+
'aria-label',
|
|
244
|
+
'aria-describedby',
|
|
245
|
+
'role'})
|
|
246
|
+
|
|
247
|
+
// Demonstrate keyboard navigation
|
|
248
|
+
accessibilitySupport.enableKeyboardNavigation('DemoElement', {
|
|
249
|
+
'Enter',
|
|
250
|
+
'Space',
|
|
251
|
+
'Tab'})
|
|
252
|
+
|
|
253
|
+
// Demonstrate screen reader support
|
|
254
|
+
accessibilitySupport.enhanceScreenReaderSupport('DemoElement', 'This is a demo element for screen readers')
|
|
255
|
+
|
|
256
|
+
// Demonstrate focus management
|
|
257
|
+
accessibilitySupport.improveFocusManagement('DemoElement', 'trap')
|
|
258
|
+
|
|
259
|
+
// Demonstrate high contrast
|
|
260
|
+
accessibilitySupport.enableHighContrast()
|
|
261
|
+
|
|
262
|
+
// Demonstrate reduced motion
|
|
263
|
+
accessibilitySupport.enableReducedMotion()
|
|
264
|
+
|
|
265
|
+
// Demonstrate voice control
|
|
266
|
+
accessibilitySupport.enableVoiceControl()
|
|
267
|
+
|
|
268
|
+
// Demonstrate auto-enhancement
|
|
269
|
+
accessibilitySupport.autoEnhanceAccessibility()
|
|
270
|
+
}, [accessibilitySupport])
|
|
271
|
+
|
|
272
|
+
// Auto-demonstrate all features
|
|
273
|
+
useEffect(() => {
|
|
274
|
+
const timer = setTimeout(() => {
|
|
275
|
+
demonstratePatterns()
|
|
276
|
+
demonstratePerformance()
|
|
277
|
+
demonstrateMobileOptimization()
|
|
278
|
+
demonstrateArchitecture()
|
|
279
|
+
demonstrateAccessibility()
|
|
280
|
+
}, 1000)
|
|
281
|
+
|
|
282
|
+
return () => clearTimeout(timer)
|
|
283
|
+
}, [demonstratePatterns, demonstratePerformance, demonstrateMobileOptimization, demonstrateArchitecture, demonstrateAccessibility])
|
|
284
|
+
|
|
285
|
+
const tabs = [
|
|
286
|
+
{ id, label, icon},
|
|
287
|
+
{ id, label, icon},
|
|
288
|
+
{ id, label, icon},
|
|
289
|
+
{ id, label, icon},
|
|
290
|
+
{ id, label, icon}
|
|
291
|
+
]
|
|
292
|
+
|
|
293
|
+
return (
|
|
294
|
+
<div className="space-y-6">
|
|
295
|
+
<div className="text-center">
|
|
296
|
+
<h1 className="text-3xl font-bold text-cs-text-primary mb-2">
|
|
297
|
+
🏗️ Advanced Component Architecture & Patterns
|
|
298
|
+
</h1>
|
|
299
|
+
<p className="text-lg text-cs-text-secondary mb-4">
|
|
300
|
+
Story 10 Implementation - Sophisticated component patterns, performance optimization, mobile optimization, reusable architecture, and accessibility support
|
|
301
|
+
</p>
|
|
302
|
+
<div className="flex items-center justify-center gap-2">
|
|
303
|
+
<Badge variant="default">Story 10</Badge>
|
|
304
|
+
<Badge variant="outline">Advanced Patterns</Badge>
|
|
305
|
+
<Badge variant="secondary">Performance Optimized</Badge>
|
|
306
|
+
<Badge variant="outline">Mobile First</Badge>
|
|
307
|
+
<Badge variant="secondary">Reusable Architecture</Badge>
|
|
308
|
+
<Badge variant="outline">Accessibility First</Badge>
|
|
309
|
+
</div>
|
|
310
|
+
</div>
|
|
311
|
+
|
|
312
|
+
{/* Tab Navigation */}
|
|
313
|
+
<div className="flex flex-wrap gap-2 border-b pb-4">
|
|
314
|
+
{tabs.map((tab) => (
|
|
315
|
+
<Button
|
|
316
|
+
key={tab.id}
|
|
317
|
+
variant={activeTab === tab.id ? 'default' }
|
|
318
|
+
size="sm"
|
|
319
|
+
onClick={() => setActiveTab(tab.id as any)}
|
|
320
|
+
className="flex items-center gap-2"
|
|
321
|
+
>
|
|
322
|
+
<span>{tab.icon}</span>
|
|
323
|
+
{tab.label}
|
|
324
|
+
</Button>
|
|
325
|
+
))}
|
|
326
|
+
</div>
|
|
327
|
+
|
|
328
|
+
{/* Advanced Patterns Tab */}
|
|
329
|
+
{activeTab === 'patterns' && (
|
|
330
|
+
<Card className="border-2 border-cs-primary">
|
|
331
|
+
<CardHeader>
|
|
332
|
+
<CardTitle className="text-xl flex items-center gap-2">
|
|
333
|
+
🧩 Advanced Component Patterns
|
|
334
|
+
<Badge variant="outline">{advancedPatterns.patterns.length} Patterns</Badge>
|
|
335
|
+
</CardTitle>
|
|
336
|
+
<CardDescription>
|
|
337
|
+
Advanced component patterns including compound components, render props, higher-order components, and custom hooks
|
|
338
|
+
</CardDescription>
|
|
339
|
+
</CardHeader>
|
|
340
|
+
<CardContent className="space-y-4">
|
|
341
|
+
<div className="grid grid-cols-1 md="space-y-3">
|
|
342
|
+
<h4 className="font-medium">Pattern Status</h4>
|
|
343
|
+
<div className="space-y-2">
|
|
344
|
+
<div className="flex justify-between">
|
|
345
|
+
<span className="text-sm">Compound Components={advancedPatterns.hasPattern('Compound Components') ? 'default' }>
|
|
346
|
+
{advancedPatterns.hasPattern('Compound Components') ? 'Active' }
|
|
347
|
+
</Badge>
|
|
348
|
+
</div>
|
|
349
|
+
<div className="flex justify-between">
|
|
350
|
+
<span className="text-sm">Render Props={advancedPatterns.hasPattern('Render Props') ? 'default' }>
|
|
351
|
+
{advancedPatterns.hasPattern('Render Props') ? 'Active' }
|
|
352
|
+
</Badge>
|
|
353
|
+
</div>
|
|
354
|
+
<div className="flex justify-between">
|
|
355
|
+
<span className="text-sm">Higher-Order Components={advancedPatterns.hasPattern('Higher-Order Components') ? 'default' }>
|
|
356
|
+
{advancedPatterns.hasPattern('Higher-Order Components') ? 'Active' }
|
|
357
|
+
</Badge>
|
|
358
|
+
</div>
|
|
359
|
+
<div className="flex justify-between">
|
|
360
|
+
<span className="text-sm">Custom Hooks={advancedPatterns.hasPattern('Custom Hooks') ? 'default' }>
|
|
361
|
+
{advancedPatterns.hasPattern('Custom Hooks') ? 'Active' }
|
|
362
|
+
</Badge>
|
|
363
|
+
</div>
|
|
364
|
+
</div>
|
|
365
|
+
</div>
|
|
366
|
+
|
|
367
|
+
<div className="space-y-3">
|
|
368
|
+
<h4 className="font-medium">Pattern Analysis</h4>
|
|
369
|
+
<div className="space-y-2">
|
|
370
|
+
<div className="flex justify-between">
|
|
371
|
+
<span className="text-sm">Total Patterns="text-sm text-cs-text-secondary">{advancedPatterns.patterns.length}</span>
|
|
372
|
+
</div>
|
|
373
|
+
<div className="flex justify-between">
|
|
374
|
+
<span className="text-sm">Unique Patterns="text-sm text-cs-text-secondary">{advancedPatterns.analyzePatterns().uniquePatterns}</span>
|
|
375
|
+
</div>
|
|
376
|
+
<div className="flex justify-between">
|
|
377
|
+
<span className="text-sm">Optimization Level="outline">{advancedPatterns.patterns.length > 0 ? 'Optimized' }</Badge>
|
|
378
|
+
</div>
|
|
379
|
+
</div>
|
|
380
|
+
</div>
|
|
381
|
+
</div>
|
|
382
|
+
|
|
383
|
+
{/* Pattern Controls */}
|
|
384
|
+
<div className="flex gap-2">
|
|
385
|
+
<Button
|
|
386
|
+
variant="default"
|
|
387
|
+
onClick={demonstratePatterns}
|
|
388
|
+
disabled={advancedPatterns.isOptimizing}
|
|
389
|
+
>
|
|
390
|
+
Demonstrate Patterns
|
|
391
|
+
</Button>
|
|
392
|
+
<Button
|
|
393
|
+
variant="outline"
|
|
394
|
+
onClick={() => advancedPatterns.clearPatterns()}
|
|
395
|
+
>
|
|
396
|
+
Clear Patterns
|
|
397
|
+
</Button>
|
|
398
|
+
</div>
|
|
399
|
+
|
|
400
|
+
{/* Pattern Recommendations */}
|
|
401
|
+
{advancedPatterns.getPatternRecommendations().length > 0 && (
|
|
402
|
+
<div className="p-3 bg-cs-accent/10 rounded-lg">
|
|
403
|
+
<h4 className="font-medium text-sm mb-2">Pattern Recommendations="text-xs text-cs-text-secondary space-y-1">
|
|
404
|
+
{advancedPatterns.getPatternRecommendations().map((recommendation, index) => (
|
|
405
|
+
<li key={index}>• {recommendation}</li>
|
|
406
|
+
))}
|
|
407
|
+
</ul>
|
|
408
|
+
</div>
|
|
409
|
+
)}
|
|
410
|
+
|
|
411
|
+
{/* Pattern Validation */}
|
|
412
|
+
{advancedPatterns.validatePatterns().warnings.length > 0 && (
|
|
413
|
+
<div className="p-3 bg-yellow-50 border border-yellow-200 rounded-lg">
|
|
414
|
+
<h4 className="font-medium text-sm mb-2 text-yellow-800">Pattern Warnings="text-xs text-yellow-700 space-y-1">
|
|
415
|
+
{advancedPatterns.validatePatterns().warnings.map((warning, index) => (
|
|
416
|
+
<li key={index}>• {warning}</li>
|
|
417
|
+
))}
|
|
418
|
+
</ul>
|
|
419
|
+
</div>
|
|
420
|
+
)}
|
|
421
|
+
</CardContent>
|
|
422
|
+
</Card>
|
|
423
|
+
)}
|
|
424
|
+
|
|
425
|
+
{/* Performance Tab */}
|
|
426
|
+
{activeTab === 'performance' && (
|
|
427
|
+
<Card className="border-2 border-cs-secondary">
|
|
428
|
+
<CardHeader>
|
|
429
|
+
<CardTitle className="text-xl flex items-center gap-2">
|
|
430
|
+
⚡ Component Performance Optimization
|
|
431
|
+
<Badge variant={componentPerformance.isPerformanceOptimized() ? 'default' }>
|
|
432
|
+
{componentPerformance.isPerformanceOptimized() ? 'Optimized' }
|
|
433
|
+
</Badge>
|
|
434
|
+
</CardTitle>
|
|
435
|
+
<CardDescription>
|
|
436
|
+
Performance optimization including memoization, lazy loading, virtualization, and performance monitoring
|
|
437
|
+
</CardDescription>
|
|
438
|
+
</CardHeader>
|
|
439
|
+
<CardContent className="space-y-4">
|
|
440
|
+
<div className="grid grid-cols-2 lg="text-2xl font-bold text-cs-primary">
|
|
441
|
+
{componentPerformance.metrics.renderTime.toFixed(2)}ms
|
|
442
|
+
</p>
|
|
443
|
+
<p className="text-sm text-cs-text-secondary">Render Time</p>
|
|
444
|
+
</div>
|
|
445
|
+
<div>
|
|
446
|
+
<p className="text-2xl font-bold text-cs-secondary">
|
|
447
|
+
{componentPerformance.metrics.memoryUsage.toFixed(1)}%
|
|
448
|
+
</p>
|
|
449
|
+
<p className="text-sm text-cs-text-secondary">Memory Usage</p>
|
|
450
|
+
</div>
|
|
451
|
+
<div>
|
|
452
|
+
<p className="text-2xl font-bold text-cs-accent">
|
|
453
|
+
{componentPerformance.metrics.reRenderCount}
|
|
454
|
+
</p>
|
|
455
|
+
<p className="text-sm text-cs-text-secondary">Re-render Count</p>
|
|
456
|
+
</div>
|
|
457
|
+
<div>
|
|
458
|
+
<p className="text-2xl font-bold text-cs-primary">
|
|
459
|
+
{componentPerformance.getPerformanceScore()}
|
|
460
|
+
</p>
|
|
461
|
+
<p className="text-sm text-cs-text-secondary">Performance Score</p>
|
|
462
|
+
</div>
|
|
463
|
+
</div>
|
|
464
|
+
|
|
465
|
+
{/* Performance Controls */}
|
|
466
|
+
<div className="flex gap-2">
|
|
467
|
+
<Button
|
|
468
|
+
variant="default"
|
|
469
|
+
onClick={demonstratePerformance}
|
|
470
|
+
disabled={componentPerformance.isOptimizing}
|
|
471
|
+
>
|
|
472
|
+
Demonstrate Performance
|
|
473
|
+
</Button>
|
|
474
|
+
<Button
|
|
475
|
+
variant="outline"
|
|
476
|
+
onClick={() => componentPerformance.clearOptimizations()}
|
|
477
|
+
>
|
|
478
|
+
Clear Optimizations
|
|
479
|
+
</Button>
|
|
480
|
+
</div>
|
|
481
|
+
|
|
482
|
+
{/* Performance Analysis */}
|
|
483
|
+
<div className="p-3 bg-cs-accent/10 rounded-lg">
|
|
484
|
+
<h4 className="font-medium text-sm mb-2">Performance Analysis="grid grid-cols-2 gap-4 text-sm">
|
|
485
|
+
<div>
|
|
486
|
+
<span className="font-medium">Needs Optimization="text-cs-text-secondary">
|
|
487
|
+
{componentPerformance.analyzePerformance().needsOptimization ? 'Yes' }
|
|
488
|
+
</div>
|
|
489
|
+
</div>
|
|
490
|
+
<div>
|
|
491
|
+
<span className="font-medium">Optimization Score="text-cs-text-secondary">
|
|
492
|
+
{componentPerformance.analyzePerformance().optimizationScore.toFixed(1)}%
|
|
493
|
+
</div>
|
|
494
|
+
</div>
|
|
495
|
+
</div>
|
|
496
|
+
</div>
|
|
497
|
+
|
|
498
|
+
{/* Performance Recommendations */}
|
|
499
|
+
{componentPerformance.analyzePerformance().recommendations.length > 0 && (
|
|
500
|
+
<div className="p-3 bg-blue-50 border border-blue-200 rounded-lg">
|
|
501
|
+
<h4 className="font-medium text-sm mb-2 text-blue-800">Performance Recommendations="text-xs text-blue-700 space-y-1">
|
|
502
|
+
{componentPerformance.analyzePerformance().recommendations.map((recommendation, index) => (
|
|
503
|
+
<li key={index}>• {recommendation}</li>
|
|
504
|
+
))}
|
|
505
|
+
</ul>
|
|
506
|
+
</div>
|
|
507
|
+
)}
|
|
508
|
+
</CardContent>
|
|
509
|
+
</Card>
|
|
510
|
+
)}
|
|
511
|
+
|
|
512
|
+
{/* Mobile Optimization Tab */}
|
|
513
|
+
{activeTab === 'mobile' && (
|
|
514
|
+
<Card className="border-2 border-cs-accent">
|
|
515
|
+
<CardHeader>
|
|
516
|
+
<CardTitle className="text-xl flex items-center gap-2">
|
|
517
|
+
📱 Mobile Optimization
|
|
518
|
+
<Badge variant={mobileOptimization.isMobileOptimized() ? 'default' }>
|
|
519
|
+
{mobileOptimization.isMobileOptimized() ? 'Optimized' }
|
|
520
|
+
</Badge>
|
|
521
|
+
</CardTitle>
|
|
522
|
+
<CardDescription>
|
|
523
|
+
Mobile-specific optimizations including touch optimization, performance optimization, battery optimization, and accessibility optimization
|
|
524
|
+
</CardDescription>
|
|
525
|
+
</CardHeader>
|
|
526
|
+
<CardContent className="space-y-4">
|
|
527
|
+
<div className="grid grid-cols-1 md="space-y-3">
|
|
528
|
+
<h4 className="font-medium">Device Information</h4>
|
|
529
|
+
<div className="space-y-2">
|
|
530
|
+
<div className="flex justify-between">
|
|
531
|
+
<span className="text-sm">Device Type={mobileOptimization.state.isMobile ? 'default' }>
|
|
532
|
+
{mobileOptimization.state.isMobile ? 'Mobile' }
|
|
533
|
+
</Badge>
|
|
534
|
+
</div>
|
|
535
|
+
<div className="flex justify-between">
|
|
536
|
+
<span className="text-sm">Touch Device={mobileOptimization.state.isTouchDevice ? 'default' }>
|
|
537
|
+
{mobileOptimization.state.isTouchDevice ? 'Yes' }
|
|
538
|
+
</Badge>
|
|
539
|
+
</div>
|
|
540
|
+
<div className="flex justify-between">
|
|
541
|
+
<span className="text-sm">Screen Size="outline">{mobileOptimization.state.screenSize}</Badge>
|
|
542
|
+
</div>
|
|
543
|
+
<div className="flex justify-between">
|
|
544
|
+
<span className="text-sm">Orientation="outline">{mobileOptimization.state.orientation}</Badge>
|
|
545
|
+
</div>
|
|
546
|
+
</div>
|
|
547
|
+
</div>
|
|
548
|
+
|
|
549
|
+
<div className="space-y-3">
|
|
550
|
+
<h4 className="font-medium">Optimization Status</h4>
|
|
551
|
+
<div className="space-y-2">
|
|
552
|
+
<div className="flex justify-between">
|
|
553
|
+
<span className="text-sm">Touch Optimized="outline">{mobileOptimization.analyzeMobileOptimization().touchOptimized ? 'Yes' }</Badge>
|
|
554
|
+
</div>
|
|
555
|
+
<div className="flex justify-between">
|
|
556
|
+
<span className="text-sm">Performance Optimized="outline">{mobileOptimization.analyzeMobileOptimization().performanceOptimized ? 'Yes' }</Badge>
|
|
557
|
+
</div>
|
|
558
|
+
<div className="flex justify-between">
|
|
559
|
+
<span className="text-sm">Battery Optimized="outline">{mobileOptimization.analyzeMobileOptimization().batteryOptimized ? 'Yes' }</Badge>
|
|
560
|
+
</div>
|
|
561
|
+
<div className="flex justify-between">
|
|
562
|
+
<span className="text-sm">Accessibility Optimized="outline">{mobileOptimization.analyzeMobileOptimization().accessibilityOptimized ? 'Yes' }</Badge>
|
|
563
|
+
</div>
|
|
564
|
+
</div>
|
|
565
|
+
</div>
|
|
566
|
+
</div>
|
|
567
|
+
|
|
568
|
+
{/* Mobile Controls */}
|
|
569
|
+
<div className="flex gap-2">
|
|
570
|
+
<Button
|
|
571
|
+
variant="default"
|
|
572
|
+
onClick={demonstrateMobileOptimization}
|
|
573
|
+
disabled={mobileOptimization.isOptimizing}
|
|
574
|
+
>
|
|
575
|
+
Demonstrate Mobile Optimization
|
|
576
|
+
</Button>
|
|
577
|
+
<Button
|
|
578
|
+
variant="outline"
|
|
579
|
+
onClick={() => mobileOptimization.clearOptimizations()}
|
|
580
|
+
>
|
|
581
|
+
Clear Optimizations
|
|
582
|
+
</Button>
|
|
583
|
+
</div>
|
|
584
|
+
|
|
585
|
+
{/* Mobile Recommendations */}
|
|
586
|
+
{mobileOptimization.analyzeMobileOptimization().recommendations.length > 0 && (
|
|
587
|
+
<div className="p-3 bg-green-50 border border-green-200 rounded-lg">
|
|
588
|
+
<h4 className="font-medium text-sm mb-2 text-green-800">Mobile Optimization Recommendations="text-xs text-green-700 space-y-1">
|
|
589
|
+
{mobileOptimization.analyzeMobileOptimization().recommendations.map((recommendation, index) => (
|
|
590
|
+
<li key={index}>• {recommendation}</li>
|
|
591
|
+
))}
|
|
592
|
+
</ul>
|
|
593
|
+
</div>
|
|
594
|
+
)}
|
|
595
|
+
</CardContent>
|
|
596
|
+
</Card>
|
|
597
|
+
)}
|
|
598
|
+
|
|
599
|
+
{/* Reusable Architecture Tab */}
|
|
600
|
+
{activeTab === 'architecture' && (
|
|
601
|
+
<Card className="border-2 border-cs-primary">
|
|
602
|
+
<CardHeader>
|
|
603
|
+
<CardTitle className="text-xl flex items-center gap-2">
|
|
604
|
+
🏗️ Reusable Component Architecture
|
|
605
|
+
<Badge variant="outline">{reusableArchitecture.templates.length} Templates</Badge>
|
|
606
|
+
</CardTitle>
|
|
607
|
+
<CardDescription>
|
|
608
|
+
Reusable component architecture including component composition, pattern sharing, style sharing, and behavior sharing
|
|
609
|
+
</CardDescription>
|
|
610
|
+
</CardHeader>
|
|
611
|
+
<CardContent className="space-y-4">
|
|
612
|
+
<div className="grid grid-cols-2 lg="text-2xl font-bold text-cs-primary">
|
|
613
|
+
{reusableArchitecture.templates.length}
|
|
614
|
+
</p>
|
|
615
|
+
<p className="text-sm text-cs-text-secondary">Templates</p>
|
|
616
|
+
</div>
|
|
617
|
+
<div>
|
|
618
|
+
<p className="text-2xl font-bold text-cs-secondary">
|
|
619
|
+
{reusableArchitecture.sharedPatterns.length}
|
|
620
|
+
</p>
|
|
621
|
+
<p className="text-sm text-cs-text-secondary">Shared Patterns</p>
|
|
622
|
+
</div>
|
|
623
|
+
<div>
|
|
624
|
+
<p className="text-2xl font-bold text-cs-accent">
|
|
625
|
+
{reusableArchitecture.sharedStyles.length}
|
|
626
|
+
</p>
|
|
627
|
+
<p className="text-sm text-cs-text-secondary">Shared Styles</p>
|
|
628
|
+
</div>
|
|
629
|
+
<div>
|
|
630
|
+
<p className="text-2xl font-bold text-cs-primary">
|
|
631
|
+
{reusableArchitecture.sharedBehaviors.length}
|
|
632
|
+
</p>
|
|
633
|
+
<p className="text-sm text-cs-text-secondary">Shared Behaviors</p>
|
|
634
|
+
</div>
|
|
635
|
+
</div>
|
|
636
|
+
|
|
637
|
+
{/* Architecture Controls */}
|
|
638
|
+
<div className="flex gap-2">
|
|
639
|
+
<Button
|
|
640
|
+
variant="default"
|
|
641
|
+
onClick={demonstrateArchitecture}
|
|
642
|
+
disabled={reusableArchitecture.isOptimizing}
|
|
643
|
+
>
|
|
644
|
+
Demonstrate Architecture
|
|
645
|
+
</Button>
|
|
646
|
+
<Button
|
|
647
|
+
variant="outline"
|
|
648
|
+
onClick={() => reusableArchitecture.clearOptimizations()}
|
|
649
|
+
>
|
|
650
|
+
Clear Optimizations
|
|
651
|
+
</Button>
|
|
652
|
+
</div>
|
|
653
|
+
|
|
654
|
+
{/* Architecture Analysis */}
|
|
655
|
+
<div className="p-3 bg-cs-accent/10 rounded-lg">
|
|
656
|
+
<h4 className="font-medium text-sm mb-2">Architecture Analysis="grid grid-cols-2 gap-4 text-sm">
|
|
657
|
+
<div>
|
|
658
|
+
<span className="font-medium">Composition Level="text-cs-text-secondary">
|
|
659
|
+
{reusableArchitecture.analyzeArchitecture().compositionLevel}
|
|
660
|
+
</div>
|
|
661
|
+
</div>
|
|
662
|
+
<div>
|
|
663
|
+
<span className="font-medium">Reusability Score="text-cs-text-secondary">
|
|
664
|
+
{reusableArchitecture.analyzeArchitecture().reusabilityScore.toFixed(1)}%
|
|
665
|
+
</div>
|
|
666
|
+
</div>
|
|
667
|
+
</div>
|
|
668
|
+
</div>
|
|
669
|
+
|
|
670
|
+
{/* Architecture Recommendations */}
|
|
671
|
+
{reusableArchitecture.analyzeArchitecture().recommendations.length > 0 && (
|
|
672
|
+
<div className="p-3 bg-blue-50 border border-blue-200 rounded-lg">
|
|
673
|
+
<h4 className="font-medium text-sm mb-2 text-blue-800">Architecture Recommendations="text-xs text-blue-700 space-y-1">
|
|
674
|
+
{reusableArchitecture.analyzeArchitecture().recommendations.map((recommendation, index) => (
|
|
675
|
+
<li key={index}>• {recommendation}</li>
|
|
676
|
+
))}
|
|
677
|
+
</ul>
|
|
678
|
+
</div>
|
|
679
|
+
)}
|
|
680
|
+
</CardContent>
|
|
681
|
+
</Card>
|
|
682
|
+
)}
|
|
683
|
+
|
|
684
|
+
{/* Accessibility Tab */}
|
|
685
|
+
{activeTab === 'accessibility' && (
|
|
686
|
+
<Card className="border-2 border-cs-secondary">
|
|
687
|
+
<CardHeader>
|
|
688
|
+
<CardTitle className="text-xl flex items-center gap-2">
|
|
689
|
+
♿ Accessibility Support
|
|
690
|
+
<Badge variant={accessibilitySupport.isAccessibilityEnhanced() ? 'default' }>
|
|
691
|
+
{accessibilitySupport.isAccessibilityEnhanced() ? 'Enhanced' }
|
|
692
|
+
</Badge>
|
|
693
|
+
</CardTitle>
|
|
694
|
+
<CardDescription>
|
|
695
|
+
Accessibility support including ARIA support, keyboard navigation, screen reader support, and focus management
|
|
696
|
+
</CardDescription>
|
|
697
|
+
</CardHeader>
|
|
698
|
+
<CardContent className="space-y-4">
|
|
699
|
+
<div className="grid grid-cols-1 md="space-y-3">
|
|
700
|
+
<h4 className="font-medium">Accessibility Features</h4>
|
|
701
|
+
<div className="space-y-2">
|
|
702
|
+
<div className="flex justify-between">
|
|
703
|
+
<span className="text-sm">ARIA Support={accessibilitySupport.state.hasAriaLabels ? 'default' }>
|
|
704
|
+
{accessibilitySupport.state.hasAriaLabels ? 'Enabled' }
|
|
705
|
+
</Badge>
|
|
706
|
+
</div>
|
|
707
|
+
<div className="flex justify-between">
|
|
708
|
+
<span className="text-sm">Keyboard Navigation={accessibilitySupport.state.hasKeyboardNavigation ? 'default' }>
|
|
709
|
+
{accessibilitySupport.state.hasKeyboardNavigation ? 'Enabled' }
|
|
710
|
+
</Badge>
|
|
711
|
+
</div>
|
|
712
|
+
<div className="flex justify-between">
|
|
713
|
+
<span className="text-sm">Screen Reader={accessibilitySupport.state.hasScreenReaderSupport ? 'default' }>
|
|
714
|
+
{accessibilitySupport.state.hasScreenReaderSupport ? 'Enabled' }
|
|
715
|
+
</Badge>
|
|
716
|
+
</div>
|
|
717
|
+
<div className="flex justify-between">
|
|
718
|
+
<span className="text-sm">Focus Management={accessibilitySupport.state.hasFocusManagement ? 'default' }>
|
|
719
|
+
{accessibilitySupport.state.hasFocusManagement ? 'Enabled' }
|
|
720
|
+
</Badge>
|
|
721
|
+
</div>
|
|
722
|
+
</div>
|
|
723
|
+
</div>
|
|
724
|
+
|
|
725
|
+
<div className="space-y-3">
|
|
726
|
+
<h4 className="font-medium">Accessibility Preferences</h4>
|
|
727
|
+
<div className="space-y-2">
|
|
728
|
+
<div className="flex justify-between">
|
|
729
|
+
<span className="text-sm">High Contrast={accessibilitySupport.state.isHighContrast ? 'default' }>
|
|
730
|
+
{accessibilitySupport.state.isHighContrast ? 'Enabled' }
|
|
731
|
+
</Badge>
|
|
732
|
+
</div>
|
|
733
|
+
<div className="flex justify-between">
|
|
734
|
+
<span className="text-sm">Reduced Motion={accessibilitySupport.state.isReducedMotion ? 'default' }>
|
|
735
|
+
{accessibilitySupport.state.isReducedMotion ? 'Enabled' }
|
|
736
|
+
</Badge>
|
|
737
|
+
</div>
|
|
738
|
+
<div className="flex justify-between">
|
|
739
|
+
<span className="text-sm">Voice Control={accessibilitySupport.state.isVoiceControlEnabled ? 'default' }>
|
|
740
|
+
{accessibilitySupport.state.isVoiceControlEnabled ? 'Enabled' }
|
|
741
|
+
</Badge>
|
|
742
|
+
</div>
|
|
743
|
+
<div className="flex justify-between">
|
|
744
|
+
<span className="text-sm">Accessibility Level="outline">{accessibilitySupport.state.accessibilityLevel}</Badge>
|
|
745
|
+
</div>
|
|
746
|
+
</div>
|
|
747
|
+
</div>
|
|
748
|
+
</div>
|
|
749
|
+
|
|
750
|
+
{/* Accessibility Controls */}
|
|
751
|
+
<div className="flex gap-2">
|
|
752
|
+
<Button
|
|
753
|
+
variant="default"
|
|
754
|
+
onClick={demonstrateAccessibility}
|
|
755
|
+
disabled={accessibilitySupport.isEnhancing}
|
|
756
|
+
>
|
|
757
|
+
Demonstrate Accessibility
|
|
758
|
+
</Button>
|
|
759
|
+
<Button
|
|
760
|
+
variant="outline"
|
|
761
|
+
onClick={() => accessibilitySupport.clearEnhancements()}
|
|
762
|
+
>
|
|
763
|
+
Clear Enhancements
|
|
764
|
+
</Button>
|
|
765
|
+
</div>
|
|
766
|
+
|
|
767
|
+
{/* Accessibility Analysis */}
|
|
768
|
+
<div className="p-3 bg-cs-accent/10 rounded-lg">
|
|
769
|
+
<h4 className="font-medium text-sm mb-2">Accessibility Analysis="grid grid-cols-2 gap-4 text-sm">
|
|
770
|
+
<div>
|
|
771
|
+
<span className="font-medium">Accessibility Level="text-cs-text-secondary">
|
|
772
|
+
{accessibilitySupport.analyzeAccessibility().level}
|
|
773
|
+
</div>
|
|
774
|
+
</div>
|
|
775
|
+
<div>
|
|
776
|
+
<span className="font-medium">Feature Coverage="text-cs-text-secondary">
|
|
777
|
+
{accessibilitySupport.analyzeAccessibility().coverage.toFixed(1)}%
|
|
778
|
+
</div>
|
|
779
|
+
</div>
|
|
780
|
+
</div>
|
|
781
|
+
</div>
|
|
782
|
+
|
|
783
|
+
{/* Accessibility Recommendations */}
|
|
784
|
+
{accessibilitySupport.analyzeAccessibility().recommendations.length > 0 && (
|
|
785
|
+
<div className="p-3 bg-green-50 border border-green-200 rounded-lg">
|
|
786
|
+
<h4 className="font-medium text-sm mb-2 text-green-800">Accessibility Recommendations="text-xs text-green-700 space-y-1">
|
|
787
|
+
{accessibilitySupport.analyzeAccessibility().recommendations.map((recommendation, index) => (
|
|
788
|
+
<li key={index}>• {recommendation}</li>
|
|
789
|
+
))}
|
|
790
|
+
</ul>
|
|
791
|
+
</div>
|
|
792
|
+
)}
|
|
793
|
+
|
|
794
|
+
{/* Accessibility Warnings */}
|
|
795
|
+
{accessibilitySupport.accessibilityWarnings.length > 0 && (
|
|
796
|
+
<div className="p-3 bg-yellow-50 border border-yellow-200 rounded-lg">
|
|
797
|
+
<h4 className="font-medium text-sm mb-2 text-yellow-800">Accessibility Warnings="text-xs text-yellow-700 space-y-1">
|
|
798
|
+
{accessibilitySupport.accessibilityWarnings.map((warning, index) => (
|
|
799
|
+
<li key={index}>• {warning}</li>
|
|
800
|
+
))}
|
|
801
|
+
</ul>
|
|
802
|
+
</div>
|
|
803
|
+
)}
|
|
804
|
+
</CardContent>
|
|
805
|
+
</Card>
|
|
806
|
+
)}
|
|
807
|
+
|
|
808
|
+
{/* Demo Controls */}
|
|
809
|
+
<Card className="border border-cs-border">
|
|
810
|
+
<CardHeader>
|
|
811
|
+
<CardTitle className="text-lg">Demo Controls</CardTitle>
|
|
812
|
+
<CardDescription>
|
|
813
|
+
Configure and test different advanced component architecture features
|
|
814
|
+
</CardDescription>
|
|
815
|
+
</CardHeader>
|
|
816
|
+
<CardContent className="space-y-4">
|
|
817
|
+
<div className="flex flex-wrap gap-4">
|
|
818
|
+
<Button
|
|
819
|
+
variant={showPatternDemo ? 'default' }
|
|
820
|
+
size="sm"
|
|
821
|
+
onClick={() => setShowPatternDemo(!showPatternDemo)}
|
|
822
|
+
>
|
|
823
|
+
{showPatternDemo ? 'Hide' } Pattern Demo
|
|
824
|
+
</Button>
|
|
825
|
+
<Button
|
|
826
|
+
variant={showPerformanceDemo ? 'default' }
|
|
827
|
+
size="sm"
|
|
828
|
+
onClick={() => setShowPerformanceDemo(!showPerformanceDemo)}
|
|
829
|
+
>
|
|
830
|
+
{showPerformanceDemo ? 'Hide' } Performance Demo
|
|
831
|
+
</Button>
|
|
832
|
+
<Button
|
|
833
|
+
variant={showMobileDemo ? 'default' }
|
|
834
|
+
size="sm"
|
|
835
|
+
onClick={() => setShowMobileDemo(!showMobileDemo)}
|
|
836
|
+
>
|
|
837
|
+
{showMobileDemo ? 'Hide' } Mobile Demo
|
|
838
|
+
</Button>
|
|
839
|
+
<Button
|
|
840
|
+
variant={showArchitectureDemo ? 'default' }
|
|
841
|
+
size="sm"
|
|
842
|
+
onClick={() => setShowArchitectureDemo(!showArchitectureDemo)}
|
|
843
|
+
>
|
|
844
|
+
{showArchitectureDemo ? 'Hide' } Architecture Demo
|
|
845
|
+
</Button>
|
|
846
|
+
<Button
|
|
847
|
+
variant={showAccessibilityDemo ? 'default' }
|
|
848
|
+
size="sm"
|
|
849
|
+
onClick={() => setShowAccessibilityDemo(!showAccessibilityDemo)}
|
|
850
|
+
>
|
|
851
|
+
{showAccessibilityDemo ? 'Hide' } Accessibility Demo
|
|
852
|
+
</Button>
|
|
853
|
+
</div>
|
|
854
|
+
</CardContent>
|
|
855
|
+
</Card>
|
|
856
|
+
</div>
|
|
857
|
+
)
|
|
858
|
+
}
|
|
859
|
+
|
|
860
|
+
export default AdvancedComponentArchitectureDemo
|