@hotosm/ui 0.3.2-b3 → 0.3.2-b4
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/osm-logo.svg +277 -0
- package/dist/chunks/chunk.EMBNMR2N.js +692 -0
- package/dist/chunks/chunk.EROFXAZH.js +1 -0
- package/dist/chunks/chunk.HQE63XEZ.js +96 -0
- package/dist/chunks/{chunk.6YSBNYKD.js → chunk.QT57GV7H.js} +1 -1
- 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.d.ts +0 -10
- package/dist/components/consent/consent.js +1 -1
- package/dist/components/header/header.component.d.ts +2 -22
- package/dist/components/header/header.component.js +1 -1
- package/dist/components/header/header.d.ts +0 -10
- package/dist/components/header/header.js +1 -1
- package/dist/components/header/header.styles.js +1 -1
- package/dist/components/logo/logo.d.ts +0 -10
- package/dist/components/tracking/tracking.component.js +1 -1
- package/dist/components/tracking/tracking.d.ts +0 -10
- package/dist/components/tracking/tracking.js +1 -1
- package/dist/hotosm-ui.js +1 -1
- package/package.json +5 -6
- package/dist/assets/logo/osm-logo.png +0 -0
- package/dist/chunks/chunk.IU7P7RMD.js +0 -1
- package/dist/chunks/chunk.O6Q54UVK.js +0 -671
- package/dist/chunks/chunk.VOBHDN5R.js +0 -168
- /package/dist/chunks/{chunk.UNSJMT66.js → chunk.CS444ZXM.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as e}from"./chunk.EMBNMR2N.js";var r=e;customElements.define("hot-header",e);export{r as a};
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import{b as f}from"./chunk.U4P7XQR4.js";import{a as c,c as g}from"./chunk.NI7UJOOZ.js";function b(t){var r,e,a="";if(typeof t=="string"||typeof t=="number")a+=t;else if(typeof t=="object")if(Array.isArray(t)){var n=t.length;for(r=0;r<n;r++)t[r]&&(e=b(t[r]))&&(a&&(a+=" "),a+=e)}else for(e in t)t[e]&&(a&&(a+=" "),a+=e);return a}function y(){for(var t,r,e=0,a="",n=arguments.length;e<n;e++)(t=arguments[e])&&(r=b(t))&&(a&&(a+=" "),a+=r);return a}var x=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,p=y,z=(t,r)=>e=>{var a;if((r==null?void 0:r.variants)==null)return p(t,e==null?void 0:e.class,e==null?void 0:e.className);let{variants:n,defaultVariants:s}=r,w=Object.keys(n).map(o=>{let i=e==null?void 0:e[o],d=s==null?void 0:s[o];if(i===null)return null;let l=x(i)||x(d);return n[o][l]}),m=e&&Object.entries(e).reduce((o,i)=>{let[d,l]=i;return l===void 0||(o[d]=l),o},{}),j=r==null||(a=r.compoundVariants)===null||a===void 0?void 0:a.reduce((o,i)=>{let u=i,{class:d,className:l}=u,V=g(u,["class","className"]);return Object.entries(V).every(k=>{let[v,h]=k;return Array.isArray(h)?h.includes(c(c({},s),m)[v]):c(c({},s),m)[v]===h})?[...o,d,l]:o},[]);return p(t,w,j,e==null?void 0:e.class,e==null?void 0:e.className)};var _=z(`
|
|
2
|
+
header
|
|
3
|
+
`,{variants:{size:{small:"header--size-small",medium:"header--size-medium",large:"header--size-large"},borderBottom:{true:"border-bottom"}}}),B=f`
|
|
4
|
+
.header {
|
|
5
|
+
display: flex;
|
|
6
|
+
align-items: center;
|
|
7
|
+
justify-content: space-between;
|
|
8
|
+
padding: 0 var(--hot-spacing-small);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.header.border-bottom {
|
|
12
|
+
border-bottom: var(--hot-spacing-3x-small) solid var(--hot-color-neutral-50);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.header--size-small {
|
|
16
|
+
height: var(--hot-spacing-4x-large);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.header--size-medium {
|
|
20
|
+
height: calc(var(--hot-spacing-4x-large) * 2);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.header--size-large {
|
|
24
|
+
height: calc(var(--hot-spacing-4x-large) * 4);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.header--link {
|
|
28
|
+
text-decoration: none;
|
|
29
|
+
display: flex;
|
|
30
|
+
align-items: center;
|
|
31
|
+
justify-content: space-between;
|
|
32
|
+
gap: var(--hot-spacing-small);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.header--title {
|
|
36
|
+
color: var(--hot-color-neutral-950);
|
|
37
|
+
font-family: var(--hot-font-sans);
|
|
38
|
+
font-size: var(--hot-font-size-x-large);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.header--tab::part(base) {
|
|
42
|
+
font-size: var(--hot-font-size-medium);
|
|
43
|
+
font-weight: var(--hot-font-weight-normal);
|
|
44
|
+
color: var(--hot-color-neutral-950);
|
|
45
|
+
padding: var(--hot-spacing-small) var(--hot-spacing-small);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.header--tab-group::part(base) {
|
|
49
|
+
--track-color: transparent;
|
|
50
|
+
--indicator-color: none;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.header--nav {
|
|
54
|
+
justify-content: space-between;
|
|
55
|
+
justify-items: center;
|
|
56
|
+
gap: var(--hot-spacing-medium);
|
|
57
|
+
font-weight: var(--hot-font-weight-semibold);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.header--nav-mobile {
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.header--person-circle {
|
|
64
|
+
font-size: var(--hot-font-size-x-large);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.header--drawer {
|
|
68
|
+
font-size: var(--hot-font-size-x-large)
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.header--right-section {
|
|
72
|
+
display: flex;
|
|
73
|
+
align-items: center;
|
|
74
|
+
gap: var(--hot-spacing-small);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
.header--logo-img {
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.header--tab {
|
|
83
|
+
border-bottom: 2px solid;
|
|
84
|
+
border-color: transparent;
|
|
85
|
+
}
|
|
86
|
+
.header--tab-active {
|
|
87
|
+
border-color: var(--hot-color-neutral-1000);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/* Login Modal Styles */
|
|
91
|
+
.login-modal {
|
|
92
|
+
--width: 35rem;
|
|
93
|
+
--border-radius: 8px;
|
|
94
|
+
--background-color: white;
|
|
95
|
+
}
|
|
96
|
+
`;export{_ as a,B as b};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as o,d as t,g as l,h as i}from"./chunk.
|
|
1
|
+
import{c as o,d as t,g as l,h as i}from"./chunk.CS444ZXM.js";import{a as e,b as a}from"./chunk.6ZDEZIWM.js";import{e as n}from"./chunk.U4P7XQR4.js";var d=`:host {
|
|
2
2
|
display: flex;
|
|
3
3
|
position: relative;
|
|
4
4
|
align-items: stretch;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.HDZFWGNV.js";import"../../chunks/chunk.U4GEH6YR.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.
|
|
1
|
+
import{a,b}from"../../chunks/chunk.HDZFWGNV.js";import"../../chunks/chunk.U4GEH6YR.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.KO4EOD3I.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as Button,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunks/chunk.H5ZQREL2.js";import"../../chunks/chunk.HDZFWGNV.js";import"../../chunks/chunk.U4GEH6YR.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.
|
|
1
|
+
import{a}from"../../chunks/chunk.H5ZQREL2.js";import"../../chunks/chunk.HDZFWGNV.js";import"../../chunks/chunk.U4GEH6YR.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.KO4EOD3I.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.CS56NBTQ.js";import"../../chunks/chunk.
|
|
1
|
+
import{a,b}from"../../chunks/chunk.CS56NBTQ.js";import"../../chunks/chunk.QT57GV7H.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.KO4EOD3I.js";import"../../chunks/chunk.T4GALJJA.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as Consent,b as default};
|
|
@@ -1,17 +1,7 @@
|
|
|
1
1
|
import Consent from './consent.component.js';
|
|
2
2
|
export default Consent;
|
|
3
|
-
|
|
4
3
|
declare global {
|
|
5
4
|
interface HTMLElementTagNameMap {
|
|
6
5
|
'hot-consent': Consent;
|
|
7
6
|
}
|
|
8
7
|
}
|
|
9
|
-
|
|
10
|
-
// React 19
|
|
11
|
-
declare module "react" {
|
|
12
|
-
namespace JSX {
|
|
13
|
-
interface IntrinsicElements {
|
|
14
|
-
'hot-consent': Consent;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunks/chunk.UYOJKKGV.js";import"../../chunks/chunk.CS56NBTQ.js";import"../../chunks/chunk.
|
|
1
|
+
import{a}from"../../chunks/chunk.UYOJKKGV.js";import"../../chunks/chunk.CS56NBTQ.js";import"../../chunks/chunk.QT57GV7H.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.KO4EOD3I.js";import"../../chunks/chunk.T4GALJJA.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as default};
|
|
@@ -2,23 +2,12 @@ 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
4
|
import { LitElement } from "lit";
|
|
5
|
-
import { type sizes } from './header.styles.js';
|
|
6
5
|
import type { CSSResultGroup } from 'lit';
|
|
6
|
+
import { type sizes } from './header.styles.js';
|
|
7
7
|
interface MenuItem {
|
|
8
8
|
label: string;
|
|
9
9
|
clickEvent: () => void;
|
|
10
10
|
}
|
|
11
|
-
interface LoginProvider {
|
|
12
|
-
icon?: string;
|
|
13
|
-
loginUrl: string;
|
|
14
|
-
redirectUrl: string;
|
|
15
|
-
clientId?: string;
|
|
16
|
-
name?: string;
|
|
17
|
-
scope?: string;
|
|
18
|
-
}
|
|
19
|
-
interface LoginProviders {
|
|
20
|
-
[key: string]: LoginProvider;
|
|
21
|
-
}
|
|
22
11
|
export declare class Header extends LitElement {
|
|
23
12
|
static styles: CSSResultGroup;
|
|
24
13
|
name: string;
|
|
@@ -40,19 +29,10 @@ export declare class Header extends LitElement {
|
|
|
40
29
|
accessor showLogin: boolean;
|
|
41
30
|
/** Control the login modal state. */
|
|
42
31
|
accessor loginModalOpen: boolean;
|
|
43
|
-
/** Configuration object for login providers. */
|
|
44
|
-
accessor loginProviders: LoginProviders;
|
|
45
32
|
/** Default fallback icon for providers without custom icons. */
|
|
46
33
|
accessor defaultLoginIcon: string;
|
|
47
|
-
|
|
48
|
-
accessor OsmOauthClientId: string;
|
|
49
|
-
accessor OsmOauthRedirectUri: string;
|
|
50
|
-
private get loginOptions();
|
|
51
|
-
private formatProviderName;
|
|
34
|
+
connectedCallback(): Promise<void>;
|
|
52
35
|
selectTab(index: number): void;
|
|
53
|
-
private performLogin;
|
|
54
|
-
private legacyOsmLoginRedirect;
|
|
55
|
-
private handleSignIn;
|
|
56
36
|
protected render(): import("lit").TemplateResult<1>;
|
|
57
37
|
private _tabClick;
|
|
58
38
|
private _handleLogin;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.
|
|
1
|
+
import{a,b}from"../../chunks/chunk.EMBNMR2N.js";import"../../chunks/chunk.HQE63XEZ.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.KO4EOD3I.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as Header,b as default};
|
|
@@ -1,17 +1,7 @@
|
|
|
1
1
|
import Header from './header.component.js';
|
|
2
2
|
export default Header;
|
|
3
|
-
|
|
4
3
|
declare global {
|
|
5
4
|
interface HTMLElementTagNameMap {
|
|
6
5
|
'hot-header': Header;
|
|
7
6
|
}
|
|
8
7
|
}
|
|
9
|
-
|
|
10
|
-
// React 19
|
|
11
|
-
declare module "react" {
|
|
12
|
-
namespace JSX {
|
|
13
|
-
interface IntrinsicElements {
|
|
14
|
-
'hot-header': Header;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunks/chunk.
|
|
1
|
+
import{a}from"../../chunks/chunk.EROFXAZH.js";import"../../chunks/chunk.EMBNMR2N.js";import"../../chunks/chunk.HQE63XEZ.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.KO4EOD3I.js";import"../../chunks/chunk.U4P7XQR4.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.HQE63XEZ.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as headerVariants,b as styles};
|
|
@@ -1,17 +1,7 @@
|
|
|
1
1
|
import Logo from './logo.component.js';
|
|
2
2
|
export default Logo;
|
|
3
|
-
|
|
4
3
|
declare global {
|
|
5
4
|
interface HTMLElementTagNameMap {
|
|
6
5
|
'hot-logo': Logo;
|
|
7
6
|
}
|
|
8
7
|
}
|
|
9
|
-
|
|
10
|
-
// React 19
|
|
11
|
-
declare module "react" {
|
|
12
|
-
namespace JSX {
|
|
13
|
-
interface IntrinsicElements {
|
|
14
|
-
'hot-logo': Logo;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"../../chunks/chunk.PDLGEB7T.js";import"../../chunks/chunk.
|
|
1
|
+
import{a,b}from"../../chunks/chunk.PDLGEB7T.js";import"../../chunks/chunk.QT57GV7H.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as MatomoTracking,b as default};
|
|
@@ -1,17 +1,7 @@
|
|
|
1
1
|
import MatomoTracking from './tracking.component.js';
|
|
2
2
|
export default MatomoTracking;
|
|
3
|
-
|
|
4
3
|
declare global {
|
|
5
4
|
interface HTMLElementTagNameMap {
|
|
6
5
|
'hot-tracking': MatomoTracking;
|
|
7
6
|
}
|
|
8
7
|
}
|
|
9
|
-
|
|
10
|
-
// React 19
|
|
11
|
-
declare module "react" {
|
|
12
|
-
namespace JSX {
|
|
13
|
-
interface IntrinsicElements {
|
|
14
|
-
'hot-tracking': MatomoTracking;
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunks/chunk.YYEOK7MA.js";import"../../chunks/chunk.PDLGEB7T.js";import"../../chunks/chunk.
|
|
1
|
+
import{a}from"../../chunks/chunk.YYEOK7MA.js";import"../../chunks/chunk.PDLGEB7T.js";import"../../chunks/chunk.QT57GV7H.js";import"../../chunks/chunk.O2GMJYSL.js";import"../../chunks/chunk.CS444ZXM.js";import"../../chunks/chunk.6ZDEZIWM.js";import"../../chunks/chunk.U4P7XQR4.js";import"../../chunks/chunk.NI7UJOOZ.js";export{a as default};
|
package/dist/hotosm-ui.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as o}from"./chunks/chunk.
|
|
1
|
+
import{a as o}from"./chunks/chunk.EROFXAZH.js";import"./chunks/chunk.EMBNMR2N.js";import"./chunks/chunk.HQE63XEZ.js";import{a as t}from"./chunks/chunk.SZ46YTWY.js";import"./chunks/chunk.7RJ72M75.js";import"./chunks/chunk.UTSKEKTV.js";import{a as r}from"./chunks/chunk.YYEOK7MA.js";import"./chunks/chunk.PDLGEB7T.js";import{a}from"./chunks/chunk.H5ZQREL2.js";import"./chunks/chunk.HDZFWGNV.js";import"./chunks/chunk.U4GEH6YR.js";import{a as m}from"./chunks/chunk.UYOJKKGV.js";import"./chunks/chunk.CS56NBTQ.js";import"./chunks/chunk.QT57GV7H.js";import"./chunks/chunk.O2GMJYSL.js";import"./chunks/chunk.CS444ZXM.js";import"./chunks/chunk.6ZDEZIWM.js";import"./chunks/chunk.KO4EOD3I.js";import"./chunks/chunk.T4GALJJA.js";import"./chunks/chunk.U4P7XQR4.js";import"./chunks/chunk.NI7UJOOZ.js";export{a as Button,m as Consent,o as Header,t as Logo,r as Tracking};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hotosm/ui",
|
|
3
|
-
"version": "0.3.2-
|
|
3
|
+
"version": "0.3.2-b4",
|
|
4
4
|
"description": "Shared UI components with HOT theming.",
|
|
5
5
|
"homepage": "https://github.com/hotosm/ui#readme",
|
|
6
6
|
"author": {
|
|
@@ -48,20 +48,19 @@
|
|
|
48
48
|
"engines": {
|
|
49
49
|
"node": ">=14.17.0"
|
|
50
50
|
},
|
|
51
|
-
"dependencies": {
|
|
52
|
-
"@awesome.me/webawesome": "3.0.0-beta.1",
|
|
53
|
-
"class-variance-authority": "^0.7.0",
|
|
54
|
-
"lit": "^3.0.0"
|
|
55
|
-
},
|
|
56
51
|
"devDependencies": {
|
|
52
|
+
"@awesome.me/webawesome": "3.0.0-beta.1",
|
|
57
53
|
"@storybook/addon-essentials": "^8.3.5",
|
|
58
54
|
"@storybook/addon-links": "^8.3.5",
|
|
59
55
|
"@storybook/blocks": "^8.3.5",
|
|
60
56
|
"@storybook/web-components": "^8.2.9",
|
|
61
57
|
"@storybook/web-components-vite": "^8.2.9",
|
|
58
|
+
"@teamhanko/hanko-elements": "^2.1.0",
|
|
59
|
+
"class-variance-authority": "^0.7.0",
|
|
62
60
|
"del": "^7.1.0",
|
|
63
61
|
"esbuild": "^0.19.4",
|
|
64
62
|
"globby": "^14.0.2",
|
|
63
|
+
"lit": "^3.0.0",
|
|
65
64
|
"storybook": "^8.2.9",
|
|
66
65
|
"typescript": "^5.2.2",
|
|
67
66
|
"user-agent-data-types": "^0.3.1"
|
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as e}from"./chunk.O6Q54UVK.js";var r=e;customElements.define("hot-header",e);export{r as a};
|