timvir 0.2.39 → 0.2.43

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 (73) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/blocks/Arbitrary/Arbitrary.d.ts +1 -1
  3. package/blocks/Arbitrary/index.js +200 -47
  4. package/blocks/Arbitrary/styles.css +222 -6
  5. package/blocks/Code/Code.d.ts +0 -6
  6. package/blocks/Code/docs/index.mdx +0 -11
  7. package/blocks/Code/index.js +211 -110
  8. package/blocks/Code/styles.css +158 -15
  9. package/blocks/ColorBar/docs/index.mdx +8 -2
  10. package/blocks/ColorBar/index.js +205 -46
  11. package/blocks/ColorBar/styles.css +157 -4
  12. package/blocks/ColorBook/docs/index.mdx +1 -1
  13. package/blocks/ColorBook/index.js +205 -39
  14. package/blocks/ColorBook/styles.css +224 -6
  15. package/blocks/Cover/index.js +175 -34
  16. package/blocks/Cover/styles.css +82 -0
  17. package/blocks/Exhibit/index.js +199 -40
  18. package/blocks/Exhibit/styles.css +126 -3
  19. package/blocks/Font/index.js +196 -58
  20. package/blocks/Font/styles.css +142 -8
  21. package/blocks/Grid/docs/index.mdx +4 -4
  22. package/blocks/Grid/index.js +183 -33
  23. package/blocks/Grid/styles.css +78 -1
  24. package/blocks/Icon/docs/index.mdx +13 -13
  25. package/blocks/Icon/index.js +25 -43
  26. package/blocks/Icon/styles.css +117 -5
  27. package/blocks/Message/docs/index.mdx +5 -8
  28. package/blocks/Message/index.js +240 -54
  29. package/blocks/Message/styles.css +154 -6
  30. package/blocks/Swatch/docs/index.mdx +16 -16
  31. package/blocks/Swatch/index.js +187 -34
  32. package/blocks/Swatch/styles.css +142 -4
  33. package/blocks/Viewport/index.js +209 -89
  34. package/blocks/Viewport/styles.css +313 -14
  35. package/blocks/WebLink/index.js +199 -47
  36. package/blocks/WebLink/styles.css +226 -8
  37. package/blocks/styles.css +2158 -97
  38. package/builtins/components.d.ts +2 -2
  39. package/builtins/index.d.ts +0 -1
  40. package/builtins/index.js +307 -243
  41. package/builtins/styles.css +323 -25
  42. package/context/index.d.ts +6 -1
  43. package/core/components/Commands/Commands.d.ts +5 -1
  44. package/core/components/NavigationFooter/NavigationFooter.d.ts +4 -2
  45. package/core/components/Page/Page.d.ts +12 -3
  46. package/core/components/Page/docs/index.mdx +44 -11
  47. package/core/index.d.ts +191 -2
  48. package/core/index.js +415 -256
  49. package/core/layout.d.ts +41 -0
  50. package/core/styles.css +857 -88
  51. package/global.css +79 -0
  52. package/internal/cx.d.ts +1 -0
  53. package/package.json +1 -2
  54. package/search/index.js +2 -223
  55. package/styles.css +3426 -235
  56. package/blocks/Code/theme.d.ts +0 -2
  57. package/bus/styles.css +0 -1
  58. package/context/styles.css +0 -1
  59. package/core/theme/index.d.ts +0 -1
  60. package/hooks/styles.css +0 -1
  61. package/search/Search/internal/Dialog.d.ts +0 -20
  62. package/search/Search/internal/index.d.ts +0 -1
  63. package/search/SearchBoxInput/SearchBoxInput.d.ts +0 -11
  64. package/search/SearchBoxInput/docs/api.mdx +0 -76
  65. package/search/SearchBoxInput/docs/index.mdx +0 -6
  66. package/search/SearchBoxInput/index.d.ts +0 -1
  67. package/search/SearchBoxInput/samples/basic.d.ts +0 -1
  68. package/search/SearchBoxListItem/SearchBoxListItem.d.ts +0 -13
  69. package/search/SearchBoxListItem/docs/api.mdx +0 -76
  70. package/search/SearchBoxListItem/docs/index.mdx +0 -30
  71. package/search/SearchBoxListItem/index.d.ts +0 -1
  72. package/search/SearchBoxListItem/samples/basic.d.ts +0 -1
  73. package/search/styles.css +0 -16
