@hotosm/ui 0.3.2-b5 → 0.3.2-b8
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/dist/assets/logo/hamburger.svg +1 -0
- package/dist/chunks/{chunk.OSUPNFJP.js → chunk.2ULJ7GOD.js} +1 -1
- package/dist/chunks/chunk.D4UQX7IV.js +146 -0
- package/dist/chunks/chunk.JWXDWX4U.js +1 -0
- package/dist/chunks/{chunk.NQSLFHXC.js → chunk.NA5VYRZH.js} +1 -1
- package/dist/chunks/chunk.PDA7Y3OG.js +1253 -0
- package/dist/chunks/chunk.TTXUWWW4.js +1 -0
- package/dist/chunks/chunk.UOUAH7BX.js +1 -0
- package/dist/chunks/chunk.XV3ZU53D.js +1 -0
- package/dist/components/button/button.component.js +1 -1
- package/dist/components/button/button.js +1 -1
- package/dist/components/consent/consent.component.js +1 -1
- package/dist/components/consent/consent.js +1 -1
- package/dist/components/header/header.component.d.ts +8 -0
- package/dist/components/header/header.component.js +1 -1
- package/dist/components/header/header.js +1 -1
- package/dist/components/header/header.styles.js +1 -1
- package/dist/components/icons.d.ts +9 -0
- package/dist/components/icons.js +1 -1
- package/dist/hotosm-ui.d.ts +1 -0
- package/dist/hotosm-ui.js +1 -1
- package/dist/themes/hot.css +2 -8
- package/dist/utils/shadow-dom-css.d.ts +30 -0
- package/package.json +1 -1
- package/dist/chunks/chunk.KO4EOD3I.js +0 -1
- package/dist/chunks/chunk.KWRSAL43.js +0 -1
- package/dist/chunks/chunk.RQCFXHIG.js +0 -1
- package/dist/chunks/chunk.SMFWK2VT.js +0 -1
- package/dist/chunks/chunk.UMBUH2EC.js +0 -690
- package/dist/chunks/chunk.WX25LIXR.js +0 -96
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as e}from"./chunk.2ULJ7GOD.js";var n=e;customElements.define("hot-consent",e);export{n as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as t}from"./chunk.NA5VYRZH.js";var o=t;customElements.define("hot-button",t);export{o as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var o='data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="3" y1="6" x2="21" y2="6"/><line x1="3" y1="12" x2="21" y2="12"/><line x1="3" y1="18" x2="21" y2="18"/></svg>%20';function n(){let e=()=>{window.WebAwesome&&window.WebAwesome.iconRegistry?window.WebAwesome.iconRegistry.addIcon("hot-icons","list",o):setTimeout(e,100)};e()}var s=n;export{s as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.
|
|
1
|
+
import{a,b}from"../../chunks/chunk.NA5VYRZH.js";import"../../chunks/chunk.O6I2TNK3.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.2FEIL35F.js";import"../../chunks/chunk.6Y3X2E2V.js";import"../../chunks/chunk.XV3ZU53D.js";import"../../chunks/chunk.TNLBUOUK.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as Button,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunks/chunk.
|
|
1
|
+
import{a}from"../../chunks/chunk.UOUAH7BX.js";import"../../chunks/chunk.NA5VYRZH.js";import"../../chunks/chunk.O6I2TNK3.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.2FEIL35F.js";import"../../chunks/chunk.6Y3X2E2V.js";import"../../chunks/chunk.XV3ZU53D.js";import"../../chunks/chunk.TNLBUOUK.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.
|
|
1
|
+
import{a,b}from"../../chunks/chunk.2ULJ7GOD.js";import"../../chunks/chunk.34D2LPI2.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.2FEIL35F.js";import"../../chunks/chunk.6Y3X2E2V.js";import"../../chunks/chunk.XV3ZU53D.js";import"../../chunks/chunk.GTNRNZDH.js";import"../../chunks/chunk.TNLBUOUK.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as Consent,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunks/chunk.
|
|
1
|
+
import{a}from"../../chunks/chunk.TTXUWWW4.js";import"../../chunks/chunk.2ULJ7GOD.js";import"../../chunks/chunk.34D2LPI2.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.2FEIL35F.js";import"../../chunks/chunk.6Y3X2E2V.js";import"../../chunks/chunk.XV3ZU53D.js";import"../../chunks/chunk.GTNRNZDH.js";import"../../chunks/chunk.TNLBUOUK.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as default};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import '@awesome.me/webawesome/dist/components/tab-group/tab-group.js';
|
|
2
2
|
import '@awesome.me/webawesome/dist/components/dialog/dialog.js';
|
|
3
3
|
import '@awesome.me/webawesome/dist/components/icon/icon.js';
|
|
4
|
+
import '@awesome.me/webawesome/dist/components/drawer/drawer.js';
|
|
4
5
|
import { LitElement } from "lit";
|
|
5
6
|
import type { CSSResultGroup } from 'lit';
|
|
6
7
|
import { type sizes } from './header.styles.js';
|
|
@@ -19,6 +20,11 @@ export declare class Header extends LitElement {
|
|
|
19
20
|
accessor drawer: boolean;
|
|
20
21
|
/** Array of menu items to include as navigation tabs. */
|
|
21
22
|
accessor tabs: MenuItem[];
|
|
23
|
+
/** Array of links to include in the drawer. */
|
|
24
|
+
accessor drawerLinks: Array<{
|
|
25
|
+
label: string;
|
|
26
|
+
href: string;
|
|
27
|
+
}>;
|
|
22
28
|
/** Size of toolbar vertically. */
|
|
23
29
|
accessor size: sizes;
|
|
24
30
|
/** Border bottom. */
|
|
@@ -35,7 +41,9 @@ export declare class Header extends LitElement {
|
|
|
35
41
|
selectTab(index: number): void;
|
|
36
42
|
protected render(): import("lit-html").TemplateResult<1>;
|
|
37
43
|
private _tabClick;
|
|
44
|
+
private _handleTabShow;
|
|
38
45
|
private _handleLogin;
|
|
39
46
|
private _handleModalClose;
|
|
47
|
+
private _handleDrawerOpen;
|
|
40
48
|
}
|
|
41
49
|
export default Header;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.
|
|
1
|
+
import{d as a,e as b}from"../../chunks/chunk.PDA7Y3OG.js";import"../../chunks/chunk.D4UQX7IV.js";import"../../chunks/chunk.2FEIL35F.js";import"../../chunks/chunk.6Y3X2E2V.js";import"../../chunks/chunk.XV3ZU53D.js";import"../../chunks/chunk.TNLBUOUK.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as Header,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunks/chunk.
|
|
1
|
+
import{a}from"../../chunks/chunk.JWXDWX4U.js";import"../../chunks/chunk.PDA7Y3OG.js";import"../../chunks/chunk.D4UQX7IV.js";import"../../chunks/chunk.2FEIL35F.js";import"../../chunks/chunk.6Y3X2E2V.js";import"../../chunks/chunk.XV3ZU53D.js";import"../../chunks/chunk.TNLBUOUK.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.
|
|
1
|
+
import{a,b}from"../../chunks/chunk.D4UQX7IV.js";import"../../chunks/chunk.TNLBUOUK.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as headerVariants,b as styles};
|
package/dist/components/icons.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../chunks/chunk.
|
|
1
|
+
import{a}from"../chunks/chunk.XV3ZU53D.js";import"../chunks/chunk.NI7UJOOZ.js";export{a as default};
|
package/dist/hotosm-ui.d.ts
CHANGED
|
@@ -3,4 +3,5 @@ import HotLogo from './components/logo/logo.js';
|
|
|
3
3
|
import HotTracking from './components/tracking/tracking.js';
|
|
4
4
|
import HotConsent from './components/consent/consent.js';
|
|
5
5
|
import HotButton from './components/button/button.js';
|
|
6
|
+
export { setupAutoInjection, injectHOTThemeIntoButtons, injectCSSIntoShadowDOM } from './utils/shadow-dom-css.js';
|
|
6
7
|
export { HotHeader as Header, HotLogo as Logo, HotConsent as Consent, HotTracking as Tracking, HotButton as Button, };
|
package/dist/hotosm-ui.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as
|
|
1
|
+
import{a as n}from"./chunks/chunk.JWXDWX4U.js";import{a as o,b as t,c as r}from"./chunks/chunk.PDA7Y3OG.js";import"./chunks/chunk.D4UQX7IV.js";import{a as e}from"./chunks/chunk.MCLA4YSC.js";import"./chunks/chunk.CFJBM2JT.js";import"./chunks/chunk.W65BP3JY.js";import{a as m}from"./chunks/chunk.3P72BRDN.js";import"./chunks/chunk.2E5B6OR3.js";import{a as i}from"./chunks/chunk.UOUAH7BX.js";import"./chunks/chunk.NA5VYRZH.js";import"./chunks/chunk.O6I2TNK3.js";import{a}from"./chunks/chunk.TTXUWWW4.js";import"./chunks/chunk.2ULJ7GOD.js";import"./chunks/chunk.34D2LPI2.js";import"./chunks/chunk.O2GMJYSL.js";import"./chunks/chunk.2FEIL35F.js";import"./chunks/chunk.6Y3X2E2V.js";import"./chunks/chunk.XV3ZU53D.js";import"./chunks/chunk.GTNRNZDH.js";import"./chunks/chunk.TNLBUOUK.js";import"./chunks/chunk.NI7UJOOZ.js";export{i as Button,a as Consent,n as Header,e as Logo,m as Tracking,o as injectCSSIntoShadowDOM,t as injectHOTThemeIntoButtons,r as setupAutoInjection};
|
package/dist/themes/hot.css
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/* HOT theme */
|
|
2
|
+
|
|
2
3
|
/* :root makes them available globally */
|
|
3
4
|
:root,
|
|
4
5
|
/* :host is for Web Components and shadow DOM scopes */
|
|
@@ -16,7 +17,7 @@
|
|
|
16
17
|
--hot-color-red-800: #B83032;
|
|
17
18
|
--hot-color-red-700: #C53639;
|
|
18
19
|
--hot-color-red-600: #D73F3F;
|
|
19
|
-
--hot-color-red-500:
|
|
20
|
+
--hot-color-red-500: #F34D47;
|
|
20
21
|
--hot-color-red-400: #ED5C5E;
|
|
21
22
|
--hot-color-red-300: #E27A7D;
|
|
22
23
|
--hot-color-red-200: #EC9EA1;
|
|
@@ -280,10 +281,3 @@
|
|
|
280
281
|
}
|
|
281
282
|
|
|
282
283
|
|
|
283
|
-
wa-button.login-button {
|
|
284
|
-
background-color: #1a73e8;
|
|
285
|
-
color: white;
|
|
286
|
-
font-weight: 600;
|
|
287
|
-
padding: 0.6rem 1.2rem;
|
|
288
|
-
border-radius: 8px;
|
|
289
|
-
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
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
|
|
5
|
+
*/
|
|
6
|
+
export interface CSSInjectionOptions {
|
|
7
|
+
/** The CSS string to inject */
|
|
8
|
+
css: string;
|
|
9
|
+
/** CSS selector to find elements to inject into */
|
|
10
|
+
selector?: string;
|
|
11
|
+
/** Whether to inject into all matching elements or just the first */
|
|
12
|
+
all?: boolean;
|
|
13
|
+
/** Custom style ID to avoid duplicate injections */
|
|
14
|
+
styleId?: string;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Injects CSS into the shadow DOM of WebAwesome components
|
|
18
|
+
* @param options Configuration options for CSS injection
|
|
19
|
+
*/
|
|
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
|
+
* Sets up a mutation observer to automatically inject CSS into new wa-button elements
|
|
28
|
+
* This ensures that dynamically added buttons also get the HOT theme
|
|
29
|
+
*/
|
|
30
|
+
export declare function setupAutoInjection(): void;
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
function e(){}var n=e;export{n as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as t}from"./chunk.NQSLFHXC.js";var o=t;customElements.define("hot-button",t);export{o as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as e}from"./chunk.UMBUH2EC.js";var r=e;customElements.define("hot-header",e);export{r as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as e}from"./chunk.OSUPNFJP.js";var n=e;customElements.define("hot-consent",e);export{n as a};
|