@hotosm/ui 0.3.4-b3 → 0.5.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.
Files changed (68) hide show
  1. package/README.md +18 -7
  2. package/dist/chunks/chunk.3RPYDHJV.js +1 -0
  3. package/dist/chunks/chunk.5NFC3HMD.js +1 -0
  4. package/dist/chunks/chunk.7BVHA4G6.js +71 -0
  5. package/dist/chunks/{chunk.SLQC3DLQ.js → chunk.7G6VEQ2R.js} +2 -2
  6. package/dist/chunks/chunk.ARF626EG.js +59 -0
  7. package/dist/chunks/{chunk.SHZIJ2ZS.js → chunk.BD4Q32VT.js} +1 -1
  8. package/dist/chunks/chunk.CQO3GWTI.js +32 -0
  9. package/dist/chunks/chunk.EB2T3VFE.js +122 -0
  10. package/dist/chunks/chunk.GEAU3JJH.js +187 -0
  11. package/dist/chunks/{chunk.NA3GD2QI.js → chunk.GLN7KYWH.js} +1 -1
  12. package/dist/chunks/{chunk.CY4WTDL2.js → chunk.LHZ7Q2M3.js} +1 -1
  13. package/dist/chunks/{chunk.SVLPRECX.js → chunk.PBBH42B6.js} +1 -1
  14. package/dist/chunks/chunk.PLECT4NZ.js +20 -0
  15. package/dist/chunks/chunk.QABMDRWR.js +28 -0
  16. package/dist/chunks/chunk.SLA5IPJG.js +1 -0
  17. package/dist/chunks/chunk.TMMJP2DW.js +1 -0
  18. package/dist/chunks/chunk.VXTJYHK5.js +1 -0
  19. package/dist/chunks/chunk.W372S2KG.js +1 -0
  20. package/dist/chunks/chunk.WTTPHBL3.js +105 -0
  21. package/dist/chunks/chunk.XDXYJBLZ.js +1 -0
  22. package/dist/chunks/{chunk.TYOVPHVD.js → chunk.XNZFLEXO.js} +1 -1
  23. package/dist/chunks/chunk.ZETV7TDG.js +25 -0
  24. package/dist/components/consent/consent.component.js +1 -1
  25. package/dist/components/consent/consent.js +1 -1
  26. package/dist/components/consent/consent.styles.js +1 -1
  27. package/dist/components/file-input-dropzone/file-input-dropzone.component.d.ts +39 -0
  28. package/dist/components/file-input-dropzone/file-input-dropzone.component.js +1 -0
  29. package/dist/components/file-input-dropzone/file-input-dropzone.d.ts +8 -0
  30. package/dist/components/file-input-dropzone/file-input-dropzone.js +1 -0
  31. package/dist/components/file-input-dropzone/file-input-dropzone.styles.d.ts +2 -0
  32. package/dist/components/file-input-dropzone/file-input-dropzone.styles.js +1 -0
  33. package/dist/components/header/header.component.d.ts +0 -2
  34. package/dist/components/header/header.component.js +1 -1
  35. package/dist/components/header/header.js +1 -1
  36. package/dist/components/header/header.styles.js +1 -1
  37. package/dist/components/list-card/list-card.component.d.ts +16 -0
  38. package/dist/components/list-card/list-card.component.js +1 -0
  39. package/dist/components/list-card/list-card.d.ts +7 -0
  40. package/dist/components/list-card/list-card.js +1 -0
  41. package/dist/components/list-card/list-card.styles.d.ts +2 -0
  42. package/dist/components/list-card/list-card.styles.js +1 -0
  43. package/dist/components/logo/logo.component.js +1 -1
  44. package/dist/components/logo/logo.js +1 -1
  45. package/dist/components/logo/logo.styles.js +1 -1
  46. package/dist/components/tool-menu/tool-menu.component.d.ts +13 -0
  47. package/dist/components/tool-menu/tool-menu.component.js +1 -0
  48. package/dist/components/tool-menu/tool-menu.d.ts +7 -0
  49. package/dist/components/tool-menu/tool-menu.js +1 -0
  50. package/dist/components/tool-menu/tool-menu.styles.d.ts +1 -0
  51. package/dist/components/tool-menu/tool-menu.styles.js +1 -0
  52. package/dist/components/tracking/tracking.component.js +1 -1
  53. package/dist/components/tracking/tracking.js +1 -1
  54. package/dist/hotosm-ui.d.ts +9 -6
  55. package/dist/hotosm-ui.js +1 -1
  56. package/dist/style.css +4 -3
  57. package/dist/themes/{hot-wa-override.css → hot-wa.css} +122 -323
  58. package/dist/themes/hot.css +15 -15
  59. package/dist/utils/shadow-dom-css.d.ts +3 -17
  60. package/package.json +21 -6
  61. package/dist/chunks/chunk.2LYFUHTS.js +0 -633
  62. package/dist/chunks/chunk.5EPWWJMT.js +0 -1
  63. package/dist/chunks/chunk.7M3AMUDU.js +0 -1
  64. package/dist/chunks/chunk.FT6RSQVB.js +0 -25
  65. package/dist/chunks/chunk.JHIEUZ7A.js +0 -1
  66. package/dist/chunks/chunk.WSMXFTSE.js +0 -28
  67. package/dist/chunks/chunk.XB4PECPF.js +0 -1
  68. package/dist/themes/hot-button-override.css +0 -246
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Utility to inject CSS into shadow DOM elements
3
- * This is needed because WebAwesome components use shadow DOM and CSS variables
4
- * from the global scope are not accessible within the shadow DOM
3
+ *
4
+ * This utility is kept for potential future use with other shadow DOM components.
5
5
  */