@@ -1,51 +1,177 @@
1
1
  import * as React from 'react';
2
2
  import { jsx, jsxs } from 'react/jsx-runtime';
3
3
 
4
- // src/css.ts
5
-
6
- // src/cx.ts
7
- var cx = function cx2() {
8
- const presentClassNames = Array.prototype.slice.call(arguments).filter(Boolean);
9
- const atomicClasses = {};
10
- const nonAtomicClasses = [];
11
- presentClassNames.forEach((arg) => {
12
- const individualClassNames = arg ? arg.split(" ") : [];
13
- individualClassNames.forEach((className) => {
14
- if (className.startsWith("atm_")) {
15
- const [, keyHash] = className.split("_");
16
- atomicClasses[keyHash] = className;
17
- } else {
18
- nonAtomicClasses.push(className);
19
- }
4
+ var styleq = {};
5
+ var hasRequiredStyleq;
6
+ function requireStyleq() {
7
+ if (hasRequiredStyleq) return styleq;
8
+ hasRequiredStyleq = 1;
9
+ Object.defineProperty(styleq, "__esModule", {
10
+ value: true
20
11
  });
21
- });
22
- const result = [];
23
- for (const keyHash in atomicClasses) {
24
- if (Object.prototype.hasOwnProperty.call(atomicClasses, keyHash)) {
25
- result.push(atomicClasses[keyHash]);
12
+ styleq.styleq = void 0;
13
+ var cache = new WeakMap();
14
+ var compiledKey = '$$css';
15
+ function createStyleq(options) {
16
+ var disableCache;
17
+ var disableMix;
18
+ var transform;
19
+ if (options != null) {
20
+ disableCache = options.disableCache === true;
21
+ disableMix = options.disableMix === true;
22
+ transform = options.transform;
23
+ }
24
+ return function styleq() {
25
+ var definedProperties = [];
26
+ var className = '';
27
+ var inlineStyle = null;
28
+ var debugString = '';
29
+ var nextCache = disableCache ? null : cache;
30
+ var styles = new Array(arguments.length);
31
+ for(var i = 0; i < arguments.length; i++){
32
+ styles[i] = arguments[i];
33
+ }
34
+ while(styles.length > 0){
35
+ var possibleStyle = styles.pop();
36
+ if (possibleStyle == null || possibleStyle === false) {
37
+ continue;
38
+ }
39
+ if (Array.isArray(possibleStyle)) {
40
+ for(var _i = 0; _i < possibleStyle.length; _i++){
41
+ styles.push(possibleStyle[_i]);
42
+ }
43
+ continue;
44
+ }
45
+ var style = transform != null ? transform(possibleStyle) : possibleStyle;
46
+ if (style.$$css != null) {
47
+ var classNameChunk = '';
48
+ if (nextCache != null && nextCache.has(style)) {
49
+ var cacheEntry = nextCache.get(style);
50
+ if (cacheEntry != null) {
51
+ classNameChunk = cacheEntry[0];
52
+ debugString = cacheEntry[2];
53
+ definedProperties.push.apply(definedProperties, cacheEntry[1]);
54
+ nextCache = cacheEntry[3];
55
+ }
56
+ } else {
57
+ var definedPropertiesChunk = [];
58
+ for(var prop in style){
59
+ var value = style[prop];
60
+ if (prop === compiledKey) {
61
+ var compiledKeyValue = style[prop];
62
+ if (compiledKeyValue !== true) {
63
+ debugString = debugString ? compiledKeyValue + '; ' + debugString : compiledKeyValue;
64
+ }
65
+ continue;
66
+ }
67
+ if (typeof value === 'string' || value === null) {
68
+ if (!definedProperties.includes(prop)) {
69
+ definedProperties.push(prop);
70
+ if (nextCache != null) {
71
+ definedPropertiesChunk.push(prop);
72
+ }
73
+ if (typeof value === 'string') {
74
+ classNameChunk += classNameChunk ? ' ' + value : value;
75
+ }
76
+ }
77
+ } else {
78
+ console.error("styleq: ".concat(prop, " typeof ").concat(String(value), " is not \"string\" or \"null\"."));
79
+ }
80
+ }
81
+ if (nextCache != null) {
82
+ var weakMap = new WeakMap();
83
+ nextCache.set(style, [
84
+ classNameChunk,
85
+ definedPropertiesChunk,
86
+ debugString,
87
+ weakMap
88
+ ]);
89
+ nextCache = weakMap;
90
+ }
91
+ }
92
+ if (classNameChunk) {
93
+ className = className ? classNameChunk + ' ' + className : classNameChunk;
94
+ }
95
+ } else {
96
+ if (disableMix) {
97
+ if (inlineStyle == null) {
98
+ inlineStyle = {};
99
+ }
100
+ inlineStyle = Object.assign({}, style, inlineStyle);
101
+ } else {
102
+ var subStyle = null;
103
+ for(var _prop in style){
104
+ var _value = style[_prop];
105
+ if (_value !== undefined) {
106
+ if (!definedProperties.includes(_prop)) {
107
+ if (_value != null) {
108
+ if (inlineStyle == null) {
109
+ inlineStyle = {};
110
+ }
111
+ if (subStyle == null) {
112
+ subStyle = {};
113
+ }
114
+ subStyle[_prop] = _value;
115
+ }
116
+ definedProperties.push(_prop);
117
+ nextCache = null;
118
+ }
119
+ }
120
+ }
121
+ if (subStyle != null) {
122
+ inlineStyle = Object.assign(subStyle, inlineStyle);
123
+ }
124
+ }
125
+ }
126
+ }
127
+ var styleProps = [
128
+ className,
129
+ inlineStyle,
130
+ debugString
131
+ ];
132
+ return styleProps;
133
+ };
26
134
  }
27
- }
28
- result.push(...nonAtomicClasses);
29
- return result.join(" ");
30
- };
31
- var cx_default = cx;
135
+ var styleq$1 = styleq.styleq = createStyleq();
136
+ styleq$1.factory = createStyleq;
137
+ return styleq;
138
+ }
139
+ var styleqExports = requireStyleq();
140
+ function props(...styles) {
141
+ const [className, style, dataStyleSrc] = styleqExports.styleq(styles);
142
+ const result = {};
143
+ if (className != null && className !== '') {
144
+ result.className = className;
145
+ }
146
+ if (style != null && Object.keys(style).length > 0) {
147
+ result.style = style;
148
+ }
149
+ if (dataStyleSrc != null && dataStyleSrc !== '') {
150
+ result['data-style-src'] = dataStyleSrc;
151
+ }
152
+ return result;
153
+ }
154
+
155
+ const layoutStyles = {
156
+ block: {
157
+ kBCFzs: "timvir-s-htle6",
158
+ k7Eaqz: "timvir-s-euugli",
159
+ kogj98: "timvir-s-1t4wa6b",
160
+ $$css: true
161
+ }};
32
162
 
33
- /**
34
- * The underlying DOM element which is rendered by this component.
35
- */
36
163
  const Root = "div";
37
- function ColorBook(props, ref) {
164
+ function ColorBook(props$1, ref) {
38
165
  const {
39
166
  chapters,
40
167
  selectedChapter,
41
168
  onSelectChapter,
42
- className,
43
169
  ...rest
44
- } = props;
170
+ } = props$1;
45
171
  return /*#__PURE__*/jsx(Root, {
46
172
  ref: ref,
47
173
  ...rest,
48
- className: cx_default(className, "rmv2wrl"),
174
+ ...props(layoutStyles.block, styles.root),
49
175
  children: chapters.map(({
50
176
  name,
51
177
  values
@@ -54,27 +180,67 @@ function ColorBook(props, ref) {
54
180
  gridColumn: i + 1
55
181
  },
56
182
  children: [/*#__PURE__*/jsx("div", {
57
- className: cx_default(chapter, i === selectedChapter && activeChapter),
183
+ ...{
184
+ 0: {
185
+ className: "timvir-s-1n2onr6 timvir-s-1ypdohk timvir-s-78zum5 timvir-s-dt5ytf timvir-s-1m3v4wt timvir-s-1hmns74 timvir-s-51xajf timvir-s-1ydowbf timvir-s-e80sof timvir-s-abwq6t timvir-s-b52w3a timvir-s-ktd1bz timvir-s-1cpjm7i timvir-s-k53niv timvir-s-115iamj timvir-s-s2hnm7"
186
+ },
187
+ 1: {
188
+ className: "timvir-s-1n2onr6 timvir-s-1ypdohk timvir-s-78zum5 timvir-s-dt5ytf timvir-s-1m3v4wt timvir-s-1hmns74 timvir-s-51xajf timvir-s-1ydowbf timvir-s-e80sof timvir-s-abwq6t timvir-s-b52w3a timvir-s-1cpjm7i timvir-s-k53niv timvir-s-ach7vw timvir-s-s2hnm7 timvir-s-su9jc6 timvir-s-fbg1o9"
189
+ }
190
+ }[!!(i === selectedChapter) << 0],
58
191
  onClick: () => {
59
192
  if (onSelectChapter) {
60
193
  onSelectChapter(i);
61
194
  }
62
195
  },
63
- children: values.map(value => /*#__PURE__*/jsx("div", {
196
+ children: values.map((value, i) => /*#__PURE__*/jsx("div", {
64
197
  style: {
65
198
  background: value
66
199
  },
67
- className: "d1l94wnr"
200
+ ...props(styles.colorValue, i === 0 ? styles.colorValueFirst : null, i === values.length - 1 ? styles.colorValueLast : null)
68
201
  }, value))
69
202
  }), name && /*#__PURE__*/jsx("div", {
70
- className: cx_default("d1uopbb", i === selectedChapter && "d1vwzhoa"),
203
+ ...{
204
+ 0: {
205
+ className: "timvir-s-2b8uid timvir-s-boafo0 timvir-s-vgvpxu timvir-s-1nmq0fv timvir-s-o5v014"
206
+ },
207
+ 1: {
208
+ className: "timvir-s-2b8uid timvir-s-boafo0 timvir-s-1nmq0fv timvir-s-o5v014 timvir-s-1cdhzux"
209
+ }
210
+ }[!!(i === selectedChapter) << 0],
71
211
  children: name
72
212
  })]
73
213
  }, i))
74
214
  });
75
215
  }
76
216
  var ColorBook$1 = /*#__PURE__*/React.forwardRef(ColorBook);
77
- const chapter = "c1xqhu04";
78
- const activeChapter = "a1y0tcvx";
217
+ const styles = {
218
+ root: {
219
+ k1xSpc: "timvir-s-rvj5dj",
220
+ kxK9yV: "timvir-s-1p3d3bo",
221
+ klIVar: "timvir-s-u6a5m6",
222
+ kGNEyG: "timvir-s-7a106z",
223
+ kzqmXN: "timvir-s-h8yej3",
224
+ $$css: true
225
+ },
226
+ colorValue: {
227
+ kzQI83: "timvir-s-1iyjqo2",
228
+ $$css: true
229
+ },
230
+ colorValueFirst: {
231
+ kIxVMA: "timvir-s-1nrfd8m",
232
+ ksF3WI: "timvir-s-16gx4na",
233
+ kqGeR4: "timvir-s-frllxf",
234
+ kYm2EN: "timvir-s-jppbhk",
235
+ $$css: true
236
+ },
237
+ colorValueLast: {
238
+ kIxVMA: "timvir-s-1ia1hqs",
239
+ ksF3WI: "timvir-s-1a2w583",
240
+ kqGeR4: "timvir-s-1v8xtx2",
241
+ kYm2EN: "timvir-s-uvn51i",
242
+ $$css: true
243
+ }
244
+ };
79
245
 
80
246
  export { ColorBook$1 as ColorBook };
@@ -1,7 +1,225 @@
1
- .rmv2wrl{display:-ms-grid;display:grid;-ms-grid-gap:16px;grid-gap:16px;-ms-grid-auto-columns:1fr;grid-auto-columns:1fr;-webkit-align-items:start;-webkit-box-align:start;-ms-flex-align:start;align-items:start;width:100%;}
2
- .d1l94wnr{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}.d1l94wnr:first-child{border-radius:3px 3px 0 0;}.d1l94wnr:last-child{border-radius:0 0 3px 3px;}
3
- .d1uopbb{text-align:center;font-size:0.75rem;color:var(--timvir-secondary-text-color);margin-top:0.8em;line-height:1;}
4
- .d1vwzhoa{color:var(--timvir-text-color);}
5
- .c1xqhu04{position:relative;cursor:pointer;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;height:200px;}.c1xqhu04::before{position:absolute;top:-2px;right:-2px;bottom:-2px;left:-2px;border-radius:4px;box-shadow:0 0 0 0 rgba(19, 124, 189, 0);content:"";-webkit-transition:all 0.16s cubic-bezier(0.4, 1, 0.75, 0.9);transition:all 0.16s cubic-bezier(0.4, 1, 0.75, 0.9);}.c1xqhu04:hover::before{box-shadow:0 0 0 2px #00000040;opacity:1;}
6
- .a1y0tcvx:hover::before,.a1y0tcvx::before{box-shadow:0 0 0 2px var(--c-p-5);opacity:1;}
1
+ @layer priority1 {
2
+ .timvir-s-1f9b50e {
3
+ --timvir-margin: var(--timvir-page-margin);
4
+ }
7
5
 
6
+ .timvir-s-1hz7z82 {
7
+ --timvir-page-margin: 16px;
8
+ }
9
+
10
+ @media (width >= 48rem) {
11
+ .timvir-s-1i3za4p.timvir-s-1i3za4p {
12
+ --timvir-page-margin: 24px;
13
+ }
14
+ }
15
+ }
16
+
17
+ @layer priority2 {
18
+ .timvir-s-1t4wa6b {
19
+ margin: 0 0 2rem;
20
+ }
21
+ }
22
+
23
+ @layer priority3 {
24
+ .timvir-s-htle6 {
25
+ grid-column: lc / rc;
26
+ }
27
+
28
+ .timvir-s-1ywaqmw {
29
+ grid-column: le / re;
30
+ }
31
+
32
+ .timvir-s-bldiei {
33
+ grid-column: lex / rex;
34
+ }
35
+
36
+ .timvir-s-1p3d3bo {
37
+ grid-gap: 16px;
38
+ }
39
+ }
40
+
41
+ @layer priority4 {
42
+ .timvir-s-7a106z {
43
+ align-items: start;
44
+ }
45
+
46
+ .timvir-s-vgvpxu {
47
+ color: var(--timvir-secondary-text-color);
48
+ }
49
+
50
+ .timvir-s-1cdhzux {
51
+ color: var(--timvir-text-color);
52
+ }
53
+
54
+ .timvir-s-1ypdohk {
55
+ cursor: pointer;
56
+ }
57
+
58
+ .timvir-s-78zum5 {
59
+ display: flex;
60
+ }
61
+
62
+ .timvir-s-rvj5dj {
63
+ display: grid;
64
+ }
65
+
66
+ .timvir-s-dt5ytf {
67
+ flex-direction: column;
68
+ }
69
+
70
+ .timvir-s-1iyjqo2 {
71
+ flex-grow: 1;
72
+ }
73
+
74
+ .timvir-s-boafo0 {
75
+ font-size: .75rem;
76
+ }
77
+
78
+ .timvir-s-u6a5m6 {
79
+ grid-auto-columns: 1fr;
80
+ }
81
+
82
+ .timvir-s-3xbxsf {
83
+ grid-auto-rows: min-content;
84
+ }
85
+
86
+ .timvir-s-12c0rpe {
87
+ grid-template-columns: [le] var(--timvir-page-margin) [lex lc] 1fr[rc rex] var(--timvir-page-margin) [re];
88
+ }
89
+
90
+ .timvir-s-o5v014 {
91
+ line-height: 1;
92
+ }
93
+
94
+ .timvir-s-1n2onr6 {
95
+ position: relative;
96
+ }
97
+
98
+ .timvir-s-2b8uid {
99
+ text-align: center;
100
+ }
101
+
102
+ .timvir-s-115iamj:hover:before {
103
+ box-shadow: 0 0 0 2px #00000040;
104
+ }
105
+
106
+ .timvir-s-ach7vw:hover:before {
107
+ box-shadow: 0 0 0 2px var(--c-p-5);
108
+ }
109
+
110
+ .timvir-s-s2hnm7:hover:before {
111
+ opacity: 1;
112
+ }
113
+
114
+ @media (width >= 72rem) {
115
+ .timvir-s-1mxrek7.timvir-s-1mxrek7 {
116
+ grid-template-columns: [le] 1fr var(--timvir-page-margin) [lex] minmax(0, 12rem) [lc] 48rem[rc] minmax(0, 12rem) [rex] var(--timvir-page-margin) 1fr[re];
117
+ }
118
+ }
119
+
120
+ @media (width >= 48rem) {
121
+ .timvir-s-9q0i6z.timvir-s-9q0i6z {
122
+ grid-template-columns: [le] var(--timvir-page-margin) [lex] 1fr[lc] minmax(0, 48rem) [rc] 1fr[rex] var(--timvir-page-margin) [re];
123
+ }
124
+ }
125
+ }
126
+
127
+ @layer priority5 {
128
+ .timvir-s-frllxf {
129
+ border-bottom-left-radius: 0;
130
+ }
131
+
132
+ .timvir-s-1v8xtx2 {
133
+ border-bottom-left-radius: 3px;
134
+ }
135
+
136
+ .timvir-s-jppbhk {
137
+ border-bottom-right-radius: 0;
138
+ }
139
+
140
+ .timvir-s-uvn51i {
141
+ border-bottom-right-radius: 3px;
142
+ }
143
+
144
+ .timvir-s-1ia1hqs {
145
+ border-top-left-radius: 0;
146
+ }
147
+
148
+ .timvir-s-1nrfd8m {
149
+ border-top-left-radius: 3px;
150
+ }
151
+
152
+ .timvir-s-1a2w583 {
153
+ border-top-right-radius: 0;
154
+ }
155
+
156
+ .timvir-s-16gx4na {
157
+ border-top-right-radius: 3px;
158
+ }
159
+
160
+ .timvir-s-1m3v4wt {
161
+ height: 200px;
162
+ }
163
+
164
+ .timvir-s-1nmq0fv {
165
+ margin-top: .8em;
166
+ }
167
+
168
+ .timvir-s-euugli {
169
+ min-width: 0;
170
+ }
171
+
172
+ .timvir-s-h8yej3 {
173
+ width: 100%;
174
+ }
175
+ }
176
+
177
+ @layer priority6 {
178
+ .timvir-s-b52w3a:before {
179
+ border-radius: 4px;
180
+ }
181
+
182
+ .timvir-s-k53niv:before {
183
+ transition: all .16s cubic-bezier(.4, 1, .75, .9);
184
+ }
185
+ }
186
+
187
+ @layer priority7 {
188
+ .timvir-s-ktd1bz:before {
189
+ box-shadow: 0 0 #137cbd00;
190
+ }
191
+
192
+ .timvir-s-su9jc6:before {
193
+ box-shadow: 0 0 0 2px var(--c-p-5);
194
+ }
195
+
196
+ .timvir-s-1cpjm7i:before {
197
+ content: "";
198
+ }
199
+
200
+ .timvir-s-fbg1o9:before {
201
+ opacity: 1;
202
+ }
203
+
204
+ .timvir-s-1hmns74:before {
205
+ position: absolute;
206
+ }
207
+ }
208
+
209
+ @layer priority8 {
210
+ .timvir-s-e80sof:before {
211
+ bottom: -2px;
212
+ }
213
+
214
+ .timvir-s-abwq6t:before {
215
+ left: -2px;
216
+ }
217
+
218
+ .timvir-s-1ydowbf:before {
219
+ right: -2px;
220
+ }
221
+
222
+ .timvir-s-51xajf:before {
223
+ top: -2px;
224
+ }
225
+ }