@hotosm/ui 0.7.0 → 0.8.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 (28) hide show
  1. package/README.md +12 -10
  2. package/dist/chunks/{chunk.2Y7OBKRQ.js → chunk.3FIEOVXD.js} +1 -1
  3. package/dist/chunks/{chunk.XU6UFL27.js → chunk.3T33Y2BX.js} +146 -50
  4. package/dist/chunks/{chunk.CNUZFRRF.js → chunk.6JUW2IZJ.js} +1 -1
  5. package/dist/chunks/chunk.6WYUOJRX.js +569 -0
  6. package/dist/chunks/{chunk.6BGQ256H.js → chunk.LVC64FO7.js} +1 -1
  7. package/dist/chunks/{chunk.7JIKOYG6.js → chunk.M3LK72JN.js} +1 -1
  8. package/dist/chunks/{chunk.APYFF2XE.js → chunk.N5KXL4J6.js} +1 -1
  9. package/dist/chunks/{chunk.LVCDAVRU.js → chunk.R44PTHOJ.js} +1 -1
  10. package/dist/chunks/{chunk.BVHLTKMC.js → chunk.WELXILIP.js} +1 -1
  11. package/dist/chunks/chunk.ZKUACKKG.js +14 -0
  12. package/dist/components/consent/consent.component.js +1 -1
  13. package/dist/components/consent/consent.js +1 -1
  14. package/dist/components/file-input-dropzone/file-input-dropzone.component.js +1 -1
  15. package/dist/components/file-input-dropzone/file-input-dropzone.js +1 -1
  16. package/dist/components/header/header.component.d.ts +57 -4
  17. package/dist/components/header/header.component.js +1 -1
  18. package/dist/components/header/header.js +1 -1
  19. package/dist/components/header/header.styles.d.ts +0 -1
  20. package/dist/components/header/header.styles.js +1 -1
  21. package/dist/components/logo/logo.component.js +1 -1
  22. package/dist/components/logo/logo.js +1 -1
  23. package/dist/components/logo/logo.styles.js +1 -1
  24. package/dist/hotosm-ui.js +1 -1
  25. package/dist/themes/hot-wa.css +9 -9
  26. package/package.json +1 -1
  27. package/dist/chunks/chunk.FDQFFQX3.js +0 -166
  28. package/dist/chunks/chunk.PBBH42B6.js +0 -6
package/README.md CHANGED
@@ -11,6 +11,9 @@
11
11
  <a href="https://github.com/hotosm/ui/actions/workflows/publish.yml" target="_blank">
12
12
  <img src="https://github.com/hotosm/ui/actions/workflows/publish.yml/badge.svg?event=release" alt="Publish">
13
13
  </a>
14
+ <a href="https://github.com/hotosm/ui/actions/workflows/playwright.yml" target="_blank">
15
+ <img src="https://github.com/hotosm/ui/actions/workflows/playwright.yml/badge.svg?branch=main" alt="Tests">
16
+ </a>
14
17
  <a href="https://github.com/hotosm/ui/actions/workflows/cdn_deploy.yml" target="_blank">
15
18
  <img src="https://github.com/hotosm/ui/actions/workflows/cdn_deploy.yml/badge.svg?branch=main" alt="CDN Deploy">
16
19
  </a>
@@ -81,7 +84,7 @@ pnpm install @hotosm/ui @awesome.me/webawesome@3.2.1
81
84
 
82
85
  Two CSS files are published. Choose the one that fits your setup.
83
86
 
84
- ### Option A Bundled (recommended for simplicity)
87
+ ### Option A - Bundled (recommended for simplicity)
85
88
 
86
89
  A single self-contained file with WebAwesome base styles + HOT theme
87
90
  already inlined. Nothing else to load.
@@ -97,14 +100,14 @@ Or from a bundler:
97
100
  import '@hotosm/ui/dist/style.css';
