timvir 0.2.39 → 0.2.42

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 +20 -0
  2. package/blocks/Arbitrary/Arbitrary.d.ts +1 -1
  3. package/blocks/Arbitrary/index.js +193 -48
  4. package/blocks/Arbitrary/styles.css +166 -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 +205 -112
  8. package/blocks/Code/styles.css +100 -15
  9. package/blocks/ColorBar/docs/index.mdx +8 -2
  10. package/blocks/ColorBar/index.js +198 -47
  11. package/blocks/ColorBar/styles.css +103 -4
  12. package/blocks/ColorBook/docs/index.mdx +1 -1
  13. package/blocks/ColorBook/index.js +198 -39
  14. package/blocks/ColorBook/styles.css +166 -6
  15. package/blocks/Cover/index.js +165 -36
  16. package/blocks/Cover/styles.css +18 -0
  17. package/blocks/Exhibit/index.js +192 -41
  18. package/blocks/Exhibit/styles.css +66 -3
  19. package/blocks/Font/index.js +188 -58
  20. package/blocks/Font/styles.css +82 -8
  21. package/blocks/Grid/docs/index.mdx +4 -4
  22. package/blocks/Grid/index.js +176 -33
  23. package/blocks/Grid/styles.css +20 -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 +233 -54
  29. package/blocks/Message/styles.css +94 -6
  30. package/blocks/Swatch/docs/index.mdx +16 -16
  31. package/blocks/Swatch/index.js +180 -35
  32. package/blocks/Swatch/styles.css +82 -4
  33. package/blocks/Viewport/index.js +198 -91
  34. package/blocks/Viewport/styles.css +259 -14
  35. package/blocks/WebLink/index.js +192 -48
  36. package/blocks/WebLink/styles.css +170 -8
  37. package/blocks/styles.css +1460 -97
  38. package/builtins/components.d.ts +2 -2
  39. package/builtins/index.d.ts +0 -1
  40. package/builtins/index.js +300 -243
  41. package/builtins/styles.css +265 -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 +2670 -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,52 +1,177 @@
1
1
  'use client';
2
- import * as Page from 'timvir/core';
3
- import { useBlock } from 'timvir/core';
2
+ import { useBlock, layoutStyles } from 'timvir/core';
4
3
  import { codeToHtml } from 'shiki';
5
4
  import * as React from 'react';
6
- import * as Icons from 'react-feather';
7
5
  import { jsxs, jsx } from 'react/jsx-runtime';
8
6
 