6
6
  export interface CSSInjectionOptions {
7
7
  /** The CSS string to inject */
@@ -14,21 +14,7 @@ export interface CSSInjectionOptions {
14
14
  styleId?: string;
15
15
  }
16
16
  /**
17
- * Injects CSS into the shadow DOM of WebAwesome components
17
+ * Injects CSS into the shadow DOM of elements
18
18
  * @param options Configuration options for CSS injection
19
19
  */
20
20
  export declare function injectCSSIntoShadowDOM(options: CSSInjectionOptions): void;
21
- /**
22
- * Injects HOT theme CSS variables into wa-button shadow DOM
23
- * This makes the HOT theme variables available within the shadow DOM
24
- */
25
- export declare function injectHOTThemeIntoButtons(): void;
26
- /**
27
- * Injects CSS into all WebAwesome components that need HOT theme styling
28
- */
29
- export declare function injectHOTThemeIntoAllComponents(): void;
30
- /**
31
- * Sets up a mutation observer to automatically inject CSS into new WebAwesome elements
32
- * This ensures that dynamically added components also get the HOT theme
33
- */
34
- export declare function setupAutoInjection(): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hotosm/ui",
3
- "version": "0.3.4-b3",
3
+ "version": "0.5.0",
4
4
  "description": "Shared UI components with HOT theming.",
5
5
  "homepage": "https://github.com/hotosm/ui#readme",
6
6
  "author": {
@@ -13,16 +13,20 @@
13
13
  "url": "https://github.com/joltcode"
14
14
  },
15
15
  {
16
- "name": "Emilio Mariscal",
16
+ "name": "Emilio",
17
17
  "url": "https://github.com/emi420"
18
18
  },
19
19
  {
20
- "name": "Deepak Pradhan",
20
+ "name": "Deepak",
21
21
  "url": "https://github.com/varun2948"
22
22
  },
23
23
  {
24
- "name": "Sam Woodcock",
24
+ "name": "Sam",
25
25
  "url": "https://github.com/spwoodcock"
26
+ },
27
+ {
28
+ "name": "Tyler",
29
+ "url": "https://github.com/tbssnch"
26
30
  }
27
31
  ],
28
32
  "license": "AGPL-3.0-only",
@@ -52,23 +56,34 @@
52
56
  "@awesome.me/webawesome": "3.0.0"
53
57
  },
54
58
  "devDependencies": {
59
+ "@awesome.me/webawesome": "3.0.0-beta.1",
55
60
  "@storybook/addon-docs": "^9.0.18",
56
61
  "@storybook/addon-links": "^9.0.18",
57
62
  "@storybook/web-components-vite": "^9.0.18",
58
63
  "@teamhanko/hanko-elements": "^2.1.0",
64
+ "@testing-library/dom": "^10.4.1",
65
+ "@testing-library/jest-dom": "^6.4.2",
66
+ "@vitest/browser": "^4.0.10",
67
+ "@vitest/browser-playwright": "^4.0.10",
59
68
  "@whitespace/storybook-addon-html": "^7.0.0",
60
69
  "class-variance-authority": "^0.7.1",
61
70
  "del": "^8.0.0",
62
71
  "esbuild": "^0.25.8",
63
72
  "globby": "^14.1.0",
73
+ "jsdom": "^24.0.0",
64
74
  "lit": "^3.3.1",
75
+ "playwright": "^1.56.1",
65
76
  "storybook": "^9.0.18",
66
77
  "typescript": "^5.8.3",
67
- "user-agent-data-types": "^0.4.2"
78
+ "user-agent-data-types": "^0.4.2",
79
+ "vitest": "^4.0.10"
68
80
  },
69
81
  "scripts": {
70
82
  "dev": "storybook dev -p 3001 --no-open",
71
83
  "build:docs": "storybook build --output-dir docs",
72
- "build": "node scripts/build.js"
84
+ "build": "node scripts/build.js",
85
+ "test": "vitest run",
86
+ "test:watch": "vitest",
87
+ "coverage": "vitest run --coverage"
73
88
  }
74
89
  }