98
101
  ```
99
102
 
100
- ### Option B Split / CDN-optimised (recommended for multi-tool caching)
103
+ ### Option B - Split / CDN-optimised (recommended for multi-tool caching)
101
104
 
102
105
  If you run several HOT tools (FMTM, Tasking Manager, etc.) and want
103
106
  the browser to **cache WebAwesome CSS once** across all of them, load
104
107
  WebAwesome from CDN separately and use the slim HOT-only stylesheet:
105
108
 
106
109
  ```html
107
- <!-- WebAwesome CSS shared across all HOT tools via browser cache -->
110
+ <!-- WebAwesome CSS - shared across all HOT tools via browser cache -->
108
111
  <link rel="stylesheet"
109
112
  href="https://cdn.jsdelivr.net/npm/@awesome.me/webawesome@3.2.1/dist/styles/native.css">
110
113
  <link rel="stylesheet"
@@ -137,9 +140,9 @@ import '@hotosm/ui/dist/style-core.css';
137
140
  > [!TIP]
138
141
  > **Which should I pick?**
139
142
  >
140
- > - Building a single standalone app? Use **Option A** zero config.
143
+ > - Building a single standalone app? Use **Option A** - zero config.
141
144
  > - Running multiple HOT tools on the same domain or expecting users to
142
- > navigate between them? Use **Option B** the ~84 KB of shared
145
+ > navigate between them? Use **Option B** - the ~84 KB of shared
143
146
  > WebAwesome CSS is fetched once and cached by the browser.
144
147
 
145
148
  ---
@@ -166,7 +169,7 @@ Add the required WebAwesome classes to your `<html>` element:
166
169
 
167
170
  ### Via Bundler (Vite, Webpack, etc.)
168
171
 
169
- Import individual components your bundler will tree-shake the rest:
172
+ Import individual components - your bundler will tree-shake the rest:
170
173
 
171
174
  ```js
172
175
  import '@hotosm/ui/dist/components/header/header.js';
@@ -186,7 +189,7 @@ all HOT tools (Option B from the styles section above):
186
189
  <!DOCTYPE html>
187
190
  <html class="wa-theme-default wa-palette-hotosm">
188
191
  <head>
189
- <!-- WebAwesome CSS cached once across all HOT tools at this WA version -->
192
+ <!-- WebAwesome CSS - cached once across all HOT tools at this WA version -->
190
193
  <link rel="stylesheet"
191
194
  href="https://cdn.jsdelivr.net/npm/@awesome.me/webawesome@3.2.1/dist/styles/native.css">
192
195
  <link rel="stylesheet"
@@ -225,7 +228,6 @@ all HOT tools (Option B from the styles section above):
225
228
  // Include the attribute to make it true.
226
229
  const hdr = document.getElementById('hdr');
227
230
  hdr.drawer = true; // enable the hamburger drawer
228
- hdr.borderBottom = true; // enable bottom border
229
231
  </script>
230
232
  </body>
231
233
  </html>
@@ -233,13 +235,13 @@ all HOT tools (Option B from the styles section above):
233
235
 
234
236
  > [!TIP]
235
237
  > If you need only a single self-contained stylesheet instead of the three
236
- > WA links above, you can use Option A (`style.css`) but then the ~84 KB
238
+ > WA links above, you can use Option A (`style.css`) - but then the ~84 KB
237
239
  > of WebAwesome CSS is bundled into the HOT package and cannot be shared
238
240
  > across tools as a single cached resource.
239
241
 
240
242
  ### React
241
243
 
242
- Web Components work in React with a small caveat use `ref` callbacks
244
+ Web Components work in React with a small caveat - use `ref` callbacks
243
245
  for custom events if React's synthetic event system doesn't forward them:
244
246
 
245
247
  ```jsx
@@ -1 +1 @@
1
- import{b as e}from"./chunk.XU6UFL27.js";var a=e;customElements.get("hot-header")||customElements.define("hot-header",e);export{a};
1
+ import{b as e}from"./chunk.3T33Y2BX.js";var a=e;customElements.get("hot-header")||customElements.define("hot-header",e);export{a};