9
- // src/css.ts
10
-
11
- // src/cx.ts
12
- var cx = function cx2() {
13
- const presentClassNames = Array.prototype.slice.call(arguments).filter(Boolean);
14
- const atomicClasses = {};
15
- const nonAtomicClasses = [];
16
- presentClassNames.forEach((arg) => {
17
- const individualClassNames = arg ? arg.split(" ") : [];
18
- individualClassNames.forEach((className) => {
19
- if (className.startsWith("atm_")) {
20
- const [, keyHash] = className.split("_");
21
- atomicClasses[keyHash] = className;
22
- } else {
23
- nonAtomicClasses.push(className);
24
- }
25
- });
26
- });
27
- const result = [];
28
- for (const keyHash in atomicClasses) {
29
- if (Object.prototype.hasOwnProperty.call(atomicClasses, keyHash)) {
30
- result.push(atomicClasses[keyHash]);
7
+ function cx(...args) {
8
+ let str = "";
9
+ for (let i = 0; i < args.length; i++) {
10
+ const arg = args[i];
11
+ if (typeof arg === "string") {
12
+ str += (str && " ") + arg;
31
13
  }
32
14
  }
33
- result.push(...nonAtomicClasses);
34
- return result.join(" ");
35
- };
36
- var cx_default = cx;
15
+ return str;
16
+ }
37
17
 
38
- var theme = "tac6gx6";
18
+ var styleq = {};
19
+ var hasRequiredStyleq;
20
+ function requireStyleq() {
21
+ if (hasRequiredStyleq) return styleq;
22
+ hasRequiredStyleq = 1;
23
+ Object.defineProperty(styleq, "__esModule", {
24
+ value: true
25
+ });
26
+ styleq.styleq = void 0;
27
+ var cache = new WeakMap();
28
+ var compiledKey = '$$css';
29
+ function createStyleq(options) {
30
+ var disableCache;
31
+ var disableMix;
32
+ var transform;
33
+ if (options != null) {
34
+ disableCache = options.disableCache === true;
35
+ disableMix = options.disableMix === true;
36
+ transform = options.transform;
37
+ }
38
+ return function styleq() {
39
+ var definedProperties = [];
40
+ var className = '';
41
+ var inlineStyle = null;
42
+ var debugString = '';
43
+ var nextCache = disableCache ? null : cache;
44
+ var styles = new Array(arguments.length);
45
+ for(var i = 0; i < arguments.length; i++){
46
+ styles[i] = arguments[i];
47
+ }
48
+ while(styles.length > 0){
49
+ var possibleStyle = styles.pop();
50
+ if (possibleStyle == null || possibleStyle === false) {
51
+ continue;
52
+ }
53
+ if (Array.isArray(possibleStyle)) {
54
+ for(var _i = 0; _i < possibleStyle.length; _i++){
55
+ styles.push(possibleStyle[_i]);
56
+ }
57
+ continue;
58
+ }
59
+ var style = transform != null ? transform(possibleStyle) : possibleStyle;
60
+ if (style.$$css != null) {
61
+ var classNameChunk = '';
62
+ if (nextCache != null && nextCache.has(style)) {
63
+ var cacheEntry = nextCache.get(style);
64
+ if (cacheEntry != null) {
65
+ classNameChunk = cacheEntry[0];
66
+ debugString = cacheEntry[2];
67
+ definedProperties.push.apply(definedProperties, cacheEntry[1]);
68
+ nextCache = cacheEntry[3];
69
+ }
70
+ } else {
71
+ var definedPropertiesChunk = [];
72
+ for(var prop in style){
73
+ var value = style[prop];
74
+ if (prop === compiledKey) {
75
+ var compiledKeyValue = style[prop];
76
+ if (compiledKeyValue !== true) {
77
+ debugString = debugString ? compiledKeyValue + '; ' + debugString : compiledKeyValue;
78
+ }
79
+ continue;
80
+ }
81
+ if (typeof value === 'string' || value === null) {
82
+ if (!definedProperties.includes(prop)) {
83
+ definedProperties.push(prop);
84
+ if (nextCache != null) {
85
+ definedPropertiesChunk.push(prop);
86
+ }
87
+ if (typeof value === 'string') {
88
+ classNameChunk += classNameChunk ? ' ' + value : value;
89
+ }
90
+ }
91
+ } else {
92
+ console.error("styleq: ".concat(prop, " typeof ").concat(String(value), " is not \"string\" or \"null\"."));
93
+ }
94
+ }
95
+ if (nextCache != null) {
96
+ var weakMap = new WeakMap();
97
+ nextCache.set(style, [
98
+ classNameChunk,
99
+ definedPropertiesChunk,
100
+ debugString,
101
+ weakMap
102
+ ]);
103
+ nextCache = weakMap;
104
+ }
105
+ }
106
+ if (classNameChunk) {
107
+ className = className ? classNameChunk + ' ' + className : classNameChunk;
108
+ }
109
+ } else {
110
+ if (disableMix) {
111
+ if (inlineStyle == null) {
112
+ inlineStyle = {};
113
+ }
114
+ inlineStyle = Object.assign({}, style, inlineStyle);
115
+ } else {
116
+ var subStyle = null;
117
+ for(var _prop in style){
118
+ var _value = style[_prop];
119
+ if (_value !== undefined) {
120
+ if (!definedProperties.includes(_prop)) {
121
+ if (_value != null) {
122
+ if (inlineStyle == null) {
123
+ inlineStyle = {};
124
+ }
125
+ if (subStyle == null) {
126
+ subStyle = {};
127
+ }
128
+ subStyle[_prop] = _value;
129
+ }
130
+ definedProperties.push(_prop);
131
+ nextCache = null;
132
+ }
133
+ }
134
+ }
135
+ if (subStyle != null) {
136
+ inlineStyle = Object.assign(subStyle, inlineStyle);
137
+ }
138
+ }
139
+ }
140
+ }
141
+ var styleProps = [
142
+ className,
143
+ inlineStyle,
144
+ debugString
145
+ ];
146
+ return styleProps;
147
+ };
148
+ }
149
+ var styleq$1 = styleq.styleq = createStyleq();
150
+ styleq$1.factory = createStyleq;
151
+ return styleq;
152
+ }
153
+ var styleqExports = requireStyleq();
154
+ function props(...styles) {
155
+ const [className, style, dataStyleSrc] = styleqExports.styleq(styles);
156
+ const result = {};
157
+ if (className != null && className !== '') {
158
+ result.className = className;
159
+ }
160
+ if (style != null && Object.keys(style).length > 0) {
161
+ result.style = style;
162
+ }
163
+ if (dataStyleSrc != null && dataStyleSrc !== '') {
164
+ result['data-style-src'] = dataStyleSrc;
165
+ }
166
+ return result;
167
+ }
39
168
 
40
- /**
41
- * The underlying DOM element which is rendered by this component.
42
- */
43
169
  const Root = "div";
44
- function Code(props, ref) {
45
- const block = useBlock(props);
170
+ function Code(props$1, ref) {
171
+ const block = useBlock(props$1);
46
172
  const {
47
173
  children,
48
174
  language,
49
- fullWidth,
50
175
  highlightedLines,
51
176
  caption,
52
177
  className,
@@ -54,36 +179,39 @@ function Code(props, ref) {
54
179
  } = block.props;
55
180
  const [state, setState] = React.useState({
56
181
  settled: false,
57
- mouseOver: false,
58
- copiedToClipboard: false,
59
- /*
60
- * Prevent layout shift during (asynchronous) highlighting of the markup by
61
- * initializing the html witha pre/code block with the expected number of
62
- * lines.
63
- */
64
- html: `<pre><code>${children.trim().split("\n").map(() => "\n").join("")}</code></pre>`
182
+ html: `<pre class="${{
183
+ className: "timvir-s-1lliihq timvir-s-1ghz6dp timvir-s-1g8o3q3 timvir-s-1d0dlzq"
184
+ }.className}"><code>${children.trim().split("\n").map(() => "\n").join("")}</code></pre>`
65
185
  });
66
186
  React.useEffect(() => {
67
187
  (async () => {
188
+ const stylexTransformer = {
189
+ name: "stylex",
190
+ pre(node) {
191
+ this.addClassToHast(node, {
192
+ className: "timvir-s-1lliihq timvir-s-1ghz6dp timvir-s-1g8o3q3 timvir-s-1d0dlzq"
193
+ }.className);
194
+ },
195
+ line(node, index) {
196
+ this.addClassToHast(node, {
197
+ className: "timvir-s-1rg5ohu timvir-s-h8yej3 timvir-s-e193im"
198
+ }.className);
199
+ if (highlightedLines?.includes(index)) {
200
+ this.addClassToHast(node, {
201
+ className: "timvir-s-15fpjw5"
202
+ }.className);
203
+ }
204
+ }
205
+ };
68
206
  const html = await codeToHtml(children.trim(), {
69
207
  lang: language ?? "text",
70
208
  themes: {
71
209
  light: "github-light",
72
210
  dark: "github-dark"
73
211
  },
74
- decorations: (highlightedLines ?? []).map(line => ({
75
- start: {
76
- line: line - 1,
77
- character: 0
78
- },
79
- end: {
80
- line: line,
81
- character: 0
82
- },
83
- properties: {
84
- class: classes.highlightedLine
85
- }
86
- }))
212
+ defaultColor: false,
213
+ cssVariablePrefix: "--timvir-b-Code-shiki-",
214
+ transformers: [stylexTransformer]
87
215
  });
88
216
  setState(state => ({
89
217
  ...state,
@@ -92,70 +220,35 @@ function Code(props, ref) {
92
220
  }));
93
221
  })();
94
222
  }, [children, language, highlightedLines]);
223
+ const rootStyleProps = props(layoutStyles.block);
224
+ const codeStyleProps = {
225
+ className: "timvir-s-w2csxc timvir-s-6wvzqs timvir-s-sfzzmd timvir-s-1sxf85j timvir-s-15o1dgp timvir-s-idmeni timvir-s-1717udv timvir-s-1etwjqo timvir-s-mkeg23 timvir-s-1y0btm7 timvir-s-j7gikm timvir-s-1d0dlzq"
226
+ };
227
+ const captionStyleProps = {
228
+ className: "timvir-s-1dcheo9 timvir-s-jkpybl timvir-s-vgvpxu timvir-s-lwy1ot"
229
+ };
95
230
  return /*#__PURE__*/jsxs(Root, {
96
231
  ref: ref,
97
- className: cx_default("timvir-b-Code", !state.settled && "timvir-unsettled", classes.root, fullWidth && Page.fullWidth),
98
232
  ...rest,
233
+ ...rootStyleProps,
234
+ className: cx("timvir-b-Code", !state.settled && "timvir-unsettled", className, rootStyleProps.className),
235
+ style: {
236
+ ...rootStyleProps.style,
237
+ ...rest.style
238
+ },
99
239
  children: [/*#__PURE__*/jsx("div", {
100
- className: cx_default("timvir-b-Code-container", className, theme, classes.code, fullWidth && classes.fullWidth),
101
- children: /*#__PURE__*/jsxs("div", {
102
- className: "d1513p2s",
103
- onMouseEnter: () => {
104
- setState(state => ({
105
- ...state,
106
- mouseOver: true
107
- }));
108
- },
109
- onMouseLeave: () => {
110
- setState(state => ({
111
- ...state,
112
- mouseOver: false,
113
- copiedToClipboard: false
114
- }));
115
- },
116
- children: [/*#__PURE__*/jsxs("button", {
117
- type: "button",
118
- onClick: () => {
119
- navigator.clipboard.writeText(children);
120
- setState(state => ({
121
- ...state,
122
- copiedToClipboard: true
123
- }));
124
- },
125
- className: cx_default("b157mkz", state.mouseOver && "b10oxtfo"),
126
- children: [/*#__PURE__*/jsx("svg", {
127
- width: 48,
128
- height: 48,
129
- viewBox: "0 0 48 48",
130
- className: "s1hdfi6o",
131
- children: /*#__PURE__*/jsx("path", {
132
- d: "M0 0 H48 V48 Z"
133
- })
134
- }), state.copiedToClipboard ? /*#__PURE__*/jsx(Icons.Clipboard, {
135
- size: "16px"
136
- }) : /*#__PURE__*/jsx(Icons.Copy, {
137
- size: "16px"
138
- })]
139
- }), /*#__PURE__*/jsx("div", {
140
- className: cx_default(fullWidth ? "d17pltln" : "d793q8f"),
141
- dangerouslySetInnerHTML: {
142
- __html: state.html
143
- }
144
- })]
145
- })
240
+ ...codeStyleProps,
241
+ className: cx("timvir-b-Code-container", codeStyleProps.className),
242
+ dangerouslySetInnerHTML: {
243
+ __html: state.html
244
+ }
146
245
  }), caption && /*#__PURE__*/jsx("div", {
147
- className: cx_default("timvir-b-Code-caption", classes.caption),
246
+ ...captionStyleProps,
247
+ className: cx("timvir-b-Code-caption", captionStyleProps.className),
148
248
  children: caption
149
249
  })]
150
250
  });
151
251
  }
152
252
  var Code$1 = /*#__PURE__*/React.forwardRef(Code);
153
- const classes = {
154
- root: "r9v2r0l",
155
- code: "cs7tint",
156
- fullWidth: "fjvaz2s",
157
- highlightedLine: "h1xcko1i",
158
- caption: "c5vr6r2"
159
- };
160
253
 
161
254
  export { Code$1 as Code };
@@ -1,16 +1,101 @@
1
- .tac6gx6{color:#393a34;background-color:#f6f8fa;}.tac6gx6 :is(.comment, .prolog, .doctype, .cdata){color:#999988;font-style:italic;}.tac6gx6 :is(.namespace){opacity:0.7;}.tac6gx6 :is(.string, .attr-value){color:#e3116c;}.tac6gx6 :is(.punctuation, .operator){color:#6cb6ff;}.tac6gx6 :is(.function, .delete, .tag){color:#d73a49;}.tac6gx6 :is(.tag, .selector, .keyword){color:#00009f;}.tac6gx6 :is(.function-variable){color:#6f42c1;}.tac6gx6 :is(.atrule, .keyword, .attr-name, .selector){color:#00a4db;}.tac6gx6 :is(.entity, .url, .symbol, .number, .boolean, .variable, .constant, .property, .regex, .inserted){color:#36acaa;}:root[data-timvir-theme="dark"] .tac6gx6{color:#adbac7;background-color:var(--timvir-secondary-background-color);}:root[data-timvir-theme="dark"] .tac6gx6 :is(.comment, .prolog, .doctype, .cdata){color:#999988;font-style:italic;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.namespace){opacity:0.7;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.string, .attr-value){color:#96d0ff;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.punctuation, .operator){color:#6cb6ff;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.function, .delete, .tag){color:#d73a49;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.tag, .selector, .keyword){color:#8ddb8c;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.function-variable){color:#6f42c1;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.atrule, .keyword, .attr-name, .selector){color:#f47067;}:root[data-timvir-theme="dark"] .tac6gx6 :is(.entity, .url, .symbol, .number, .boolean, .variable, .constant, .property, .regex, .inserted){color:#dcbdfb;}
2
-
3
- .d1513p2s{display:-ms-grid;display:grid;-ms-grid-columns:1fr;grid-template-columns:1fr;}
4
- .b157mkz{--size:48px;z-index:1;position:absolute;top:0;right:0;overflow:hidden;width:var(--size);height:var(--size);display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;-webkit-box-pack:end;-ms-flex-pack:end;-webkit-justify-content:flex-end;justify-content:flex-end;outline:none;border:none;padding:6px;background:transparent;-webkit-transition:all 0.2s;transition:all 0.2s;cursor:pointer;pointer-events:none;opacity:0;}.b157mkz:hover{color:white;}.b157mkz:hover svg:first-child{-webkit-transform:translate(0, 0);-moz-transform:translate(0, 0);-ms-transform:translate(0, 0);transform:translate(0, 0);}.b157mkz:active svg:first-child{-webkit-transform:translate(2px, -2px);-moz-transform:translate(2px, -2px);-ms-transform:translate(2px, -2px);transform:translate(2px, -2px);}
5
- .b10oxtfo{pointer-events:all;opacity:1;}
6
- .s1hdfi6o{position:absolute;z-index:-1;top:0;right:0;-webkit-transition:all 0.2s;transition:all 0.2s;-webkit-transform:translate(48px, -48px);-moz-transform:translate(48px, -48px);-ms-transform:translate(48px, -48px);transform:translate(48px, -48px);}.s1hdfi6o path{fill:var(--c-p-4);}
7
- .d17pltln{padding:16px 24px 16px 0;}
8
-
9
- :root[data-timvir-theme="dark"] .r9v2r0l .shiki,:root[data-timvir-theme="dark"] .r9v2r0l .shiki span{color:var(--shiki-dark)!important;font-style:var(--shiki-dark-font-style)!important;font-weight:var(--shiki-dark-font-weight)!important;-webkit-text-decoration:var(--shiki-dark-text-decoration)!important;text-decoration:var(--shiki-dark-text-decoration)!important;}
10
- .cs7tint{overflow-x:auto;contain:content;font-size:0.8em;border-radius:5px;--timvir-b-Code-bleed:calc(var(--timvir-margin, 0px) * 0.6666);--timvir-b-Code-inlinePadding:max(var(--timvir-b-Code-bleed), 8px);padding:0;margin:0 calc(-1 * var(--timvir-b-Code-bleed));border:1px solid var(--timvir-border-color);}.cs7tint pre{margin:0;padding:16px 0;background-color:var(--timvir-secondary-background-color)!important;}.cs7tint pre code{display:block;}.cs7tint pre code .line{display:inline-block;position:relative;width:100%;}.cs7tint pre .line{padding-inline:var(--timvir-b-Code-inlinePadding);}
11
- .fjvaz2s{display:-ms-grid;display:grid;border-radius:0;box-shadow:none;margin-inline:0;-ms-grid-auto-rows:min-content;grid-auto-rows:min-content;-ms-grid-columns:[le] 0 [lc] 1fr [rc] 0 [re];grid-template-columns:[le] 0 [lc] 1fr [rc] 0 [re];-ms-grid-column-gap:16px;grid-column-gap:16px;}.fjvaz2s:hover{box-shadow:none;}@media (min-width: 60rem){.fjvaz2s{-ms-grid-columns:[le] 1fr [lc] minmax(0, 48rem) [rc] 1fr [re];grid-template-columns:[le] 1fr [lc] minmax(0, 48rem) [rc] 1fr [re];-ms-grid-column-gap:24px;grid-column-gap:24px;}}.fjvaz2s>*{grid-column:lc/re;}
12
- .lchll0h{padding-inline:var(--timvir-b-Code-inlinePadding);}
13
- .h1xcko1i{background-color:#ffe10044;}:root[data-timvir-theme="dark"] .h1xcko1i{background-color:rgba(174, 124, 20, 0.15);}
14
- .ll2b9hx{display:inline-block;width:var(--timvir-b-Code-bleed);color:var(--timvir-secondary-text-color);text-align:right;padding-inline:4px;}
15
- .c5vr6r2{font-size:0.8125rem;line-height:1.1875;color:var(--timvir-secondary-text-color);margin-top:0.3em;}
1
+ @layer priority1 {
2
+ .timvir-s-15o1dgp {
3
+ --timvir-b-Code-bleed: calc(var(--timvir-margin, 0) * .6666);
4
+ }
16
5
 
6
+ .timvir-s-idmeni {
7
+ --timvir-b-Code-inlinePadding: max(var(--timvir-b-Code-bleed), 8px);
8
+ }
9
+ }
10
+
11
+ @layer priority2 {
12
+ .timvir-s-1etwjqo {
13
+ margin: 0 calc(-1 * var(--timvir-b-Code-bleed));
14
+ }
15
+
16
+ .timvir-s-1ghz6dp {
17
+ margin: 0;
18
+ }
19
+
20
+ .timvir-s-1717udv {
21
+ padding: 0;
22
+ }
23
+
24
+ .timvir-s-1g8o3q3 {
25
+ padding: 16px 0;
26
+ }
27
+ }
28
+
29
+ @layer priority3 {
30
+ .timvir-s-j7gikm {
31
+ border-color: var(--timvir-border-color);
32
+ }
33
+
34
+ .timvir-s-1sxf85j {
35
+ border-radius: 5px;
36
+ }
37
+
38
+ .timvir-s-1y0btm7 {
39
+ border-style: solid;
40
+ }
41
+
42
+ .timvir-s-mkeg23 {
43
+ border-width: 1px;
44
+ }
45
+
46
+ .timvir-s-e193im {
47
+ padding-inline: var(--timvir-b-Code-inlinePadding);
48
+ }
49
+ }
50
+
51
+ @layer priority4 {
52
+ .timvir-s-15fpjw5 {
53
+ background-color: var(--timvir-highlight-background-color);
54
+ }
55
+
56
+ .timvir-s-1d0dlzq {
57
+ background-color: var(--timvir-secondary-background-color);
58
+ }
59
+
60
+ .timvir-s-vgvpxu {
61
+ color: var(--timvir-secondary-text-color);
62
+ }
63
+
64
+ .timvir-s-6wvzqs {
65
+ contain: content;
66
+ }
67
+
68
+ .timvir-s-1lliihq {
69
+ display: block;
70
+ }
71
+
72
+ .timvir-s-1rg5ohu {
73
+ display: inline-block;
74
+ }
75
+
76
+ .timvir-s-1dcheo9 {
77
+ font-size: .8125rem;
78
+ }
79
+
80
+ .timvir-s-sfzzmd {
81
+ font-size: .8em;
82
+ }
83
+
84
+ .timvir-s-jkpybl {
85
+ line-height: 1.1875;
86
+ }
87
+ }
88
+
89
+ @layer priority5 {
90
+ .timvir-s-lwy1ot {
91
+ margin-top: .3em;
92
+ }
93
+
94
+ .timvir-s-w2csxc {
95
+ overflow-x: auto;
96
+ }
97
+
98
+ .timvir-s-h8yej3 {
99
+ width: 100%;
100
+ }
101
+ }
@@ -19,14 +19,15 @@ A `ColorBar` is a horizontal arrangement of swatches.
19
19
  "#6550B0",
20
20
  "#5642A6",
21
21
  ]}
22
+ style={{ margin: 0 }}
22
23
  />
23
24
  </Exhibit>
24
25
 
25
26
  <Exhibit>
26
- <ColorBar values={["#a0dbc2", "#60c19f", "#1a896b", "#0e6d54"]} />
27
+ <ColorBar values={["#a0dbc2", "#60c19f", "#1a896b", "#0e6d54"]} style={{ margin: 0 }} />
27
28
  </Exhibit>
28
29
 
29
- <Code language="jsx" caption="Pass an array of color values to the component." highlightedLines={[5]}>
30
+ <Code language="jsx" caption="Pass an array of color values to the component." highlightedLines={[4]}>
30
31
  <Sample variant="basic" as="source" />
31
32
  </Code>
32
33
 
@@ -38,6 +39,7 @@ The ColorBar works comfortably with as few as two colors and as many as 20
38
39
  { value: "#FFE4A0", name: "Yellow Submarine", ancestry: "Yellow 001" },
39
40
  { value: "#A67908", name: "Yellow Spaceship", ancestry: "Yellow 999", contrastValue: "white" },
40
41
  ]}
42
+ style={{ margin: 0 }}
41
43
  />
42
44
  </Exhibit>
43
45
 
@@ -65,6 +67,7 @@ The ColorBar works comfortably with as few as two colors and as many as 20
65
67
  "#AB7E15",
66
68
  "#A67908",
67
69
  ]}
70
+ style={{ margin: 0 }}
68
71
  />
69
72
  </Exhibit>
70
73
 
@@ -83,6 +86,7 @@ All text colors are taken from the **Gray** palette.
83
86
  { value: "rgba(0, 0, 13, 0.69)", name: "???? (unnamed)", ancestry: "Gray 03", contrastValue: "white" },
84
87
  { value: "rgba(0, 0, 13, 0.49)", name: "textSecondary", ancestry: "Gray 05" },
85
88
  ]}
89
+ style={{ margin: 0 }}
86
90
  />
87
91
  </Exhibit>
88
92
  <Exhibit caption="Gray Color Palette (00 – 09)" style={{ margin: "-12px 0 20px 0" }}>
@@ -99,6 +103,7 @@ All text colors are taken from the **Gray** palette.
99
103
  { value: "rgba(0, 0, 13, 0.19)", name: "Gray 08", contrastValue: "black" },
100
104
  { value: "rgba(0, 0, 13, 0.09)", name: "Gray 09", contrastValue: "black" },
101
105
  ]}
106
+ style={{ margin: 0 }}
102
107
  />
103
108
  </Exhibit>
104
109
 
@@ -124,5 +129,6 @@ Wrap a `<ColorBar>` in a `<Exhibit>` to add a caption to it. The caption can eve
124
129
  "#0D6CA1",
125
130
  "#09486C",
126
131
  ]}
132
+ style={{ margin: 0 }}
127
133
  />
128
134
  </Exhibit>