@rakeyshgidwani/roger-ui-bank-theme-harvey 0.2.52 → 0.3.0
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/button.d.ts +3 -1
- package/dist/components/ui/button.d.ts.map +1 -1
- package/dist/components/ui/button.esm.js +3 -2
- package/dist/components/ui/button.js +3 -2
- package/dist/components/ui/layout/container.d.ts +57 -0
- package/dist/components/ui/layout/container.d.ts.map +1 -0
- package/dist/components/ui/layout/container.esm.js +173 -0
- package/dist/components/ui/layout/container.js +173 -0
- package/dist/components/ui/layout/index.d.ts +9 -0
- package/dist/components/ui/layout/index.d.ts.map +1 -0
- package/dist/components/ui/layout/index.esm.js +6 -0
- package/dist/components/ui/layout/index.js +6 -0
- package/dist/components/ui/layout/responsive-grid.d.ts +93 -0
- package/dist/components/ui/layout/responsive-grid.d.ts.map +1 -0
- package/dist/components/ui/layout/responsive-grid.esm.js +124 -0
- package/dist/components/ui/layout/responsive-grid.js +124 -0
- package/dist/components/ui/navigation/index.d.ts +2 -1
- package/dist/components/ui/navigation/index.d.ts.map +1 -1
- package/dist/components/ui/navigation/index.esm.js +1 -0
- package/dist/components/ui/navigation/index.js +1 -0
- package/dist/components/ui/navigation/progressive-navigation.d.ts +37 -0
- package/dist/components/ui/navigation/progressive-navigation.d.ts.map +1 -0
- package/dist/components/ui/navigation/progressive-navigation.esm.js +145 -0
- package/dist/components/ui/navigation/progressive-navigation.js +145 -0
- package/dist/components/ui/navigation/types.d.ts +21 -0
- package/dist/components/ui/navigation/types.d.ts.map +1 -1
- package/dist/hooks/use-adaptive-layout.d.ts +2 -1
- package/dist/hooks/use-adaptive-layout.d.ts.map +1 -1
- package/dist/hooks/use-adaptive-layout.esm.js +13 -8
- package/dist/hooks/use-adaptive-layout.js +13 -8
- package/dist/hooks/use-device.d.ts +3 -1
- package/dist/hooks/use-device.d.ts.map +1 -1
- package/dist/hooks/use-device.esm.js +14 -7
- package/dist/hooks/use-device.js +14 -7
- package/dist/index.d.ts +19 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.esm.js +9 -4
- package/dist/index.js +9 -4
- package/dist/plugins/css-purge-optimizer.d.ts +25 -0
- package/dist/plugins/css-purge-optimizer.d.ts.map +1 -0
- package/dist/plugins/css-purge-optimizer.esm.js +414 -0
- package/dist/plugins/css-purge-optimizer.js +414 -0
- package/dist/plugins/performance-monitor.d.ts +29 -0
- package/dist/plugins/performance-monitor.d.ts.map +1 -0
- package/dist/plugins/performance-monitor.esm.js +221 -0
- package/dist/plugins/performance-monitor.js +221 -0
- package/dist/plugins/progressive-css-loader.d.ts +21 -0
- package/dist/plugins/progressive-css-loader.d.ts.map +1 -0
- package/dist/plugins/progressive-css-loader.esm.js +227 -0
- package/dist/plugins/progressive-css-loader.js +227 -0
- package/dist/plugins/theme-css-generator.d.ts.map +1 -1
- package/dist/plugins/theme-css-generator.esm.js +19 -6
- package/dist/plugins/theme-css-generator.js +19 -6
- package/dist/styles.css +1025 -110
- package/dist/theme.d.ts.map +1 -1
- package/dist/theme.esm.js +4 -1
- package/dist/theme.js +4 -1
- package/dist/themes/phase1-constants.d.ts +23 -0
- package/dist/themes/phase1-constants.d.ts.map +1 -0
- package/dist/themes/phase1-constants.esm.js +180 -0
- package/dist/themes/phase1-constants.js +180 -0
- package/dist/themes/themes/default.d.ts.map +1 -1
- package/dist/themes/themes/default.esm.js +4 -1
- package/dist/themes/themes/default.js +4 -1
- package/dist/themes/themes/harvey.d.ts.map +1 -1
- package/dist/themes/themes/harvey.esm.js +4 -1
- package/dist/themes/themes/harvey.js +4 -1
- package/dist/themes/types.d.ts +62 -0
- package/dist/themes/types.d.ts.map +1 -1
- package/dist/themes/validation.d.ts +17 -0
- package/dist/themes/validation.d.ts.map +1 -1
- package/dist/themes/validation.esm.js +218 -0
- package/dist/themes/validation.js +218 -0
- package/dist/types.d.ts +62 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/progressive-css-injector.d.ts +80 -0
- package/dist/utils/progressive-css-injector.d.ts.map +1 -0
- package/dist/utils/progressive-css-injector.esm.js +217 -0
- package/dist/utils/progressive-css-injector.js +217 -0
- package/package.json +1 -1
- package/src/components/ui/button.tsx +9 -6
- package/src/components/ui/layout/container.tsx +312 -0
- package/src/components/ui/layout/index.ts +10 -0
- package/src/components/ui/layout/responsive-grid.tsx +286 -0
- package/src/components/ui/navigation/index.ts +2 -0
- package/src/components/ui/navigation/progressive-navigation.tsx +453 -0
- package/src/components/ui/navigation/types.ts +41 -0
- package/src/hooks/use-adaptive-layout.ts +13 -9
- package/src/hooks/use-device.tsx +17 -10
- package/src/index.ts +19 -4
- package/src/plugins/css-purge-optimizer.ts +491 -0
- package/src/plugins/performance-monitor.ts +292 -0
- package/src/plugins/progressive-css-loader.ts +269 -0
- package/src/plugins/theme-css-generator.ts +22 -6
- package/src/styles/components/base/badge.css +2 -2
- package/src/styles/components/base/button.css +238 -35
- package/src/styles/components/base/card.css +2 -2
- package/src/styles/components/base/checkbox.css +3 -3
- package/src/styles/components/base/label.css +3 -3
- package/src/styles/components/feedback/skeleton.css +1 -1
- package/src/styles/components/feedback/toast.css +1 -1
- package/src/styles/components/index.css +3 -0
- package/src/styles/components/layout/container.css +466 -0
- package/src/styles/components/layout/index.css +5 -0
- package/src/styles/components/layout/responsive-grid.css +422 -0
- package/src/styles/components/navigation/breadcrumb.css +1 -1
- package/src/styles/components/navigation/index.css +1 -0
- package/src/styles/components/navigation/menu.css +2 -2
- package/src/styles/components/navigation/pagination.css +4 -4
- package/src/styles/components/navigation/progressive-navigation.css +633 -0
- package/src/styles/components/navigation/sidebar.css +4 -4
- package/src/styles/components/navigation/stepper.css +2 -2
- package/src/styles/components/navigation/tabs.css +1 -1
- package/src/styles/progressive.css +17 -0
- package/src/styles/themes/harvey.css +103 -19
- package/src/styles/utilities/semantic-input-system.css +7 -13
- package/src/theme.ts +5 -1
- package/src/themes/phase1-constants.ts +189 -0
- package/src/themes/themes/default.ts +5 -1
- package/src/themes/themes/harvey.ts +5 -1
- package/src/themes/types.ts +77 -1
- package/src/themes/validation.ts +249 -0
- package/src/types.ts +77 -1
- package/src/utils/progressive-css-injector.ts +254 -0
|
@@ -10,6 +10,11 @@ export class ThemeValidator {
|
|
|
10
10
|
const warnings = [];
|
|
11
11
|
// Validate required fields
|
|
12
12
|
this.validateRequiredFields(theme, errors);
|
|
13
|
+
// Phase 1 Enhancement: Validate new foundation primitives
|
|
14
|
+
this.validatePhase1RequiredFields(theme, errors);
|
|
15
|
+
this.validateBreakpointSystem(theme, errors, warnings);
|
|
16
|
+
this.validateContentDensitySystem(theme, errors, warnings);
|
|
17
|
+
this.validateResponsiveTypographySystem(theme, errors, warnings);
|
|
13
18
|
// Validate color formats
|
|
14
19
|
this.validateColorFormats(theme, errors, warnings);
|
|
15
20
|
// Validate color contrast
|
|
@@ -380,6 +385,196 @@ export class ThemeValidator {
|
|
|
380
385
|
return false;
|
|
381
386
|
}
|
|
382
387
|
}
|
|
388
|
+
// Phase 1 Enhancement: New validation methods for foundation primitives
|
|
389
|
+
/**
|
|
390
|
+
* Validate Phase 1 required fields
|
|
391
|
+
*/
|
|
392
|
+
static validatePhase1RequiredFields(theme, errors) {
|
|
393
|
+
this.PHASE1_REQUIRED_FIELDS.forEach(fieldPath => {
|
|
394
|
+
const value = this.getNestedValue(theme, fieldPath);
|
|
395
|
+
if (value === undefined || value === null || value === '') {
|
|
396
|
+
errors.push({
|
|
397
|
+
path: fieldPath,
|
|
398
|
+
message: `Required Phase 1 field '${fieldPath}' is missing`,
|
|
399
|
+
severity: 'critical'
|
|
400
|
+
});
|
|
401
|
+
}
|
|
402
|
+
});
|
|
403
|
+
}
|
|
404
|
+
/**
|
|
405
|
+
* Validate enhanced breakpoint system
|
|
406
|
+
*/
|
|
407
|
+
static validateBreakpointSystem(theme, errors, warnings) {
|
|
408
|
+
if (!theme.breakpoints) {
|
|
409
|
+
errors.push({
|
|
410
|
+
path: 'breakpoints',
|
|
411
|
+
message: 'Breakpoint system is required for Phase 1 compliance',
|
|
412
|
+
severity: 'critical'
|
|
413
|
+
});
|
|
414
|
+
return;
|
|
415
|
+
}
|
|
416
|
+
const requiredBreakpoints = ['xs', 'sm', 'md', 'lg', 'xl', '2xl', '3xl'];
|
|
417
|
+
const expectedValues = {
|
|
418
|
+
xs: '475px',
|
|
419
|
+
sm: '640px',
|
|
420
|
+
md: '768px',
|
|
421
|
+
lg: '1024px',
|
|
422
|
+
xl: '1280px',
|
|
423
|
+
'2xl': '1536px',
|
|
424
|
+
'3xl': '1920px'
|
|
425
|
+
};
|
|
426
|
+
requiredBreakpoints.forEach(breakpoint => {
|
|
427
|
+
const value = theme.breakpoints[breakpoint];
|
|
428
|
+
if (!value) {
|
|
429
|
+
errors.push({
|
|
430
|
+
path: `breakpoints.${breakpoint}`,
|
|
431
|
+
message: `Breakpoint '${breakpoint}' is required`,
|
|
432
|
+
severity: 'error'
|
|
433
|
+
});
|
|
434
|
+
}
|
|
435
|
+
else {
|
|
436
|
+
// Validate format (should end with 'px')
|
|
437
|
+
if (!value.endsWith('px')) {
|
|
438
|
+
warnings.push({
|
|
439
|
+
path: `breakpoints.${breakpoint}`,
|
|
440
|
+
message: `Breakpoint '${breakpoint}' should use px units`,
|
|
441
|
+
severity: 'warning'
|
|
442
|
+
});
|
|
443
|
+
}
|
|
444
|
+
// Validate expected values for consistency
|
|
445
|
+
if (value !== expectedValues[breakpoint]) {
|
|
446
|
+
warnings.push({
|
|
447
|
+
path: `breakpoints.${breakpoint}`,
|
|
448
|
+
message: `Breakpoint '${breakpoint}' value '${value}' differs from specification '${expectedValues[breakpoint]}'`,
|
|
449
|
+
severity: 'info'
|
|
450
|
+
});
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
});
|
|
454
|
+
}
|
|
455
|
+
/**
|
|
456
|
+
* Validate content density system
|
|
457
|
+
*/
|
|
458
|
+
static validateContentDensitySystem(theme, errors, warnings) {
|
|
459
|
+
if (!theme.contentDensity) {
|
|
460
|
+
errors.push({
|
|
461
|
+
path: 'contentDensity',
|
|
462
|
+
message: 'Content density system is required for Phase 1 compliance',
|
|
463
|
+
severity: 'critical'
|
|
464
|
+
});
|
|
465
|
+
return;
|
|
466
|
+
}
|
|
467
|
+
const densityLevels = ['compact', 'comfortable', 'spacious'];
|
|
468
|
+
densityLevels.forEach(level => {
|
|
469
|
+
const density = theme.contentDensity[level];
|
|
470
|
+
if (!density) {
|
|
471
|
+
errors.push({
|
|
472
|
+
path: `contentDensity.${level}`,
|
|
473
|
+
message: `Density level '${level}' is required`,
|
|
474
|
+
severity: 'error'
|
|
475
|
+
});
|
|
476
|
+
return;
|
|
477
|
+
}
|
|
478
|
+
// Validate spacing structure
|
|
479
|
+
if (!density.spacing) {
|
|
480
|
+
errors.push({
|
|
481
|
+
path: `contentDensity.${level}.spacing`,
|
|
482
|
+
message: `Spacing configuration is required for density level '${level}'`,
|
|
483
|
+
severity: 'error'
|
|
484
|
+
});
|
|
485
|
+
}
|
|
486
|
+
else {
|
|
487
|
+
['section', 'component', 'element'].forEach(spacingType => {
|
|
488
|
+
const spacingValue = density.spacing[spacingType];
|
|
489
|
+
if (!spacingValue) {
|
|
490
|
+
warnings.push({
|
|
491
|
+
path: `contentDensity.${level}.spacing.${spacingType}`,
|
|
492
|
+
message: `Spacing type '${spacingType}' is recommended for density level '${level}'`,
|
|
493
|
+
severity: 'warning'
|
|
494
|
+
});
|
|
495
|
+
}
|
|
496
|
+
});
|
|
497
|
+
}
|
|
498
|
+
// Validate typography structure
|
|
499
|
+
if (!density.typography) {
|
|
500
|
+
errors.push({
|
|
501
|
+
path: `contentDensity.${level}.typography`,
|
|
502
|
+
message: `Typography configuration is required for density level '${level}'`,
|
|
503
|
+
severity: 'error'
|
|
504
|
+
});
|
|
505
|
+
}
|
|
506
|
+
else {
|
|
507
|
+
if (typeof density.typography.scale !== 'number') {
|
|
508
|
+
errors.push({
|
|
509
|
+
path: `contentDensity.${level}.typography.scale`,
|
|
510
|
+
message: `Typography scale must be a number for density level '${level}'`,
|
|
511
|
+
severity: 'error'
|
|
512
|
+
});
|
|
513
|
+
}
|
|
514
|
+
if (typeof density.typography.lineHeight !== 'number') {
|
|
515
|
+
errors.push({
|
|
516
|
+
path: `contentDensity.${level}.typography.lineHeight`,
|
|
517
|
+
message: `Typography lineHeight must be a number for density level '${level}'`,
|
|
518
|
+
severity: 'error'
|
|
519
|
+
});
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
// Validate touch targets for mobile-focused densities
|
|
523
|
+
if (level === 'compact' && !density.touchTargets) {
|
|
524
|
+
warnings.push({
|
|
525
|
+
path: `contentDensity.${level}.touchTargets`,
|
|
526
|
+
message: `Touch targets configuration is recommended for compact density level`,
|
|
527
|
+
severity: 'warning'
|
|
528
|
+
});
|
|
529
|
+
}
|
|
530
|
+
});
|
|
531
|
+
}
|
|
532
|
+
/**
|
|
533
|
+
* Validate responsive typography system
|
|
534
|
+
*/
|
|
535
|
+
static validateResponsiveTypographySystem(theme, errors, warnings) {
|
|
536
|
+
if (!theme.responsiveTypography) {
|
|
537
|
+
errors.push({
|
|
538
|
+
path: 'responsiveTypography',
|
|
539
|
+
message: 'Responsive typography system is required for Phase 1 compliance',
|
|
540
|
+
severity: 'critical'
|
|
541
|
+
});
|
|
542
|
+
return;
|
|
543
|
+
}
|
|
544
|
+
const typographyLevels = ['heading1', 'heading2', 'heading3', 'heading4', 'heading5', 'heading6', 'body', 'bodyLarge', 'bodySmall', 'caption'];
|
|
545
|
+
const breakpoints = ['xs', 'sm', 'md', 'lg', 'xl', '2xl', '3xl'];
|
|
546
|
+
typographyLevels.forEach(level => {
|
|
547
|
+
const typography = theme.responsiveTypography[level];
|
|
548
|
+
if (!typography) {
|
|
549
|
+
warnings.push({
|
|
550
|
+
path: `responsiveTypography.${level}`,
|
|
551
|
+
message: `Typography level '${level}' is recommended for complete responsive scaling`,
|
|
552
|
+
severity: 'warning'
|
|
553
|
+
});
|
|
554
|
+
return;
|
|
555
|
+
}
|
|
556
|
+
breakpoints.forEach(breakpoint => {
|
|
557
|
+
const value = typography[breakpoint];
|
|
558
|
+
if (!value) {
|
|
559
|
+
warnings.push({
|
|
560
|
+
path: `responsiveTypography.${level}.${breakpoint}`,
|
|
561
|
+
message: `Breakpoint '${breakpoint}' is missing for typography level '${level}'`,
|
|
562
|
+
severity: 'warning'
|
|
563
|
+
});
|
|
564
|
+
}
|
|
565
|
+
else {
|
|
566
|
+
// Validate format (should end with 'px' or be a number)
|
|
567
|
+
if (typeof value === 'string' && !value.endsWith('px') && !value.endsWith('rem') && !value.endsWith('em')) {
|
|
568
|
+
warnings.push({
|
|
569
|
+
path: `responsiveTypography.${level}.${breakpoint}`,
|
|
570
|
+
message: `Typography value should include units (px, rem, or em) for '${level}.${breakpoint}'`,
|
|
571
|
+
severity: 'warning'
|
|
572
|
+
});
|
|
573
|
+
}
|
|
574
|
+
}
|
|
575
|
+
});
|
|
576
|
+
});
|
|
577
|
+
}
|
|
383
578
|
}
|
|
384
579
|
ThemeValidator.REQUIRED_FIELDS = [
|
|
385
580
|
'fonts.primary.family',
|
|
@@ -399,6 +594,29 @@ ThemeValidator.REQUIRED_FIELDS = [
|
|
|
399
594
|
'meta.description',
|
|
400
595
|
'meta.version'
|
|
401
596
|
];
|
|
597
|
+
// Phase 1 Enhancement: Required fields for new foundation primitives
|
|
598
|
+
ThemeValidator.PHASE1_REQUIRED_FIELDS = [
|
|
599
|
+
// Enhanced Breakpoint System
|
|
600
|
+
'breakpoints.xs',
|
|
601
|
+
'breakpoints.sm',
|
|
602
|
+
'breakpoints.md',
|
|
603
|
+
'breakpoints.lg',
|
|
604
|
+
'breakpoints.xl',
|
|
605
|
+
'breakpoints.2xl',
|
|
606
|
+
'breakpoints.3xl',
|
|
607
|
+
// Content Density System
|
|
608
|
+
'contentDensity.compact.spacing.section',
|
|
609
|
+
'contentDensity.compact.typography.scale',
|
|
610
|
+
'contentDensity.comfortable.spacing.section',
|
|
611
|
+
'contentDensity.comfortable.typography.scale',
|
|
612
|
+
'contentDensity.spacious.spacing.section',
|
|
613
|
+
'contentDensity.spacious.typography.scale',
|
|
614
|
+
// Responsive Typography System
|
|
615
|
+
'responsiveTypography.heading1.xs',
|
|
616
|
+
'responsiveTypography.heading1.3xl',
|
|
617
|
+
'responsiveTypography.body.xs',
|
|
618
|
+
'responsiveTypography.body.3xl'
|
|
619
|
+
];
|
|
402
620
|
ThemeValidator.COLOR_FORMATS = {
|
|
403
621
|
hex: /^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,
|
|
404
622
|
rgb: /^rgb\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*\)$/,
|
|
@@ -10,6 +10,11 @@ export class ThemeValidator {
|
|
|
10
10
|
const warnings = [];
|
|
11
11
|
// Validate required fields
|
|
12
12
|
this.validateRequiredFields(theme, errors);
|
|
13
|
+
// Phase 1 Enhancement: Validate new foundation primitives
|
|
14
|
+
this.validatePhase1RequiredFields(theme, errors);
|
|
15
|
+
this.validateBreakpointSystem(theme, errors, warnings);
|
|
16
|
+
this.validateContentDensitySystem(theme, errors, warnings);
|
|
17
|
+
this.validateResponsiveTypographySystem(theme, errors, warnings);
|
|
13
18
|
// Validate color formats
|
|
14
19
|
this.validateColorFormats(theme, errors, warnings);
|
|
15
20
|
// Validate color contrast
|
|
@@ -380,6 +385,196 @@ export class ThemeValidator {
|
|
|
380
385
|
return false;
|
|
381
386
|
}
|
|
382
387
|
}
|
|
388
|
+
// Phase 1 Enhancement: New validation methods for foundation primitives
|
|
389
|
+
/**
|
|
390
|
+
* Validate Phase 1 required fields
|
|
391
|
+
*/
|
|
392
|
+
static validatePhase1RequiredFields(theme, errors) {
|
|
393
|
+
this.PHASE1_REQUIRED_FIELDS.forEach(fieldPath => {
|
|
394
|
+
const value = this.getNestedValue(theme, fieldPath);
|
|
395
|
+
if (value === undefined || value === null || value === '') {
|
|
396
|
+
errors.push({
|
|
397
|
+
path: fieldPath,
|
|
398
|
+
message: `Required Phase 1 field '${fieldPath}' is missing`,
|
|
399
|
+
severity: 'critical'
|
|
400
|
+
});
|
|
401
|
+
}
|
|
402
|
+
});
|
|
403
|
+
}
|
|
404
|
+
/**
|
|
405
|
+
* Validate enhanced breakpoint system
|
|
406
|
+
*/
|
|
407
|
+
static validateBreakpointSystem(theme, errors, warnings) {
|
|
408
|
+
if (!theme.breakpoints) {
|
|
409
|
+
errors.push({
|
|
410
|
+
path: 'breakpoints',
|
|
411
|
+
message: 'Breakpoint system is required for Phase 1 compliance',
|
|
412
|
+
severity: 'critical'
|
|
413
|
+
});
|
|
414
|
+
return;
|
|
415
|
+
}
|
|
416
|
+
const requiredBreakpoints = ['xs', 'sm', 'md', 'lg', 'xl', '2xl', '3xl'];
|
|
417
|
+
const expectedValues = {
|
|
418
|
+
xs: '475px',
|
|
419
|
+
sm: '640px',
|
|
420
|
+
md: '768px',
|
|
421
|
+
lg: '1024px',
|
|
422
|
+
xl: '1280px',
|
|
423
|
+
'2xl': '1536px',
|
|
424
|
+
'3xl': '1920px'
|
|
425
|
+
};
|
|
426
|
+
requiredBreakpoints.forEach(breakpoint => {
|
|
427
|
+
const value = theme.breakpoints[breakpoint];
|
|
428
|
+
if (!value) {
|
|
429
|
+
errors.push({
|
|
430
|
+
path: `breakpoints.${breakpoint}`,
|
|
431
|
+
message: `Breakpoint '${breakpoint}' is required`,
|
|
432
|
+
severity: 'error'
|
|
433
|
+
});
|
|
434
|
+
}
|
|
435
|
+
else {
|
|
436
|
+
// Validate format (should end with 'px')
|
|
437
|
+
if (!value.endsWith('px')) {
|
|
438
|
+
warnings.push({
|
|
439
|
+
path: `breakpoints.${breakpoint}`,
|
|
440
|
+
message: `Breakpoint '${breakpoint}' should use px units`,
|
|
441
|
+
severity: 'warning'
|
|
442
|
+
});
|
|
443
|
+
}
|
|
444
|
+
// Validate expected values for consistency
|
|
445
|
+
if (value !== expectedValues[breakpoint]) {
|
|
446
|
+
warnings.push({
|
|
447
|
+
path: `breakpoints.${breakpoint}`,
|
|
448
|
+
message: `Breakpoint '${breakpoint}' value '${value}' differs from specification '${expectedValues[breakpoint]}'`,
|
|
449
|
+
severity: 'info'
|
|
450
|
+
});
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
});
|
|
454
|
+
}
|
|
455
|
+
/**
|
|
456
|
+
* Validate content density system
|
|
457
|
+
*/
|
|
458
|
+
static validateContentDensitySystem(theme, errors, warnings) {
|
|
459
|
+
if (!theme.contentDensity) {
|
|
460
|
+
errors.push({
|
|
461
|
+
path: 'contentDensity',
|
|
462
|
+
message: 'Content density system is required for Phase 1 compliance',
|
|
463
|
+
severity: 'critical'
|
|
464
|
+
});
|
|
465
|
+
return;
|
|
466
|
+
}
|
|
467
|
+
const densityLevels = ['compact', 'comfortable', 'spacious'];
|
|
468
|
+
densityLevels.forEach(level => {
|
|
469
|
+
const density = theme.contentDensity[level];
|
|
470
|
+
if (!density) {
|
|
471
|
+
errors.push({
|
|
472
|
+
path: `contentDensity.${level}`,
|
|
473
|
+
message: `Density level '${level}' is required`,
|
|
474
|
+
severity: 'error'
|
|
475
|
+
});
|
|
476
|
+
return;
|
|
477
|
+
}
|
|
478
|
+
// Validate spacing structure
|
|
479
|
+
if (!density.spacing) {
|
|
480
|
+
errors.push({
|
|
481
|
+
path: `contentDensity.${level}.spacing`,
|
|
482
|
+
message: `Spacing configuration is required for density level '${level}'`,
|
|
483
|
+
severity: 'error'
|
|
484
|
+
});
|
|
485
|
+
}
|
|
486
|
+
else {
|
|
487
|
+
['section', 'component', 'element'].forEach(spacingType => {
|
|
488
|
+
const spacingValue = density.spacing[spacingType];
|
|
489
|
+
if (!spacingValue) {
|
|
490
|
+
warnings.push({
|
|
491
|
+
path: `contentDensity.${level}.spacing.${spacingType}`,
|
|
492
|
+
message: `Spacing type '${spacingType}' is recommended for density level '${level}'`,
|
|
493
|
+
severity: 'warning'
|
|
494
|
+
});
|
|
495
|
+
}
|
|
496
|
+
});
|
|
497
|
+
}
|
|
498
|
+
// Validate typography structure
|
|
499
|
+
if (!density.typography) {
|
|
500
|
+
errors.push({
|
|
501
|
+
path: `contentDensity.${level}.typography`,
|
|
502
|
+
message: `Typography configuration is required for density level '${level}'`,
|
|
503
|
+
severity: 'error'
|
|
504
|
+
});
|
|
505
|
+
}
|
|
506
|
+
else {
|
|
507
|
+
if (typeof density.typography.scale !== 'number') {
|
|
508
|
+
errors.push({
|
|
509
|
+
path: `contentDensity.${level}.typography.scale`,
|
|
510
|
+
message: `Typography scale must be a number for density level '${level}'`,
|
|
511
|
+
severity: 'error'
|
|
512
|
+
});
|
|
513
|
+
}
|
|
514
|
+
if (typeof density.typography.lineHeight !== 'number') {
|
|
515
|
+
errors.push({
|
|
516
|
+
path: `contentDensity.${level}.typography.lineHeight`,
|
|
517
|
+
message: `Typography lineHeight must be a number for density level '${level}'`,
|
|
518
|
+
severity: 'error'
|
|
519
|
+
});
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
// Validate touch targets for mobile-focused densities
|
|
523
|
+
if (level === 'compact' && !density.touchTargets) {
|
|
524
|
+
warnings.push({
|
|
525
|
+
path: `contentDensity.${level}.touchTargets`,
|
|
526
|
+
message: `Touch targets configuration is recommended for compact density level`,
|
|
527
|
+
severity: 'warning'
|
|
528
|
+
});
|
|
529
|
+
}
|
|
530
|
+
});
|
|
531
|
+
}
|
|
532
|
+
/**
|
|
533
|
+
* Validate responsive typography system
|
|
534
|
+
*/
|
|
535
|
+
static validateResponsiveTypographySystem(theme, errors, warnings) {
|
|
536
|
+
if (!theme.responsiveTypography) {
|
|
537
|
+
errors.push({
|
|
538
|
+
path: 'responsiveTypography',
|
|
539
|
+
message: 'Responsive typography system is required for Phase 1 compliance',
|
|
540
|
+
severity: 'critical'
|
|
541
|
+
});
|
|
542
|
+
return;
|
|
543
|
+
}
|
|
544
|
+
const typographyLevels = ['heading1', 'heading2', 'heading3', 'heading4', 'heading5', 'heading6', 'body', 'bodyLarge', 'bodySmall', 'caption'];
|
|
545
|
+
const breakpoints = ['xs', 'sm', 'md', 'lg', 'xl', '2xl', '3xl'];
|
|
546
|
+
typographyLevels.forEach(level => {
|
|
547
|
+
const typography = theme.responsiveTypography[level];
|
|
548
|
+
if (!typography) {
|
|
549
|
+
warnings.push({
|
|
550
|
+
path: `responsiveTypography.${level}`,
|
|
551
|
+
message: `Typography level '${level}' is recommended for complete responsive scaling`,
|
|
552
|
+
severity: 'warning'
|
|
553
|
+
});
|
|
554
|
+
return;
|
|
555
|
+
}
|
|
556
|
+
breakpoints.forEach(breakpoint => {
|
|
557
|
+
const value = typography[breakpoint];
|
|
558
|
+
if (!value) {
|
|
559
|
+
warnings.push({
|
|
560
|
+
path: `responsiveTypography.${level}.${breakpoint}`,
|
|
561
|
+
message: `Breakpoint '${breakpoint}' is missing for typography level '${level}'`,
|
|
562
|
+
severity: 'warning'
|
|
563
|
+
});
|
|
564
|
+
}
|
|
565
|
+
else {
|
|
566
|
+
// Validate format (should end with 'px' or be a number)
|
|
567
|
+
if (typeof value === 'string' && !value.endsWith('px') && !value.endsWith('rem') && !value.endsWith('em')) {
|
|
568
|
+
warnings.push({
|
|
569
|
+
path: `responsiveTypography.${level}.${breakpoint}`,
|
|
570
|
+
message: `Typography value should include units (px, rem, or em) for '${level}.${breakpoint}'`,
|
|
571
|
+
severity: 'warning'
|
|
572
|
+
});
|
|
573
|
+
}
|
|
574
|
+
}
|
|
575
|
+
});
|
|
576
|
+
});
|
|
577
|
+
}
|
|
383
578
|
}
|
|
384
579
|
ThemeValidator.REQUIRED_FIELDS = [
|
|
385
580
|
'fonts.primary.family',
|
|
@@ -399,6 +594,29 @@ ThemeValidator.REQUIRED_FIELDS = [
|
|
|
399
594
|
'meta.description',
|
|
400
595
|
'meta.version'
|
|
401
596
|
];
|
|
597
|
+
// Phase 1 Enhancement: Required fields for new foundation primitives
|
|
598
|
+
ThemeValidator.PHASE1_REQUIRED_FIELDS = [
|
|
599
|
+
// Enhanced Breakpoint System
|
|
600
|
+
'breakpoints.xs',
|
|
601
|
+
'breakpoints.sm',
|
|
602
|
+
'breakpoints.md',
|
|
603
|
+
'breakpoints.lg',
|
|
604
|
+
'breakpoints.xl',
|
|
605
|
+
'breakpoints.2xl',
|
|
606
|
+
'breakpoints.3xl',
|
|
607
|
+
// Content Density System
|
|
608
|
+
'contentDensity.compact.spacing.section',
|
|
609
|
+
'contentDensity.compact.typography.scale',
|
|
610
|
+
'contentDensity.comfortable.spacing.section',
|
|
611
|
+
'contentDensity.comfortable.typography.scale',
|
|
612
|
+
'contentDensity.spacious.spacing.section',
|
|
613
|
+
'contentDensity.spacious.typography.scale',
|
|
614
|
+
// Responsive Typography System
|
|
615
|
+
'responsiveTypography.heading1.xs',
|
|
616
|
+
'responsiveTypography.heading1.3xl',
|
|
617
|
+
'responsiveTypography.body.xs',
|
|
618
|
+
'responsiveTypography.body.3xl'
|
|
619
|
+
];
|
|
402
620
|
ThemeValidator.COLOR_FORMATS = {
|
|
403
621
|
hex: /^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,
|
|
404
622
|
rgb: /^rgb\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*\)$/,
|
package/dist/types.d.ts
CHANGED
|
@@ -16,6 +16,9 @@ export interface MultiThemeConfig {
|
|
|
16
16
|
shimmer: ShimmerThemeConfig;
|
|
17
17
|
meta: ThemeMetadata;
|
|
18
18
|
extends?: string;
|
|
19
|
+
breakpoints?: BreakpointThemeConfig;
|
|
20
|
+
contentDensity?: ContentDensityThemeConfig;
|
|
21
|
+
responsiveTypography?: ResponsiveTypographyThemeConfig;
|
|
19
22
|
modes?: {
|
|
20
23
|
light?: {
|
|
21
24
|
colors?: Partial<ColorThemeConfig>;
|
|
@@ -397,4 +400,63 @@ export interface CompleteThemeConfig extends MultiThemeConfig {
|
|
|
397
400
|
inheritance?: ThemeInheritance;
|
|
398
401
|
validation: ThemeValidationResult;
|
|
399
402
|
}
|
|
403
|
+
export interface BreakpointThemeConfig {
|
|
404
|
+
xs: string;
|
|
405
|
+
sm: string;
|
|
406
|
+
md: string;
|
|
407
|
+
lg: string;
|
|
408
|
+
xl: string;
|
|
409
|
+
'2xl': string;
|
|
410
|
+
'3xl': string;
|
|
411
|
+
}
|
|
412
|
+
export interface ContentDensityThemeConfig {
|
|
413
|
+
compact: DensityLevel;
|
|
414
|
+
comfortable: DensityLevel;
|
|
415
|
+
spacious: DensityLevel;
|
|
416
|
+
}
|
|
417
|
+
export interface DensityLevel {
|
|
418
|
+
spacing: DensitySpacing;
|
|
419
|
+
typography: DensityTypography;
|
|
420
|
+
touchTargets?: DensityTouchTargets;
|
|
421
|
+
interactions?: DensityInteractions;
|
|
422
|
+
}
|
|
423
|
+
export interface DensitySpacing {
|
|
424
|
+
section: string;
|
|
425
|
+
component: string;
|
|
426
|
+
element: string;
|
|
427
|
+
}
|
|
428
|
+
export interface DensityTypography {
|
|
429
|
+
scale: number;
|
|
430
|
+
lineHeight: number;
|
|
431
|
+
}
|
|
432
|
+
export interface DensityTouchTargets {
|
|
433
|
+
minimum: string;
|
|
434
|
+
preferred: string;
|
|
435
|
+
}
|
|
436
|
+
export interface DensityInteractions {
|
|
437
|
+
hover?: boolean;
|
|
438
|
+
tooltips?: boolean;
|
|
439
|
+
shortcuts?: boolean;
|
|
440
|
+
}
|
|
441
|
+
export interface ResponsiveTypographyThemeConfig {
|
|
442
|
+
heading1: ResponsiveTypographyScale;
|
|
443
|
+
heading2: ResponsiveTypographyScale;
|
|
444
|
+
heading3: ResponsiveTypographyScale;
|
|
445
|
+
heading4: ResponsiveTypographyScale;
|
|
446
|
+
heading5: ResponsiveTypographyScale;
|
|
447
|
+
heading6: ResponsiveTypographyScale;
|
|
448
|
+
body: ResponsiveTypographyScale;
|
|
449
|
+
bodyLarge: ResponsiveTypographyScale;
|
|
450
|
+
bodySmall: ResponsiveTypographyScale;
|
|
451
|
+
caption: ResponsiveTypographyScale;
|
|
452
|
+
}
|
|
453
|
+
export interface ResponsiveTypographyScale {
|
|
454
|
+
xs: string;
|
|
455
|
+
sm: string;
|
|
456
|
+
md: string;
|
|
457
|
+
lg: string;
|
|
458
|
+
xl: string;
|
|
459
|
+
'2xl': string;
|
|
460
|
+
'3xl': string;
|
|
461
|
+
}
|
|
400
462
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,SAAS,GAAG,SAAS,GAAG,aAAa,GAAG,QAAQ,GAAG,YAAY,GAAG,MAAM,CAAC;AAErF,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,eAAe,CAAC;IACvB,MAAM,EAAE,gBAAgB,CAAC;IACzB,UAAU,EAAE,qBAAqB,CAAC;IAClC,OAAO,EAAE,kBAAkB,CAAC;IAC5B,OAAO,EAAE,iBAAiB,CAAC;IAC3B,WAAW,EAAE,qBAAqB,CAAC;IACnC,YAAY,EAAE,uBAAuB,CAAC;IACtC,WAAW,EAAE,sBAAsB,CAAC;IACpC,SAAS,EAAE,oBAAoB,CAAC;IAChC,aAAa,EAAE,wBAAwB,CAAC;IACxC,KAAK,EAAE,gBAAgB,CAAC;IACxB,cAAc,EAAE,yBAAyB,CAAC;IAC1C,SAAS,EAAE,oBAAoB,CAAC;IAChC,OAAO,EAAE,kBAAkB,CAAC;IAC5B,IAAI,EAAE,aAAa,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IAGjB,KAAK,CAAC,EAAE;QACN,KAAK,CAAC,EAAE;YACN,MAAM,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,CAAC;SACpC,CAAC;QACF,IAAI,CAAC,EAAE;YACL,MAAM,CAAC,EAAE,OAAO,CAAC,gBAAgB,CAAC,CAAC;SACpC,CAAC;KACH,CAAC;CACH;AAED,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,UAAU,CAAC;IACpB,SAAS,EAAE,U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cAAc;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,mBAAmB;IAClC,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAGD,MAAM,WAAW,+BAA+B;IAC9C,QAAQ,EAAE,yBAAyB,CAAC;IACpC,QAAQ,EAAE,yBAAyB,CAAC;IACpC,QAAQ,EAAE,yBAAyB,CAAC;IACpC,QAAQ,EAAE,yBAAyB,CAAC;IACpC,QAAQ,EAAE,yBAAyB,CAAC;IACpC,QAAQ,EAAE,yBAAyB,CAAC;IACpC,IAAI,EAAE,yBAAyB,CAAC;IAChC,SAAS,EAAE,yBAAyB,CAAC;IACrC,SAAS,EAAE,yBAAyB,CAAC;IACrC,OAAO,EAAE,yBAAyB,CAAC;CACpC;AAED,MAAM,WAAW,yBAAyB;IACxC,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf"}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Progressive CSS Injector
|
|
3
|
+
* Runtime utility to load progressive CSS for desktop enhancement
|
|
4
|
+
*
|
|
5
|
+
* This is a simplified, production-ready approach that:
|
|
6
|
+
* 1. Detects desktop viewport (>= 1024px)
|
|
7
|
+
* 2. Dynamically loads progressive.css
|
|
8
|
+
* 3. Handles viewport changes and preloading
|
|
9
|
+
*/
|
|
10
|
+
interface ProgressiveLoaderConfig {
|
|
11
|
+
desktopBreakpoint: number;
|
|
12
|
+
progressiveCSSPath: string;
|
|
13
|
+
enablePreload: boolean;
|
|
14
|
+
enableViewportDetection: boolean;
|
|
15
|
+
}
|
|
16
|
+
declare class ProgressiveCSSInjector {
|
|
17
|
+
private config;
|
|
18
|
+
private isLoaded;
|
|
19
|
+
private linkElement;
|
|
20
|
+
private preloadElement;
|
|
21
|
+
constructor(config?: Partial<ProgressiveLoaderConfig>);
|
|
22
|
+
/**
|
|
23
|
+
* Initialize the progressive CSS loader
|
|
24
|
+
*/
|
|
25
|
+
init(): void;
|
|
26
|
+
/**
|
|
27
|
+
* Initialize progressive CSS features
|
|
28
|
+
*/
|
|
29
|
+
private initializeFeatures;
|
|
30
|
+
/**
|
|
31
|
+
* Check if the progressive CSS file exists
|
|
32
|
+
*/
|
|
33
|
+
private checkFileExists;
|
|
34
|
+
/**
|
|
35
|
+
* Check viewport and load progressive CSS if needed
|
|
36
|
+
*/
|
|
37
|
+
private checkAndLoadProgressiveCSS;
|
|
38
|
+
/**
|
|
39
|
+
* Load progressive CSS
|
|
40
|
+
*/
|
|
41
|
+
private loadProgressiveCSS;
|
|
42
|
+
/**
|
|
43
|
+
* Unload progressive CSS (for mobile/tablet)
|
|
44
|
+
*/
|
|
45
|
+
private unloadProgressiveCSS;
|
|
46
|
+
/**
|
|
47
|
+
* Setup viewport change listener
|
|
48
|
+
*/
|
|
49
|
+
private setupViewportListener;
|
|
50
|
+
/**
|
|
51
|
+
* Setup preloading for fast desktop switches
|
|
52
|
+
*/
|
|
53
|
+
private setupPreloading;
|
|
54
|
+
/**
|
|
55
|
+
* Cleanup resources
|
|
56
|
+
*/
|
|
57
|
+
private cleanup;
|
|
58
|
+
/**
|
|
59
|
+
* Force load progressive CSS (for testing/debugging)
|
|
60
|
+
*/
|
|
61
|
+
forceLoad(): void;
|
|
62
|
+
/**
|
|
63
|
+
* Force unload progressive CSS (for testing/debugging)
|
|
64
|
+
*/
|
|
65
|
+
forceUnload(): void;
|
|
66
|
+
/**
|
|
67
|
+
* Get current load status
|
|
68
|
+
*/
|
|
69
|
+
getStatus(): {
|
|
70
|
+
isLoaded: boolean;
|
|
71
|
+
hasLinkElement: boolean;
|
|
72
|
+
hasPreloadElement: boolean;
|
|
73
|
+
currentViewport: number;
|
|
74
|
+
isDesktopViewport: boolean;
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
export declare const progressiveLoader: ProgressiveCSSInjector;
|
|
78
|
+
export { ProgressiveCSSInjector };
|
|
79
|
+
export declare function initializeProgressiveCSS(config?: Partial<ProgressiveLoaderConfig>): void;
|
|
80
|
+
//# sourceMappingURL=progressive-css-injector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"progressive-css-injector.d.ts","sourceRoot":"","sources":["../../src/utils/progressive-css-injector.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,UAAU,uBAAuB;IAC/B,iBAAiB,EAAE,MAAM,CAAA;IACzB,kBAAkB,EAAE,MAAM,CAAA;IAC1B,aAAa,EAAE,OAAO,CAAA;IACtB,uBAAuB,EAAE,OAAO,CAAA;CACjC;AASD,cAAM,sBAAsB;IAC1B,OAAO,CAAC,MAAM,CAAyB;IACvC,OAAO,CAAC,QAAQ,CAAQ;IACxB,OAAO,CAAC,WAAW,CAA+B;IAClD,OAAO,CAAC,cAAc,CAA+B;gBAEzC,MAAM,GAAE,OAAO,CAAC,uBAAuB,CAAM;IAIzD;;OAEG;IACH,IAAI,IAAI,IAAI;IAgCZ;;OAEG;IACH,OAAO,CAAC,kBAAkB;IAe1B;;OAEG;YACW,eAAe;IAS7B;;OAEG;IACH,OAAO,CAAC,0BAA0B;IAUlC;;OAEG;IACH,OAAO,CAAC,kBAAkB;IAqB1B;;OAEG;IACH,OAAO,CAAC,oBAAoB;IAS5B;;OAEG;IACH,OAAO,CAAC,qBAAqB;IAa7B;;OAEG;IACH,OAAO,CAAC,eAAe;IAavB;;OAEG;IACH,OAAO,CAAC,OAAO;IAWf;;OAEG;IACH,SAAS,IAAI,IAAI;IAIjB;;OAEG;IACH,WAAW,IAAI,IAAI;IAInB;;OAEG;IACH,SAAS;;;;;;;CASV;AAGD,eAAO,MAAM,iBAAiB,wBAA+B,CAAA;AAG7D,OAAO,EAAE,sBAAsB,EAAE,CAAA;AAGjC,wBAAgB,wBAAwB,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,uBAAuB,CAAC,GAAG,IAAI,CAwBxF"}
|