@maelstrom-futurism/core 0.9.0 → 0.9.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.
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createContext as M,useContext as g}from"react";var I=/* @__PURE__ */(A=>(A[A.LOW=0]="LOW",A[A.MEDIUM=1]="MEDIUM",A[A.HIGH=2]="HIGH",A))(I||{}),C=/* @__PURE__ */(A=>(A[A.NORTH=0]="NORTH",A[A.NORTHEAST=1]="NORTHEAST",A[A.EAST=2]="EAST",A[A.SOUTHEAST=3]="SOUTHEAST",A[A.SOUTH=4]="SOUTH",A[A.SOUTHWEST=5]="SOUTHWEST",A[A.WEST=6]="WEST",A[A.NORTHWEST=7]="NORTHWEST",A))(C||{});const w={base:"16px",sm:"0.707em",normal:"1em",md:"1.414em",lg:"2em",xl:"2.827em",xxl:"4em"},Y=["0","4","8","16","24","32","40","48","64"],F={xs:"0px",sm:"576px",md:"992px",lg:"1200px"},U={bottom:"-1000",low:"-100",sunk:"-10",normal:"0",raised:"10",high:"100",top:"1000"},D={input:"8px",button:"16px",card:"24px",pill:"9999px"};class N{colors;sizes={...w};breakpoints={...F};space=[...Y];heights={...U};borderRadius=D.card;inputRadius=D.input;buttonRadius=D.button;pillRadius=D.pill;size(A){return this.sizes[A]}color=A=>this.colors[A];bp=A=>this.breakpoints[A];height=A=>this.heights[A];constructor(A){this.colors=A.colorSet}}const R={nordDark:{background:"#242933",borderMuted:"#303744",border:"#2e3440",content:"#2e3440",textColor:"#eceff4",linkColor:"#88c0d0",primary:"#5e81ac",secondary:"#81a1c1",alert:"#bf616a",warning:"#ebcb8b",success:"#a3be8c",info:"#5e81ac"},nordLight:{background:"#eceff4",borderMuted:"#303744",border:"#2e3440",content:"#eceff4",textColor:"#242933",linkColor:"#88c0d0",primary:"#5e81ac",secondary:"#81a1c1",alert:"#bf616a",warning:"#ebcb8b",success:"#a3be8c",info:"#5e81ac"}},G=(A,B)=>{const Q=B?.colors?{...R[A],...B.colors}:R[A],E=new N({colorSet:Q});if(B?.radii){const{input:A,button:Q,card:M,pill:g}=B.radii;void 0!==A&&(E.inputRadius=A),void 0!==Q&&(E.buttonRadius=Q),void 0!==M&&(E.borderRadius=M),void 0!==g&&(E.pillRadius=g)}return B?.sizes&&(E.sizes={...w,...B.sizes}),E},j="cubic-bezier(.65, .05, .36, 1)",c=M(G("nordDark")),J=()=>g(c),z=({theme:M,children:g})=>{const I=M,C="#242933"===I.color("background"),w=C?"#d8dee9":"#3b4252",Y=C?"#3b4252":"#e5e9f0",F=C?"#434c5e":"#d8dee9",U=A`
1
+ import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createContext as M,useContext as g}from"react";var I=/* @__PURE__ */(A=>(A[A.LOW=0]="LOW",A[A.MEDIUM=1]="MEDIUM",A[A.HIGH=2]="HIGH",A))(I||{}),C=/* @__PURE__ */(A=>(A[A.NORTH=0]="NORTH",A[A.NORTHEAST=1]="NORTHEAST",A[A.EAST=2]="EAST",A[A.SOUTHEAST=3]="SOUTHEAST",A[A.SOUTH=4]="SOUTH",A[A.SOUTHWEST=5]="SOUTHWEST",A[A.WEST=6]="WEST",A[A.NORTHWEST=7]="NORTHWEST",A))(C||{});const w={base:"16px",sm:"0.707em",normal:"1em",md:"1.414em",lg:"2em",xl:"2.827em",xxl:"4em"},Y=["0","4","8","16","24","32","40","48","64"],F={xs:"0px",sm:"576px",md:"992px",lg:"1200px"},U={bottom:"-1000",low:"-100",sunk:"-10",normal:"0",raised:"10",high:"100",top:"1000"},D={input:"8px",button:"16px",card:"24px",pill:"9999px"},N={tight:"1.2",normal:"1.5",relaxed:"1.6"},R={tight:"-0.01em",normal:"0",wide:"0.04em",display:"0.06em"};class G{colors;sizes={...w};breakpoints={...F};space=[...Y];heights={...U};borderRadius=D.card;inputRadius=D.input;buttonRadius=D.button;pillRadius=D.pill;durations={fast:"100ms",normal:"200ms",slow:"300ms",ripple:"1000ms"};lineHeights={...N};letterSpacings={...R};size(A){return this.sizes[A]}color=A=>this.colors[A];bp=A=>this.breakpoints[A];height=A=>this.heights[A];constructor(A){this.colors=A.colorSet}}const j={nordDark:{background:"#242933",borderMuted:"#303744",border:"#2e3440",content:"#2e3440",textColor:"#eceff4",linkColor:"#88c0d0",primary:"#5e81ac",secondary:"#81a1c1",focus:"#5e81ac",active:"#5e81ac",alert:"#bf616a",warning:"#ebcb8b",success:"#a3be8c",info:"#5e81ac"},nordLight:{background:"#eceff4",borderMuted:"#303744",border:"#2e3440",content:"#eceff4",textColor:"#242933",linkColor:"#88c0d0",primary:"#5e81ac",secondary:"#81a1c1",focus:"#5e81ac",active:"#5e81ac",alert:"#bf616a",warning:"#ebcb8b",success:"#a3be8c",info:"#5e81ac"}},c=(A,B)=>{const Q=B?.colors?{...j[A],...B.colors}:j[A],E=new G({colorSet:Q});if(B?.radii){const{input:A,button:Q,card:M,pill:g}=B.radii;void 0!==A&&(E.inputRadius=A),void 0!==Q&&(E.buttonRadius=Q),void 0!==M&&(E.borderRadius=M),void 0!==g&&(E.pillRadius=g)}return B?.sizes&&(E.sizes={...w,...B.sizes}),B?.durations&&(E.durations={...E.durations,...B.durations}),B?.lineHeights&&(E.lineHeights={...E.lineHeights,...B.lineHeights}),B?.letterSpacings&&(E.letterSpacings={...E.letterSpacings,...B.letterSpacings}),E},J="cubic-bezier(.65, .05, .36, 1)",z=M(c("nordDark")),T=()=>g(z),h=({theme:M,children:g})=>{const I=M,C="#242933"===I.color("background"),w=C?"#d8dee9":"#3b4252",Y=C?"#3b4252":"#e5e9f0",F=C?"#434c5e":"#d8dee9",U=A`
2
2
  :root {
3
3
  /* Semantic colors */
4
4
  --mf-background: ${I.color("background")};
@@ -10,6 +10,8 @@ import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createCo
10
10
  --mf-link: ${I.color("linkColor")};
11
11
  --mf-primary: ${I.color("primary")};
12
12
  --mf-secondary: ${I.color("secondary")};
13
+ --mf-focus: ${I.color("focus")};
14
+ --mf-active: ${I.color("active")};
13
15
  --mf-alert: ${I.color("alert")};
14
16
  --mf-warning: ${I.color("warning")};
15
17
  --mf-success: ${I.color("success")};
@@ -82,12 +84,37 @@ import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createCo
82
84
  --mf-z-high: ${I.heights.high};
83
85
  --mf-z-top: ${I.heights.top};
84
86
 
87
+ /* Line heights */
88
+ --mf-lh-tight: ${I.lineHeights.tight};
89
+ --mf-lh-normal: ${I.lineHeights.normal};
90
+ --mf-lh-relaxed: ${I.lineHeights.relaxed};
91
+
92
+ /* Letter spacings */
93
+ --mf-ls-tight: ${I.letterSpacings.tight};
94
+ --mf-ls-normal: ${I.letterSpacings.normal};
95
+ --mf-ls-wide: ${I.letterSpacings.wide};
96
+ --mf-ls-display: ${I.letterSpacings.display};
97
+
85
98
  /* Motion */
86
- --mf-ease: ${j};
87
- --mf-dur-fast: 100ms;
88
- --mf-dur-normal: 200ms;
89
- --mf-dur-slow: 300ms;
90
- --mf-dur-ripple: 1000ms;
99
+ --mf-ease: ${J};
100
+ --mf-dur-fast: ${I.durations.fast};
101
+ --mf-dur-normal: ${I.durations.normal};
102
+ --mf-dur-slow: ${I.durations.slow};
103
+ --mf-dur-ripple: ${I.durations.ripple};
104
+ }
105
+
106
+ @media (prefers-reduced-motion: reduce) {
107
+ :root {
108
+ --mf-dur-fast: 1ms;
109
+ --mf-dur-normal: 1ms;
110
+ --mf-dur-slow: 1ms;
111
+ --mf-dur-ripple: 1ms;
112
+ }
113
+ }
114
+
115
+ *:focus-visible {
116
+ outline: 2px solid var(--mf-focus);
117
+ outline-offset: 2px;
91
118
  }
92
119
 
93
120
  html {
@@ -149,22 +176,22 @@ import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createCo
149
176
  font-family: Poppins;
150
177
  font-size: ${I.size("base")};
151
178
  font-weight: 400;
152
- line-height: 1.5;
179
+ line-height: var(--mf-lh-normal);
153
180
  }
154
181
 
155
182
  h1, h2, h3, h4, h5, h6 {
156
183
  margin: ${I.space[1]}px 0;
157
184
  font-family: var(--mf-font-sans);
158
185
  font-weight: 500;
159
- line-height: 1.2;
160
- letter-spacing: -0.01em;
186
+ line-height: var(--mf-lh-tight);
187
+ letter-spacing: var(--mf-ls-tight);
161
188
  }
162
189
  h1 { font-size: ${I.sizes.xxl}; }
163
190
  h2 { font-size: ${I.sizes.xl}; }
164
191
  h3 { font-size: ${I.sizes.lg}; }
165
192
  h4 { font-size: ${I.sizes.md}; }
166
- h5 { font-size: ${I.sizes.normal}; text-transform: uppercase; letter-spacing: 0.06em; }
167
- h6 { font-size: ${I.sizes.sm}; text-transform: uppercase; letter-spacing: 0.08em; }
193
+ h5 { font-size: ${I.sizes.normal}; text-transform: uppercase; letter-spacing: var(--mf-ls-display); }
194
+ h6 { font-size: ${I.sizes.sm}; text-transform: uppercase; letter-spacing: var(--mf-ls-display); }
168
195
 
169
196
  p {
170
197
  margin: 0 0 16px;
@@ -174,7 +201,7 @@ import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createCo
174
201
  a {
175
202
  color: ${I.color("linkColor")};
176
203
  text-decoration: none;
177
- transition: color 100ms ${j};
204
+ transition: color var(--mf-dur-fast) ${J};
178
205
  }
179
206
  a:hover {
180
207
  text-decoration: underline;
@@ -196,7 +223,7 @@ import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createCo
196
223
  .mf-display, .mf-pixel {
197
224
  font-family: "Silkscreen", "Poppins", system-ui, sans-serif;
198
225
  font-weight: 400;
199
- letter-spacing: 0.04em;
226
+ letter-spacing: var(--mf-ls-wide);
200
227
  text-transform: uppercase;
201
228
  }
202
229
 
@@ -208,8 +235,8 @@ import{c as A,j as B,a as Q,G as E}from"./@emotion-DDqJX_w5.mjs";import{createCo
208
235
  color: ${I.color("textColor")}80;
209
236
  }
210
237
  `;/* @__PURE__ */
211
- return B(c.Provider,{value:I,children:[
212
- /* @__PURE__ */Q(E,{styles:U}),g]})},T={bg:"background",w:"width",h:"height",m:"margin",p:"padding"},h=B=>{const E=J(),M=(A=>{const B={};for(const[Q,E]of Object.entries(A))B[T[Q]||Q]=E;return B})(B),{css:g,children:I,...C}=B,w=A`
238
+ return B(z.Provider,{value:I,children:[
239
+ /* @__PURE__ */Q(E,{styles:U}),g]})},i={bg:"background",w:"width",h:"height",m:"margin",p:"padding"},V=B=>{const E=T(),M=(A=>{const B={};for(const[Q,E]of Object.entries(A))B[i[Q]||Q]=E;return B})(B),{css:g,children:I,...C}=B,w=A`
213
240
  width: ${M.width||"100%"};
214
241
  ${M.height&&`height: ${M.height};`}
215
242
  ${M.margin&&`margin: ${M.margin};`}
@@ -217,7 +244,7 @@ return B(c.Provider,{value:I,children:[
217
244
  ${M.border&&`border: ${M.border};`}
218
245
  border-radius: ${E.borderRadius};
219
246
  `;/* @__PURE__ */
220
- return Q("div",{css:[w,g],...C,children:I})},V=({background:B,border:E,children:M,variant:g,...I})=>{const C=((B,Q,E,M)=>{if(Q||E)return A`
247
+ return Q("div",{css:[w,g],...C,children:I})},H=({background:B,border:E,children:M,variant:g,...I})=>{const C=((B,Q,E,M)=>{if(Q||E)return A`
221
248
  background-color: ${Q||B.color("content")};
222
249
  border: ${E||B.color("secondary")};
223
250
  `;switch(M){case"alert":case"error":return A`
@@ -236,11 +263,11 @@ return Q("div",{css:[w,g],...C,children:I})},V=({background:B,border:E,children:
236
263
  `;default:return A`
237
264
  background-color: ${Q||B.color("content")};
238
265
  border: ${E||B.color("secondary")};
239
- `}})(J(),B,E,g),w=A`
266
+ `}})(T(),B,E,g),w=A`
240
267
  padding: 0.75rem;
241
268
  margin-bottom: 0.25rem;
242
269
  `;/* @__PURE__ */
243
- return Q(h,{css:[C,w],...I,children:M})},i=({variant:E="info",dot:M=!1,children:g,css:I,...C})=>{const w=J(),Y=((A,B)=>({success:B.color("success"),warning:B.color("warning"),alert:B.color("alert"),info:B.color("linkColor"),muted:`${B.color("textColor")}80`}[A]))(E,w),F=A`
270
+ return Q(V,{css:[C,w],...I,children:M})},k=({variant:E="info",dot:M=!1,children:g,css:I,...C})=>{const w=T(),Y=((A,B)=>({success:B.color("success"),warning:B.color("warning"),alert:B.color("alert"),info:B.color("linkColor"),muted:`${B.color("textColor")}80`}[A]))(E,w),F=A`
244
271
  display: inline-flex;
245
272
  align-items: center;
246
273
  gap: 6px;
@@ -258,7 +285,7 @@ return Q(h,{css:[C,w],...I,children:M})},i=({variant:E="info",dot:M=!1,children:
258
285
  background: currentColor;
259
286
  flex-shrink: 0;
260
287
  `;/* @__PURE__ */
261
- return B("span",{css:[F,I],...C,children:[M&&/* @__PURE__ */Q("span",{css:U,"aria-hidden":"true"}),g]})},H=A=>/* @__PURE__ */B("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 192 192",shapeRendering:"crispEdges",role:"img","aria-label":"Maelstrom-Futurism mark",...A,children:[
288
+ return B("span",{css:[F,I],...C,children:[M&&/* @__PURE__ */Q("span",{css:U,"aria-hidden":"true"}),g]})},W=A=>/* @__PURE__ */B("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 192 192",shapeRendering:"crispEdges",role:"img","aria-label":"Maelstrom-Futurism mark",...A,children:[
262
289
  /* @__PURE__ */Q("title",{children:"Maelstrom-Futurism"}),
263
290
  /* @__PURE__ */Q("rect",{x:"114",y:"120",width:"6",height:"6",fill:"currentColor",fillOpacity:"0.55"}),
264
291
  /* @__PURE__ */Q("rect",{x:"108",y:"114",width:"6",height:"6",fill:"currentColor",fillOpacity:"0.47"}),
@@ -543,7 +570,7 @@ return B("span",{css:[F,I],...C,children:[M&&/* @__PURE__ */Q("span",{css:U,"ari
543
570
  /* @__PURE__ */Q("rect",{x:"60",y:"162",width:"6",height:"6",fill:"currentColor",fillOpacity:"0.54"}),
544
571
  /* @__PURE__ */Q("rect",{x:"36",y:"150",width:"6",height:"6",fill:"currentColor",fillOpacity:"1.00"}),
545
572
  /* @__PURE__ */Q("rect",{x:"30",y:"144",width:"6",height:"6",fill:"currentColor",fillOpacity:"1.00"}),
546
- /* @__PURE__ */Q("rect",{x:"30",y:"138",width:"6",height:"6",fill:"currentColor",fillOpacity:"1.00"})]}),k=A=>/* @__PURE__ */B("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 192 192",shapeRendering:"crispEdges",role:"img","aria-label":"Maelstrom-Futurism mark (flat)",...A,children:[
573
+ /* @__PURE__ */Q("rect",{x:"30",y:"138",width:"6",height:"6",fill:"currentColor",fillOpacity:"1.00"})]}),S=A=>/* @__PURE__ */B("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 192 192",shapeRendering:"crispEdges",role:"img","aria-label":"Maelstrom-Futurism mark (flat)",...A,children:[
547
574
  /* @__PURE__ */Q("title",{children:"Maelstrom-Futurism"}),
548
575
  /* @__PURE__ */Q("rect",{x:"114",y:"120",width:"6",height:"6",fill:"currentColor"}),
549
576
  /* @__PURE__ */Q("rect",{x:"108",y:"114",width:"6",height:"6",fill:"currentColor"}),
@@ -828,4 +855,4 @@ return B("span",{css:[F,I],...C,children:[M&&/* @__PURE__ */Q("span",{css:U,"ari
828
855
  /* @__PURE__ */Q("rect",{x:"60",y:"162",width:"6",height:"6",fill:"currentColor"}),
829
856
  /* @__PURE__ */Q("rect",{x:"36",y:"150",width:"6",height:"6",fill:"currentColor"}),
830
857
  /* @__PURE__ */Q("rect",{x:"30",y:"144",width:"6",height:"6",fill:"currentColor"}),
831
- /* @__PURE__ */Q("rect",{x:"30",y:"138",width:"6",height:"6",fill:"currentColor"})]}),W=A=>A.charAt(0).toUpperCase()+A.slice(1),S=A=>A.toLowerCase().split(" ").map((A,B)=>["a","an","to","the","of"].includes(A)&&B>0?A:W(A)).join(" "),y=A=>A&&"[object Function]"===Object.prototype.toString.call(A),x=A=>"string"==typeof A||A instanceof String,l=(A,B)=>{let Q=0;return(...E)=>{clearTimeout(Q),Q=setTimeout(()=>A(...E),B)}};export{F as BREAKPOINTS,h as Box,C as CardinalDirection,V as ContentBox,j as EASE_FUNCTION,U as HEIGHTS,I as Intensity,H as LogoMark,k as LogoMarkFlat,i as Pill,D as RADII,w as SIZES,Y as SPACES,N as Theme,z as ThemeProvider,W as capitalize,G as createTheme,l as debounce,y as isFunction,x as isString,S as titleCase,J as useTheme};
858
+ /* @__PURE__ */Q("rect",{x:"30",y:"138",width:"6",height:"6",fill:"currentColor"})]}),y=A=>A.charAt(0).toUpperCase()+A.slice(1),x=A=>A.toLowerCase().split(" ").map((A,B)=>["a","an","to","the","of"].includes(A)&&B>0?A:y(A)).join(" "),l=A=>A&&"[object Function]"===Object.prototype.toString.call(A),s=A=>"string"==typeof A||A instanceof String,P=(A,B)=>{let Q=0;return(...E)=>{clearTimeout(Q),Q=setTimeout(()=>A(...E),B)}};export{F as BREAKPOINTS,V as Box,C as CardinalDirection,H as ContentBox,J as EASE_FUNCTION,U as HEIGHTS,I as Intensity,R as LETTER_SPACINGS,N as LINE_HEIGHTS,W as LogoMark,S as LogoMarkFlat,k as Pill,D as RADII,w as SIZES,Y as SPACES,G as Theme,h as ThemeProvider,y as capitalize,c as createTheme,P as debounce,l as isFunction,s as isString,x as titleCase,T as useTheme};
@@ -8,6 +8,8 @@ export interface ColorSet {
8
8
  linkColor: string;
9
9
  primary: string;
10
10
  secondary: string;
11
+ focus: string;
12
+ active: string;
11
13
  alert: string;
12
14
  warning: string;
13
15
  success: string;
@@ -1 +1 @@
1
- {"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../lib/interfaces.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEvD,MAAM,WAAW,QAAQ;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,O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version":3,"file":"ThemeProvider.d.ts","sourceRoot":"","sources":["../../lib/themes/ThemeProvider.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,SAAS,EAA6B,MAAM,OAAO,CAAC;AASpE,OAAO,KAAK,MAAM,SAAS,CAAC;AAK5B,eAAO,MAAM,QAAQ,aAAiC,CAAC;AAEvD,UAAU,kBAAkB;IACxB,KAAK,EAAE,KAAK,CAAC;IACb,QAAQ,EAAE,SAAS,CAAC;CACvB;AAED,eAAO,MAAM,aAAa,GAAI,qBAAqB,kBAAkB,KAAG,SAiOvE,CAAC"}
1
+ {"version":3,"file":"ThemeProvider.d.ts","sourceRoot":"","sources":["../../lib/themes/ThemeProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAA6B,MAAM,OAAO,CAAC;AAS7D,OAAO,KAAK,MAAM,SAAS,CAAC;AAK5B,eAAO,MAAM,QAAQ,aAAiC,CAAC;AAEvD,UAAU,kBAAkB;IACxB,KAAK,EAAE,KAAK,CAAC;IACb,QAAQ,EAAE,SAAS,CAAC;CACvB;AAED,eAAO,MAAM,aAAa,GAAI,qBAAqB,kBAAkB,KAAG,SA4PvE,CAAC"}
@@ -18,6 +18,23 @@ export interface ThemeOverrides {
18
18
  xl?: string;
19
19
  xxl?: string;
20
20
  };
21
+ durations?: {
22
+ fast?: string;
23
+ normal?: string;
24
+ slow?: string;
25
+ ripple?: string;
26
+ };
27
+ lineHeights?: {
28
+ tight?: string;
29
+ normal?: string;
30
+ relaxed?: string;
31
+ };
32
+ letterSpacings?: {
33
+ tight?: string;
34
+ normal?: string;
35
+ wide?: string;
36
+ display?: string;
37
+ };
21
38
  }
22
39
  export declare const createTheme: (colorSetName: ColorSetName, overrides?: ThemeOverrides) => Theme;
23
40
  //# sourceMappingURL=createTheme.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"createTheme.d.ts","sourceRoot":"","sources":["../../lib/themes/createTheme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ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AAC;IACF,KAAK,CAAC,EAAE;QACJ,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,EAAE,CAAC,EAAE,MAAM,CAAC;QACZ,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,EAAE,CAAC,EAAE,MAAM,CAAC;QACZ,EAAE,CAAC,EAAE,MAAM,CAAC;QACZ,EAAE,CAAC,EAAE,MAAM,CAAC;QACZ,GAAG,CAAC,EAAE,MAAM,CAAC;KAChB,CAAC;IACF,SAAS,CAAC,EAAE;QACR,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,MAAM,CAAC,EAAE,MAAM,CAAC;KACnB,CAAC;IACF,WAAW,CAAC,EAAE;QACV,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,OAAO,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;IACF,cAAc,CAAC,EAAE;QACb,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,OAAO,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;CACL;AAgDD,eAAO,MAAM,WAAW,GAAI,cAAc,YAAY,EAAE,YAAY,cAAc,KAAG,KAgCpF,CAAC"}
@@ -24,6 +24,23 @@ declare class Theme {
24
24
  inputRadius: string;
25
25
  buttonRadius: string;
26
26
  pillRadius: string;
27
+ durations: {
28
+ fast: string;
29
+ normal: string;
30
+ slow: string;
31
+ ripple: string;
32
+ };
33
+ lineHeights: {
34
+ tight: string;
35
+ normal: string;
36
+ relaxed: string;
37
+ };
38
+ letterSpacings: {
39
+ tight: string;
40
+ normal: string;
41
+ wide: string;
42
+ display: string;
43
+ };
27
44
  size(name: string): string;
28
45
  color: (name: keyof typeof this.colors) => string;
29
46
  bp: (name: keyof typeof this.breakpoints) => string;
@@ -1 +1 @@
1
- {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../lib/themes/theme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AACzD,OAAO,EAAE,KAAK,EAAuC,MAAM,WAAW,CAAC;AAEvE,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;AAElD,cAAM,KAAK;IACT,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC;IAE1B,KAAK,EAAE,MAAM,CAAC,MAAM,OAAO,KAAK,EAAE,MAAM,CAAC,CAAgB;IAEzD,WAAW;;;;;MAAsB;IAEjC,KAAK,gEAAe;IAEpB,OAAO;;;;;;;;MAAkB;IAEzB,YAAY,EAAE,MAAM,CAAc;IAClC,WAAW,EAAE,MAAM,CAAgB;IACnC,YAAY,EAAE,MAAM,CAAgB;IACpC,UAAU,EAAE,MAAM,CAAgB;IAElC,IAAI,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM;IAI1B,KAAK,GAAI,MAAM,MAAM,OAAO,IAAI,CAAC,MAAM,KAAG,MAAM,CAAsB;IACtE,EAAE,GAAI,MAAM,MAAM,OAAO,IAAI,CAAC,WAAW,KAAG,MAAM,CAA2B;IAC7E,MAAM,GAAI,MAAM,MAAM,KAAG,MAAM,CAAoD;gBAEvE,WAAW,EAAE,cAAc;CAGxC;AAED,eAAe,KAAK,CAAC"}
1
+ {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../lib/themes/theme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AACzD,OAAO,EAAE,KAAK,EAAsE,MAAM,WAAW,CAAC;AAEtG,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;AAElD,cAAM,KAAK;IACT,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC;IAE1B,KAAK,EAAE,MAAM,CAAC,MAAM,OAAO,KAAK,EAAE,MAAM,CAAC,CAAgB;IAEzD,WAAW;;;;;MAAsB;IAEjC,KAAK,gEAAe;IAEpB,OAAO;;;;;;;;MAAkB;IAEzB,YAAY,EAAE,MAAM,CAAc;IAClC,WAAW,EAAE,MAAM,CAAgB;IACnC,YAAY,EAAE,MAAM,CAAgB;IACpC,UAAU,EAAE,MAAM,CAAgB;IAElC,SAAS;;;;;MAKP;IAEF,WAAW,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAAuB;IAEtF,cAAc,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAA0B;IAE1G,IAAI,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM;IAI1B,KAAK,GAAI,MAAM,MAAM,OAAO,IAAI,CAAC,MAAM,KAAG,MAAM,CAAsB;IACtE,EAAE,GAAI,MAAM,MAAM,OAAO,IAAI,CAAC,WAAW,KAAG,MAAM,CAA2B;IAC7E,MAAM,GAAI,MAAM,MAAM,KAAG,MAAM,CAAoD;gBAEvE,WAAW,EAAE,cAAc;CAGxC;AAED,eAAe,KAAK,CAAC"}
package/dist/tokens.d.ts CHANGED
@@ -29,4 +29,15 @@ export declare const RADII: {
29
29
  readonly card: "24px";
30
30
  readonly pill: "9999px";
31
31
  };
32
+ export declare const LINE_HEIGHTS: {
33
+ readonly tight: "1.2";
34
+ readonly normal: "1.5";
35
+ readonly relaxed: "1.6";
36
+ };
37
+ export declare const LETTER_SPACINGS: {
38
+ readonly tight: "-0.01em";
39
+ readonly normal: "0";
40
+ readonly wide: "0.04em";
41
+ readonly display: "0.06em";
42
+ };
32
43
  //# sourceMappingURL=tokens.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tokens.d.ts","sourceRoot":"","sources":["../lib/tokens.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,KAAK;;;;;;;;CAQR,CAAC;AAEX,eAAO,MAAM,MAAM,8DAA+D,CAAC;AAEnF,eAAO,MAAM,WAAW;;;;;CAKd,CAAC;AAEX,eAAO,MAAM,OAAO;;;;;;;;CAQV,CAAC;AAEX,eAAO,MAAM,KAAK;;;;;CAKR,CAAC"}
1
+ {"version":3,"file":"tokens.d.ts","sourceRoot":"","sources":["../lib/tokens.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,KAAK;;;;;;;;CAQR,CAAC;AAEX,eAAO,MAAM,MAAM,8DAA+D,CAAC;AAEnF,eAAO,MAAM,WAAW;;;;;CAKd,CAAC;AAEX,eAAO,MAAM,OAAO;;;;;;;;CAQV,CAAC;AAEX,eAAO,MAAM,KAAK;;;;;CAKR,CAAC;AAEX,eAAO,MAAM,YAAY;;;;CAIf,CAAC;AAEX,eAAO,MAAM,eAAe;;;;;CAKlB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maelstrom-futurism/core",
3
- "version": "0.9.0",
3
+ "version": "0.9.1",
4
4
  "description": "Core package for shared resources in Maelstrom Futurism",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -29,5 +29,5 @@
29
29
  "url": "https://github.com/DawsonG/maelstrom-futurism/issues"
30
30
  },
31
31
  "homepage": "https://github.com/DawsonG/maelstrom-futurism#readme",
32
- "gitHead": "5034af01ee5ea4d23abc4b678e0c66c73bae417a"
32
+ "gitHead": "e70900f407baeb2e060065ccaee259390e686ca6"
33
33
  }