@smilodon/core 1.10.0 → 1.10.1

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.
Files changed (52) hide show
  1. package/README.md +130 -371
  2. package/dist/index.cjs +1918 -20
  3. package/dist/index.cjs.map +1 -1
  4. package/dist/index.js +1918 -21
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.min.js +1 -1
  7. package/dist/index.min.js.map +1 -1
  8. package/dist/index.umd.js +1918 -20
  9. package/dist/index.umd.js.map +1 -1
  10. package/dist/index.umd.min.js +1 -1
  11. package/dist/index.umd.min.js.map +1 -1
  12. package/dist/types/src/components/enhanced-select.d.ts +70 -7
  13. package/dist/types/src/components/native-select.d.ts +1 -1
  14. package/dist/types/src/components/select-option.d.ts +2 -2
  15. package/dist/types/src/config/global-config.d.ts +5 -3
  16. package/dist/types/src/data-loading/public-config.d.ts +3 -0
  17. package/dist/types/src/data-loading/public-types.d.ts +171 -0
  18. package/dist/types/src/data-loading/request-coordinator.d.ts +236 -0
  19. package/dist/types/src/index.d.ts +2 -0
  20. package/dist/types/src/native-types.d.ts +5 -0
  21. package/dist/types/src/renderers/contracts.d.ts +1 -1
  22. package/dist/types/src/types/limitation.d.ts +6 -0
  23. package/dist/types/src/types.d.ts +2 -6
  24. package/dist/types/src/utils/custom-option-pool.d.ts +1 -1
  25. package/package.json +7 -4
  26. package/dist/types/src/themes/importer.d.ts +0 -112
  27. package/dist/types/tests/accessibility-contract.spec.d.ts +0 -1
  28. package/dist/types/tests/capabilities-tracking.spec.d.ts +0 -1
  29. package/dist/types/tests/csp.spec.d.ts +0 -5
  30. package/dist/types/tests/enhanced-option-renderer.spec.d.ts +0 -1
  31. package/dist/types/tests/enhanced-select-accessibility-integration.spec.d.ts +0 -1
  32. package/dist/types/tests/enhanced-select-active-authority.spec.d.ts +0 -1
  33. package/dist/types/tests/enhanced-select-active-parity.spec.d.ts +0 -1
  34. package/dist/types/tests/enhanced-select-authority.spec.d.ts +0 -1
  35. package/dist/types/tests/enhanced-select-compatibility-projection.spec.d.ts +0 -1
  36. package/dist/types/tests/enhanced-select-selection-parity.spec.d.ts +0 -1
  37. package/dist/types/tests/enhanced-select-virtualization-integration.spec.d.ts +0 -1
  38. package/dist/types/tests/interaction.spec.d.ts +0 -1
  39. package/dist/types/tests/item-adapter.spec.d.ts +0 -1
  40. package/dist/types/tests/item-registry.spec.d.ts +0 -1
  41. package/dist/types/tests/lifecycle.spec.d.ts +0 -1
  42. package/dist/types/tests/memory-lifecycle.spec.d.ts +0 -1
  43. package/dist/types/tests/select-accessibility.spec.d.ts +0 -1
  44. package/dist/types/tests/select-selection.spec.d.ts +0 -1
  45. package/dist/types/tests/setup.d.ts +0 -6
  46. package/dist/types/tests/shadow-dom.spec.d.ts +0 -5
  47. package/dist/types/tests/smoke.spec.d.ts +0 -1
  48. package/dist/types/tests/stress.spec.d.ts +0 -5
  49. package/dist/types/tests/styling-contract.spec.d.ts +0 -1
  50. package/dist/types/tests/virtualization-contract.spec.d.ts +0 -1
  51. package/dist/types/tests/virtualizer.spec.d.ts +0 -1
  52. package/dist/types/tests/web-accessibility-effects.spec.d.ts +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smilodon/core",
3
- "version": "1.10.0",
3
+ "version": "1.10.1",
4
4
  "description": "High-performance native select component with extreme-scale virtualization - React, Vue, Svelte, Vanilla JS",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -12,6 +12,9 @@
12
12
  "import": "./dist/index.js",
13
13
  "require": "./dist/index.cjs"
14
14
  },
15
+ "./native-types": {
16
+ "types": "./dist/types/src/native-types.d.ts"
17
+ },
15
18
  "./package.json": "./package.json"
16
19
  },
17
20
  "files": [
@@ -19,7 +22,7 @@
19
22
  "README.md"
20
23
  ],
21
24
  "scripts": {
22
- "build": "rollup -c && tsc --emitDeclarationOnly --outDir dist/types",
25
+ "build": "rollup -c && tsc --project tsconfig.build.json --emitDeclarationOnly --outDir dist/types",
23
26
  "dev": "rollup -c --watch",
24
27
  "test": "vitest run",
25
28
  "test:watch": "vitest",
@@ -56,12 +59,12 @@
56
59
  },
57
60
  "devDependencies": {
58
61
  "@rollup/plugin-node-resolve": "^15.2.3",
59
- "@rollup/plugin-terser": "^0.4.4",
62
+ "@rollup/plugin-terser": "^1.0.2",
60
63
  "@rollup/plugin-typescript": "^11.1.6",
61
64
  "jsdom": "^24.0.0",
62
65
  "rollup": "^4.9.0",
63
66
  "typescript": "^5.6.2",
64
- "vitest": "^1.6.0"
67
+ "vitest": "4.1.12"
65
68
  },
