@codecademy/gamut-patterns 1.0.0-alpha.f6cb5a.0 → 67.0.0-alpha.7455bb.0
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/LICENSE +1 -1
- package/dist/patterns/CheckerDense.js +39 -32
- package/dist/patterns/CheckerLoose.js +39 -32
- package/dist/patterns/CheckerRegular.js +39 -32
- package/dist/patterns/DiagonalADense.js +73 -66
- package/dist/patterns/DiagonalALoose.js +217 -210
- package/dist/patterns/DiagonalARegular.js +121 -114
- package/dist/patterns/DiagonalBDense.js +55 -48
- package/dist/patterns/DiagonalBLoose.js +123 -116
- package/dist/patterns/DiagonalBRegular.js +79 -72
- package/dist/patterns/DotDense.js +34 -27
- package/dist/patterns/DotLoose.js +77 -70
- package/dist/patterns/DotRegular.js +34 -27
- package/dist/patterns/ExDense.js +56 -49
- package/dist/patterns/ExLoose.js +56 -49
- package/dist/patterns/ExRegular.js +56 -49
- package/dist/patterns/FlowerDense.js +50 -43
- package/dist/patterns/FlowerLoose.js +50 -43
- package/dist/patterns/FlowerRegular.js +50 -43
- package/dist/patterns/GridDense.js +49 -42
- package/dist/patterns/GridLoose.js +49 -42
- package/dist/patterns/GridRegular.js +49 -42
- package/dist/patterns/Herringbone.js +67 -60
- package/dist/patterns/RainDense.js +39 -32
- package/dist/patterns/RainLoose.js +39 -32
- package/dist/patterns/RainRegular.js +39 -32
- package/dist/patterns/StripeDense.js +71 -64
- package/dist/patterns/StripeLoose.js +203 -196
- package/dist/patterns/StripeRegular.js +115 -108
- package/dist/types.js +1 -0
- package/dist/usePatternId.js +4 -6
- package/package.json +16 -17
- package/.svgo.yml +0 -11
- package/CHANGELOG.md +0 -329
- package/babel.config.js +0 -5
- package/emotion-plugin.js +0 -46
- package/index-template.js +0 -10
- package/jest.config.js +0 -1
- package/pattern-template.js +0 -30
- package/svgr.config.js +0 -29
- package/tsconfig.json +0 -12
|
@@ -1,211 +1,218 @@
|
|
|
1
|
-
function
|
|
2
|
-
|
|
1
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
6
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
3
7
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
4
|
-
|
|
5
8
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
6
|
-
|
|
7
9
|
import * as React from 'react';
|
|
8
10
|
import { Svg } from '../props';
|
|
9
11
|
import { usePatternId } from '../usePatternId';
|
|
12
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
14
|
export var StripeLoose = /*#__PURE__*/React.forwardRef(function (_ref, svgRef) {
|
|
11
15
|
var _ref$title = _ref.title,
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
+
title = _ref$title === void 0 ? 'Stripe Loose' : _ref$title,
|
|
17
|
+
titleId = _ref.titleId,
|
|
18
|
+
props = _objectWithoutProperties(_ref, ["title", "titleId"]);
|
|
16
19
|
var patternId = usePatternId('StripeLoose');
|
|
17
|
-
return /*#__PURE__*/
|
|
20
|
+
return /*#__PURE__*/_jsxs(Svg, _objectSpread(_objectSpread({
|
|
18
21
|
fill: "currentColor",
|
|
19
22
|
role: "img",
|
|
20
23
|
"aria-hidden": "true",
|
|
21
24
|
ref: svgRef,
|
|
22
25
|
"aria-labelledby": titleId
|
|
23
|
-
}, props),
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
26
|
+
}, props), {}, {
|
|
27
|
+
children: [title ? /*#__PURE__*/_jsx("title", {
|
|
28
|
+
id: titleId,
|
|
29
|
+
children: title
|
|
30
|
+
}) : null, /*#__PURE__*/_jsxs("pattern", {
|
|
31
|
+
id: patternId,
|
|
32
|
+
x: 0,
|
|
33
|
+
y: 0,
|
|
34
|
+
width: 16,
|
|
35
|
+
height: 16,
|
|
36
|
+
patternUnits: "userSpaceOnUse",
|
|
37
|
+
children: [/*#__PURE__*/_jsx("rect", {
|
|
38
|
+
x: 1,
|
|
39
|
+
width: 1,
|
|
40
|
+
height: 1,
|
|
41
|
+
fill: "currentColor"
|
|
42
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
43
|
+
width: 1,
|
|
44
|
+
height: 1,
|
|
45
|
+
fill: "currentColor"
|
|
46
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
47
|
+
x: 2,
|
|
48
|
+
width: 1,
|
|
49
|
+
height: 1,
|
|
50
|
+
fill: "currentColor"
|
|
51
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
52
|
+
x: 3,
|
|
53
|
+
width: 1,
|
|
54
|
+
height: 1,
|
|
55
|
+
fill: "currentColor"
|
|
56
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
57
|
+
x: 1,
|
|
58
|
+
y: 8,
|
|
59
|
+
width: 1,
|
|
60
|
+
height: 1,
|
|
61
|
+
fill: "currentColor"
|
|
62
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
63
|
+
y: 8,
|
|
64
|
+
width: 1,
|
|
65
|
+
height: 1,
|
|
66
|
+
fill: "currentColor"
|
|
67
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
68
|
+
x: 2,
|
|
69
|
+
y: 8,
|
|
70
|
+
width: 1,
|
|
71
|
+
height: 1,
|
|
72
|
+
fill: "currentColor"
|
|
73
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
74
|
+
x: 3,
|
|
75
|
+
y: 8,
|
|
76
|
+
width: 1,
|
|
77
|
+
height: 1,
|
|
78
|
+
fill: "currentColor"
|
|
79
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
80
|
+
x: 5,
|
|
81
|
+
width: 1,
|
|
82
|
+
height: 1,
|
|
83
|
+
fill: "currentColor"
|
|
84
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
85
|
+
x: 4,
|
|
86
|
+
width: 1,
|
|
87
|
+
height: 1,
|
|
88
|
+
fill: "currentColor"
|
|
89
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
90
|
+
x: 6,
|
|
91
|
+
width: 1,
|
|
92
|
+
height: 1,
|
|
93
|
+
fill: "currentColor"
|
|
94
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
95
|
+
x: 7,
|
|
96
|
+
width: 1,
|
|
97
|
+
height: 1,
|
|
98
|
+
fill: "currentColor"
|
|
99
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
100
|
+
x: 5,
|
|
101
|
+
y: 8,
|
|
102
|
+
width: 1,
|
|
103
|
+
height: 1,
|
|
104
|
+
fill: "currentColor"
|
|
105
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
106
|
+
x: 4,
|
|
107
|
+
y: 8,
|
|
108
|
+
width: 1,
|
|
109
|
+
height: 1,
|
|
110
|
+
fill: "currentColor"
|
|
111
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
112
|
+
x: 6,
|
|
113
|
+
y: 8,
|
|
114
|
+
width: 1,
|
|
115
|
+
height: 1,
|
|
116
|
+
fill: "currentColor"
|
|
117
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
118
|
+
x: 7,
|
|
119
|
+
y: 8,
|
|
120
|
+
width: 1,
|
|
121
|
+
height: 1,
|
|
122
|
+
fill: "currentColor"
|
|
123
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
124
|
+
x: 9,
|
|
125
|
+
width: 1,
|
|
126
|
+
height: 1,
|
|
127
|
+
fill: "currentColor"
|
|
128
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
129
|
+
x: 8,
|
|
130
|
+
width: 1,
|
|
131
|
+
height: 1,
|
|
132
|
+
fill: "currentColor"
|
|
133
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
134
|
+
x: 10,
|
|
135
|
+
width: 1,
|
|
136
|
+
height: 1,
|
|
137
|
+
fill: "currentColor"
|
|
138
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
139
|
+
x: 11,
|
|
140
|
+
width: 1,
|
|
141
|
+
height: 1,
|
|
142
|
+
fill: "currentColor"
|
|
143
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
144
|
+
x: 9,
|
|
145
|
+
y: 8,
|
|
146
|
+
width: 1,
|
|
147
|
+
height: 1,
|
|
148
|
+
fill: "currentColor"
|
|
149
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
150
|
+
x: 8,
|
|
151
|
+
y: 8,
|
|
152
|
+
width: 1,
|
|
153
|
+
height: 1,
|
|
154
|
+
fill: "currentColor"
|
|
155
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
156
|
+
x: 10,
|
|
157
|
+
y: 8,
|
|
158
|
+
width: 1,
|
|
159
|
+
height: 1,
|
|
160
|
+
fill: "currentColor"
|
|
161
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
162
|
+
x: 11,
|
|
163
|
+
y: 8,
|
|
164
|
+
width: 1,
|
|
165
|
+
height: 1,
|
|
166
|
+
fill: "currentColor"
|
|
167
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
168
|
+
x: 13,
|
|
169
|
+
width: 1,
|
|
170
|
+
height: 1,
|
|
171
|
+
fill: "currentColor"
|
|
172
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
173
|
+
x: 12,
|
|
174
|
+
width: 1,
|
|
175
|
+
height: 1,
|
|
176
|
+
fill: "currentColor"
|
|
177
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
178
|
+
x: 14,
|
|
179
|
+
width: 1,
|
|
180
|
+
height: 1,
|
|
181
|
+
fill: "currentColor"
|
|
182
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
183
|
+
x: 15,
|
|
184
|
+
width: 1,
|
|
185
|
+
height: 1,
|
|
186
|
+
fill: "currentColor"
|
|
187
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
188
|
+
x: 13,
|
|
189
|
+
y: 8,
|
|
190
|
+
width: 1,
|
|
191
|
+
height: 1,
|
|
192
|
+
fill: "currentColor"
|
|
193
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
194
|
+
x: 12,
|
|
195
|
+
y: 8,
|
|
196
|
+
width: 1,
|
|
197
|
+
height: 1,
|
|
198
|
+
fill: "currentColor"
|
|
199
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
200
|
+
x: 14,
|
|
201
|
+
y: 8,
|
|
202
|
+
width: 1,
|
|
203
|
+
height: 1,
|
|
204
|
+
fill: "currentColor"
|
|
205
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
206
|
+
x: 15,
|
|
207
|
+
y: 8,
|
|
208
|
+
width: 1,
|
|
209
|
+
height: 1,
|
|
210
|
+
fill: "currentColor"
|
|
211
|
+
})]
|
|
212
|
+
}), /*#__PURE__*/_jsx("rect", {
|
|
213
|
+
width: "100%",
|
|
214
|
+
height: "100%",
|
|
215
|
+
fill: "url(#".concat(patternId, ")")
|
|
216
|
+
})]
|
|
210
217
|
}));
|
|
211
218
|
});
|