66
69
  "sideEffects": [
67
70
  "./src/components/enhanced-select.ts",
@@ -1,112 +0,0 @@
1
- /**
2
- * Design Token Importer
3
- * Convert design tokens from Figma, Adobe XD, and other design tools to CSS variables
4
- *
5
- * Supports:
6
- * - Figma Variables API
7
- * - Adobe XD Design Tokens
8
- * - Design Tokens Format (W3C Community Group spec)
9
- * - Style Dictionary format
10
- *
11
- * Usage:
12
- * import { importTokens, applyTokens } from '@smilodon/core/themes/importer';
13
- *
14
- * const tokens = await importTokens('figma', figmaData);
15
- * applyTokens(selectElement, tokens);
16
- */
17
- /**
18
- * Design token types
19
- */
20
- export interface DesignToken {
21
- $type?: string;
22
- $value: string | number | DesignToken;
23
- $description?: string;
24
- }
25
- export interface DesignTokens {
26
- [key: string]: DesignToken | DesignTokens;
27
- }
28
- export interface CSSVariable {
29
- name: string;
30
- value: string;
31
- category?: string;
32
- description?: string;
33
- }
34
- /**
35
- * Import design tokens from various sources
36
- */
37
- export declare function importTokens(source: 'figma' | 'adobe-xd' | 'tokens-studio' | 'style-dictionary' | 'json', data: any): Promise<Map<string, CSSVariable>>;
38
- /**
39
- * Import Figma Variables API format
40
- *
41
- * Example Figma export:
42
- * {
43
- * "colors": {
44
- * "primary": { "$type": "color", "$value": "#007aff" },
45
- * "background": { "$type": "color", "$value": "#ffffff" }
46
- * },
47
- * "spacing": {
48
- * "sm": { "$type": "dimension", "$value": "8px" }
49
- * }
50
- * }
51
- */
52
- export declare function importFigmaTokens(data: any): Map<string, CSSVariable>;
53
- /**
54
- * Import Adobe XD design tokens
55
- *
56
- * Example Adobe XD export:
57
- * {
58
- * "colors": [
59
- * { "name": "Primary Blue", "value": "#007aff" }
60
- * ],
61
- * "textStyles": [
62
- * { "name": "Body", "fontSize": 16, "fontFamily": "SF Pro" }
63
- * ]
64
- * }
65
- */
66
- export declare function importAdobeXDTokens(data: any): Map<string, CSSVariable>;
67
- /**
68
- * Import Tokens Studio (Figma plugin) format
69
- */
70
- export declare function importTokensStudioTokens(data: any): Map<string, CSSVariable>;
71
- /**
72
- * Import Style Dictionary format
73
- *
74
- * Example:
75
- * {
76
- * "color": {
77
- * "primary": { "value": "#007aff" }
78
- * }
79
- * }
80
- */
81
- export declare function importStyleDictionaryTokens(data: any): Map<string, CSSVariable>;
82
- /**
83
- * Import generic JSON token format
84
- */
85
- export declare function importGenericTokens(data: any): Map<string, CSSVariable>;
86
- /**
87
- * Apply CSS variables to an element
88
- */
89
- export declare function applyTokens(element: HTMLElement, tokens: Map<string, CSSVariable>, options?: {
90
- prefix?: string;
91
- scope?: 'element' | 'root';
92
- }): void;
93
- /**
94
- * Generate CSS stylesheet from tokens
95
- */
96
- export declare function generateCSS(tokens: Map<string, CSSVariable>, options?: {
97
- selector?: string;
98
- groupByCategory?: boolean;
99
- includeComments?: boolean;
100
- }): string;
101
- /**
102
- * Export tokens to various formats
103
- */
104
- export declare function exportTokens(tokens: Map<string, CSSVariable>, format: 'css' | 'json' | 'scss' | 'js' | 'ts'): string;
105
- /**
106
- * CLI tool for token conversion
107
- *
108
- * Usage:
109
- * npx @smilodon/tokens import figma tokens.json --output theme.css
110
- * npx @smilodon/tokens import adobe-xd design.json --output vars.css
111
- */
112
- export declare function cli(args: string[]): Promise<void>;
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1,5 +0,0 @@
1
- /**
2
- * CSP (Content Security Policy) compliance test suite.
3
- * Verifies the library works in CSP-restricted environments.
4
- */
5
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1,6 +0,0 @@
1
- /**
2
- * Test setup - runs before all tests
3
- */
4
- import '../src/components/native-select';
5
- import '../src/components/enhanced-select';
6
- import '../src/components/select-option';
@@ -1,5 +0,0 @@
1
- /**
2
- * Shadow DOM security and isolation tests.
3
- * Tests closed shadow roots, nested embeddings, and isolation boundaries.
4
- */
5
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1,5 +0,0 @@
1
- /**
2
- * Stress tests for extreme scale performance validation.
3
- * Tests 1M+ items, heavy transforms, worker offloading.
4
- */
5
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};