@primer/components 0.0.0-20219293614 → 0.0.0-2021931194230
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/CHANGELOG.md +1 -7
- package/dist/browser.esm.js +439 -436
- package/dist/browser.esm.js.map +1 -1
- package/dist/browser.umd.js +443 -440
- package/dist/browser.umd.js.map +1 -1
- package/lib/ActionList/Item.d.ts +0 -6
- package/lib/ActionList/Item.js +1 -5
- package/lib/ActionMenu.js +2 -2
- package/lib/AnchoredOverlay/AnchoredOverlay.d.ts +4 -2
- package/lib/Autocomplete/Autocomplete.d.ts +13 -11
- package/lib/Autocomplete/AutocompleteInput.d.ts +13 -11
- package/lib/Button/Button.d.ts +11 -11
- package/lib/Button/ButtonBase.d.ts +1 -1
- package/lib/Button/ButtonClose.d.ts +29 -29
- package/lib/Button/ButtonDanger.d.ts +11 -11
- package/lib/Button/ButtonInvisible.d.ts +11 -11
- package/lib/Button/ButtonOutline.d.ts +11 -11
- package/lib/Button/ButtonPrimary.d.ts +11 -11
- package/lib/Button/ButtonStyles.js +1 -1
- package/lib/CircleBadge.d.ts +2 -2
- package/lib/CircleOcticon.d.ts +33 -33
- package/lib/DatePicker/DatePicker.d.ts +48 -0
- package/lib/DatePicker/DatePicker.js +106 -0
- package/lib/DatePicker/DatePickerAnchor.d.ts +5 -0
- package/lib/DatePicker/DatePickerAnchor.js +223 -0
- package/lib/DatePicker/DatePickerOverlay.d.ts +3 -0
- package/lib/DatePicker/DatePickerOverlay.js +48 -0
- package/lib/DatePicker/DatePickerPanel.d.ts +2 -0
- package/lib/DatePicker/DatePickerPanel.js +143 -0
- package/lib/DatePicker/Day.d.ts +14 -0
- package/lib/DatePicker/Day.js +192 -0
- package/lib/DatePicker/Month.d.ts +9 -0
- package/lib/DatePicker/Month.js +122 -0
- package/lib/DatePicker/dateParser.d.ts +11 -0
- package/lib/DatePicker/dateParser.js +192 -0
- package/lib/DatePicker/index.d.ts +2 -0
- package/lib/DatePicker/index.js +13 -0
- package/lib/DatePicker/useDatePicker.d.ts +89 -0
- package/lib/DatePicker/useDatePicker.js +439 -0
- package/lib/Dialog/Dialog.d.ts +4 -4
- package/lib/Dialog/Dialog.js +22 -12
- package/lib/Dialog.d.ts +35 -35
- package/lib/Dropdown.d.ts +165 -85
- package/lib/Dropdown.js +5 -6
- package/lib/DropdownMenu/DropdownButton.d.ts +30 -30
- package/lib/FilterList.d.ts +26 -26
- package/lib/Label.d.ts +1 -1
- package/lib/Position.d.ts +4 -4
- package/lib/ProgressBar.d.ts +1 -1
- package/lib/SelectMenu/SelectMenu.d.ts +153 -151
- package/lib/SelectMenu/SelectMenuItem.d.ts +1 -1
- package/lib/SelectMenu/SelectMenuModal.d.ts +1 -1
- package/lib/TextInputWithTokens.d.ts +13 -11
- package/lib/Timeline.d.ts +33 -33
- package/lib/Token/AvatarToken.d.ts +1 -1
- package/lib/Token/IssueLabelToken.d.ts +1 -1
- package/lib/Token/Token.d.ts +1 -1
- package/lib/_TextInputWrapper.d.ts +1 -1
- package/lib/constants.js +1 -3
- package/lib/hooks/useDebounce.d.ts +2 -0
- package/lib/hooks/useDebounce.js +24 -0
- package/lib/hooks/useResizeObserver.d.ts +1 -1
- package/lib/hooks/useResizeObserver.js +1 -1
- package/lib/index.d.ts +0 -2
- package/lib/index.js +0 -8
- package/lib/theme-preval.js +2 -2
- package/lib/utils/testing.d.ts +1 -1
- package/lib-esm/ActionList/Item.d.ts +0 -6
- package/lib-esm/ActionList/Item.js +1 -5
- package/lib-esm/ActionMenu.js +2 -2
- package/lib-esm/AnchoredOverlay/AnchoredOverlay.d.ts +4 -2
- package/lib-esm/Autocomplete/Autocomplete.d.ts +13 -11
- package/lib-esm/Autocomplete/AutocompleteInput.d.ts +13 -11
- package/lib-esm/Button/Button.d.ts +11 -11
- package/lib-esm/Button/ButtonBase.d.ts +1 -1
- package/lib-esm/Button/ButtonClose.d.ts +29 -29
- package/lib-esm/Button/ButtonDanger.d.ts +11 -11
- package/lib-esm/Button/ButtonInvisible.d.ts +11 -11
- package/lib-esm/Button/ButtonOutline.d.ts +11 -11
- package/lib-esm/Button/ButtonPrimary.d.ts +11 -11
- package/lib-esm/Button/ButtonStyles.js +1 -1
- package/lib-esm/CircleBadge.d.ts +2 -2
- package/lib-esm/CircleOcticon.d.ts +33 -33
- package/lib-esm/DatePicker/DatePicker.d.ts +48 -0
- package/lib-esm/DatePicker/DatePicker.js +89 -0
- package/lib-esm/DatePicker/DatePickerAnchor.d.ts +5 -0
- package/lib-esm/DatePicker/DatePickerAnchor.js +196 -0
- package/lib-esm/DatePicker/DatePickerOverlay.d.ts +3 -0
- package/lib-esm/DatePicker/DatePickerOverlay.js +29 -0
- package/lib-esm/DatePicker/DatePickerPanel.d.ts +2 -0
- package/lib-esm/DatePicker/DatePickerPanel.js +116 -0
- package/lib-esm/DatePicker/Day.d.ts +14 -0
- package/lib-esm/DatePicker/Day.js +169 -0
- package/lib-esm/DatePicker/Month.d.ts +9 -0
- package/lib-esm/DatePicker/Month.js +98 -0
- package/lib-esm/DatePicker/dateParser.d.ts +11 -0
- package/lib-esm/DatePicker/dateParser.js +178 -0
- package/lib-esm/DatePicker/index.d.ts +2 -0
- package/lib-esm/DatePicker/index.js +1 -0
- package/lib-esm/DatePicker/useDatePicker.d.ts +89 -0
- package/lib-esm/DatePicker/useDatePicker.js +408 -0
- package/lib-esm/Dialog/Dialog.d.ts +4 -4
- package/lib-esm/Dialog/Dialog.js +21 -12
- package/lib-esm/Dialog.d.ts +35 -35
- package/lib-esm/Dropdown.d.ts +165 -85
- package/lib-esm/Dropdown.js +3 -4
- package/lib-esm/DropdownMenu/DropdownButton.d.ts +30 -30
- package/lib-esm/FilterList.d.ts +26 -26
- package/lib-esm/Label.d.ts +1 -1
- package/lib-esm/Position.d.ts +4 -4
- package/lib-esm/ProgressBar.d.ts +1 -1
- package/lib-esm/SelectMenu/SelectMenu.d.ts +153 -151
- package/lib-esm/SelectMenu/SelectMenuItem.d.ts +1 -1
- package/lib-esm/SelectMenu/SelectMenuModal.d.ts +1 -1
- package/lib-esm/TextInputWithTokens.d.ts +13 -11
- package/lib-esm/Timeline.d.ts +33 -33
- package/lib-esm/Token/AvatarToken.d.ts +1 -1
- package/lib-esm/Token/IssueLabelToken.d.ts +1 -1
- package/lib-esm/Token/Token.d.ts +1 -1
- package/lib-esm/_TextInputWrapper.d.ts +1 -1
- package/lib-esm/constants.js +1 -3
- package/lib-esm/hooks/useDebounce.d.ts +2 -0
- package/lib-esm/hooks/useDebounce.js +16 -0
- package/lib-esm/hooks/useResizeObserver.d.ts +1 -1
- package/lib-esm/hooks/useResizeObserver.js +1 -1
- package/lib-esm/index.d.ts +0 -2
- package/lib-esm/index.js +0 -1
- package/lib-esm/theme-preval.js +2 -2
- package/lib-esm/utils/testing.d.ts +1 -1
- package/package.json +14 -13
- package/lib/NewButton/button.d.ts +0 -579
- package/lib/NewButton/button.js +0 -298
- package/lib/NewButton/counter.d.ts +0 -6
- package/lib/NewButton/counter.js +0 -33
- package/lib/NewButton/index.d.ts +0 -4
- package/lib/NewButton/index.js +0 -21
- package/lib-esm/NewButton/button.d.ts +0 -579
- package/lib-esm/NewButton/button.js +0 -274
- package/lib-esm/NewButton/counter.d.ts +0 -6
- package/lib-esm/NewButton/counter.js +0 -21
- package/lib-esm/NewButton/index.d.ts +0 -4
- package/lib-esm/NewButton/index.js +0 -3
package/lib/NewButton/button.js
DELETED
@@ -1,298 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
4
|
-
value: true
|
5
|
-
});
|
6
|
-
exports.default = void 0;
|
7
|
-
|
8
|
-
var _react = _interopRequireWildcard(require("react"));
|
9
|
-
|
10
|
-
var _octiconsReact = require("@primer/octicons-react");
|
11
|
-
|
12
|
-
var _Box = _interopRequireDefault(require("../Box"));
|
13
|
-
|
14
|
-
var _styledSystem = require("styled-system");
|
15
|
-
|
16
|
-
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
17
|
-
|
18
|
-
var _sx = _interopRequireDefault(require("../sx"));
|
19
|
-
|
20
|
-
var _constants = require("../constants");
|
21
|
-
|
22
|
-
var _ButtonStyles = _interopRequireDefault(require("../Button/ButtonStyles"));
|
23
|
-
|
24
|
-
var _counter = _interopRequireDefault(require("./counter"));
|
25
|
-
|
26
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
27
|
-
|
28
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
29
|
-
|
30
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
31
|
-
|
32
|
-
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
33
|
-
|
34
|
-
const sizes = (0, _styledSystem.variant)({
|
35
|
-
prop: 'size',
|
36
|
-
variants: {
|
37
|
-
small: {
|
38
|
-
p: '4px 12px',
|
39
|
-
fontSize: 0
|
40
|
-
},
|
41
|
-
medium: {
|
42
|
-
fontSize: 1
|
43
|
-
},
|
44
|
-
large: {
|
45
|
-
fontSize: 2,
|
46
|
-
p: '10px 20px'
|
47
|
-
}
|
48
|
-
}
|
49
|
-
});
|
50
|
-
|
51
|
-
const getVariantStyles = (theme, variant = 'default') => {
|
52
|
-
const style = {
|
53
|
-
default: `
|
54
|
-
padding: 5px 16px;
|
55
|
-
color: ${(0, _constants.get)('colors.btn.text')({
|
56
|
-
theme
|
57
|
-
})};
|
58
|
-
background-color: ${(0, _constants.get)('colors.btn.bg')({
|
59
|
-
theme
|
60
|
-
})};
|
61
|
-
border-width: 1px;
|
62
|
-
border-style: solid;
|
63
|
-
border-color: ${(0, _constants.get)('colors.btn.border')({
|
64
|
-
theme
|
65
|
-
})};
|
66
|
-
box-shadow: ${((0, _constants.get)('shadows.btn.shadow')({
|
67
|
-
theme
|
68
|
-
}), (0, _constants.get)('shadows.btn.insetShadow')({
|
69
|
-
theme
|
70
|
-
}))};
|
71
|
-
&:hover {
|
72
|
-
background-color: ${(0, _constants.get)('colors.btn.hoverBg')({
|
73
|
-
theme
|
74
|
-
})};
|
75
|
-
}
|
76
|
-
// focus must come before :active so that the active box shadow overrides
|
77
|
-
&:focus {
|
78
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.focusShadow')({
|
79
|
-
theme
|
80
|
-
})};
|
81
|
-
}
|
82
|
-
&:active {
|
83
|
-
background-color: ${(0, _constants.get)('colors.btn.selectedBg')({
|
84
|
-
theme
|
85
|
-
})};
|
86
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.shadowActive')({
|
87
|
-
theme
|
88
|
-
})};
|
89
|
-
}
|
90
|
-
&:disabled {
|
91
|
-
color: ${(0, _constants.get)('colors.primer.fg.disabled')({
|
92
|
-
theme
|
93
|
-
})};
|
94
|
-
}
|
95
|
-
`,
|
96
|
-
primary: `
|
97
|
-
padding: 5px 16px;
|
98
|
-
color: ${(0, _constants.get)('colors.btn.primary.text')({
|
99
|
-
theme
|
100
|
-
})};
|
101
|
-
background-color: ${(0, _constants.get)('colors.btn.primary.bg')({
|
102
|
-
theme
|
103
|
-
})};
|
104
|
-
border-width: 1px;
|
105
|
-
border-style: solid;
|
106
|
-
border-color: ${(0, _constants.get)('colors.border.subtle')({
|
107
|
-
theme
|
108
|
-
})};
|
109
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.primary.shadow')({
|
110
|
-
theme
|
111
|
-
})};
|
112
|
-
|
113
|
-
&:hover {
|
114
|
-
color: ${(0, _constants.get)('colors.btn.primary.hoverText')({
|
115
|
-
theme
|
116
|
-
})};
|
117
|
-
background-color: ${(0, _constants.get)('colors.btn.primary.hoverBg')({
|
118
|
-
theme
|
119
|
-
})};
|
120
|
-
}
|
121
|
-
// focus must come before :active so that the active box shadow overrides
|
122
|
-
&:focus {
|
123
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.primary.focusShadow')({
|
124
|
-
theme
|
125
|
-
})};
|
126
|
-
}
|
127
|
-
|
128
|
-
&:active {
|
129
|
-
background-color: ${(0, _constants.get)('colors.btn.primary.selectedBg')({
|
130
|
-
theme
|
131
|
-
})};
|
132
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.primary.selectedShadow')({
|
133
|
-
theme
|
134
|
-
})};
|
135
|
-
}
|
136
|
-
|
137
|
-
&:disabled {
|
138
|
-
color: ${(0, _constants.get)('colors.btn.primary.disabledText')({
|
139
|
-
theme
|
140
|
-
})};
|
141
|
-
background-color: ${(0, _constants.get)('colors.btn.primary.disabledBg')({
|
142
|
-
theme
|
143
|
-
})};
|
144
|
-
}`,
|
145
|
-
danger: `
|
146
|
-
padding: 5px 16px;
|
147
|
-
color: ${(0, _constants.get)('colors.btn.danger.text')({
|
148
|
-
theme
|
149
|
-
})};
|
150
|
-
border: 1px solid ${(0, _constants.get)('colors.btn.border')({
|
151
|
-
theme
|
152
|
-
})};
|
153
|
-
background-color: ${(0, _constants.get)('colors.btn.bg')({
|
154
|
-
theme
|
155
|
-
})};
|
156
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.shadow')({
|
157
|
-
theme
|
158
|
-
})};
|
159
|
-
|
160
|
-
&:hover {
|
161
|
-
color: ${(0, _constants.get)('colors.btn.danger.hoverText')({
|
162
|
-
theme
|
163
|
-
})};
|
164
|
-
background-color: ${(0, _constants.get)('colors.btn.danger.hoverBg')({
|
165
|
-
theme
|
166
|
-
})};
|
167
|
-
border-color: ${(0, _constants.get)('colors.btn.danger.hoverBorder')({
|
168
|
-
theme
|
169
|
-
})};
|
170
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.danger.hoverShadow')({
|
171
|
-
theme
|
172
|
-
})};
|
173
|
-
}
|
174
|
-
// focus must come before :active so that the active box shadow overrides
|
175
|
-
&:focus {
|
176
|
-
border-color: ${(0, _constants.get)('colors.btn.danger.focusBorder')({
|
177
|
-
theme
|
178
|
-
})};
|
179
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.danger.focusShadow')({
|
180
|
-
theme
|
181
|
-
})};
|
182
|
-
}
|
183
|
-
|
184
|
-
&:active {
|
185
|
-
color: ${(0, _constants.get)('colors.btn.danger.selectedText')({
|
186
|
-
theme
|
187
|
-
})};
|
188
|
-
background-color: ${(0, _constants.get)('colors.btn.danger.selectedBg')({
|
189
|
-
theme
|
190
|
-
})};
|
191
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.danger.selectedShadow')({
|
192
|
-
theme
|
193
|
-
})};
|
194
|
-
border-color: ${(0, _constants.get)('colors.btn.danger.selectedBorder')({
|
195
|
-
theme
|
196
|
-
})};
|
197
|
-
}
|
198
|
-
|
199
|
-
&:disabled {
|
200
|
-
color: ${(0, _constants.get)('colors.btn.danger.disabledText')({
|
201
|
-
theme
|
202
|
-
})};
|
203
|
-
background-color: ${(0, _constants.get)('colors.btn.danger.disabledBg')({
|
204
|
-
theme
|
205
|
-
})};
|
206
|
-
border-color: ${(0, _constants.get)('colors.btn.danger.disabledBorder')({
|
207
|
-
theme
|
208
|
-
})};
|
209
|
-
}
|
210
|
-
`,
|
211
|
-
invisible: `
|
212
|
-
padding: 6px 16px;
|
213
|
-
color: ${(0, _constants.get)('colors.accent.fg')({
|
214
|
-
theme
|
215
|
-
})};
|
216
|
-
background-color: transparent;
|
217
|
-
border: 0;
|
218
|
-
border-radius: ${(0, _constants.get)('radii.2')({
|
219
|
-
theme
|
220
|
-
})};
|
221
|
-
box-shadow: none;
|
222
|
-
|
223
|
-
&:disabled {
|
224
|
-
color: ${(0, _constants.get)('colors.primer.fg.disabled')({
|
225
|
-
theme
|
226
|
-
})};
|
227
|
-
}
|
228
|
-
&:focus {
|
229
|
-
box-shadow: ${(0, _constants.get)('shadows.btn.focusShadow')({
|
230
|
-
theme
|
231
|
-
})};
|
232
|
-
}
|
233
|
-
&:hover {
|
234
|
-
background-color: ${(0, _constants.get)('colors.btn.hoverBg')({
|
235
|
-
theme
|
236
|
-
})};
|
237
|
-
}
|
238
|
-
&:active {
|
239
|
-
background-color: ${(0, _constants.get)('colors.btn.selectedBg')({
|
240
|
-
theme
|
241
|
-
})};
|
242
|
-
}
|
243
|
-
`,
|
244
|
-
block: ``
|
245
|
-
};
|
246
|
-
return style[variant];
|
247
|
-
};
|
248
|
-
|
249
|
-
const ButtonBase = _styledComponents.default.button.withConfig({
|
250
|
-
displayName: "button__ButtonBase",
|
251
|
-
componentId: "sc-15k5iqk-0"
|
252
|
-
})(["", " ", " ", " ", " ", " ", ""], _ButtonStyles.default, props => getVariantStyles(props.theme, props.variant), sizes, props => props.icon && !props.children ? `padding: 4px 6px;` : '', _sx.default, _styledSystem.fontSize);
|
253
|
-
|
254
|
-
const Button = /*#__PURE__*/(0, _react.forwardRef)(({
|
255
|
-
children,
|
256
|
-
...props
|
257
|
-
}, forwardedRef) => {
|
258
|
-
const {
|
259
|
-
icon: Icon,
|
260
|
-
caret
|
261
|
-
} = props;
|
262
|
-
let iconOnly = false;
|
263
|
-
|
264
|
-
if (Icon && !children) {
|
265
|
-
iconOnly = true;
|
266
|
-
}
|
267
|
-
|
268
|
-
const iconWrapStyles = {
|
269
|
-
display: 'inline-block',
|
270
|
-
...(!iconOnly ? {
|
271
|
-
pr: 3
|
272
|
-
} : {})
|
273
|
-
};
|
274
|
-
return /*#__PURE__*/_react.default.createElement(ButtonBase, _extends({
|
275
|
-
ref: forwardedRef
|
276
|
-
}, props, {
|
277
|
-
iconOnly: iconOnly
|
278
|
-
}), Icon && /*#__PURE__*/_react.default.createElement(_Box.default, {
|
279
|
-
sx: iconWrapStyles,
|
280
|
-
"aria-hidden": !iconOnly
|
281
|
-
}, /*#__PURE__*/_react.default.createElement(Icon, null)), children, caret && /*#__PURE__*/_react.default.createElement(_Box.default, {
|
282
|
-
sx: {
|
283
|
-
display: 'inline-block',
|
284
|
-
pl: 3
|
285
|
-
},
|
286
|
-
"aria-hidden": true
|
287
|
-
}, /*#__PURE__*/_react.default.createElement(_octiconsReact.TriangleDownIcon, null)));
|
288
|
-
});
|
289
|
-
Button.displayName = 'Button';
|
290
|
-
Button.defaultProps = {
|
291
|
-
size: 'medium',
|
292
|
-
variant: 'default'
|
293
|
-
};
|
294
|
-
const NewButton = Object.assign(Button, {
|
295
|
-
Counter: _counter.default
|
296
|
-
});
|
297
|
-
var _default = NewButton;
|
298
|
-
exports.default = _default;
|
package/lib/NewButton/counter.js
DELETED
@@ -1,33 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
4
|
-
value: true
|
5
|
-
});
|
6
|
-
exports.default = void 0;
|
7
|
-
|
8
|
-
var _react = _interopRequireDefault(require("react"));
|
9
|
-
|
10
|
-
var _Box = _interopRequireDefault(require("../Box"));
|
11
|
-
|
12
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
13
|
-
|
14
|
-
const styles = {
|
15
|
-
display: 'inline-block',
|
16
|
-
padding: '0px 6px',
|
17
|
-
backgroundColor: 'neutral.muted',
|
18
|
-
borderRadius: '50%',
|
19
|
-
marginLeft: '8px'
|
20
|
-
};
|
21
|
-
|
22
|
-
const Counter = ({
|
23
|
-
count
|
24
|
-
}) => {
|
25
|
-
// get this to announce new count. How? Change aria property for every render? or aria-live?
|
26
|
-
return /*#__PURE__*/_react.default.createElement(_Box.default, {
|
27
|
-
sx: styles
|
28
|
-
}, count);
|
29
|
-
};
|
30
|
-
|
31
|
-
Counter.displayName = "Counter";
|
32
|
-
var _default = Counter;
|
33
|
-
exports.default = _default;
|
package/lib/NewButton/index.d.ts
DELETED
package/lib/NewButton/index.js
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
4
|
-
value: true
|
5
|
-
});
|
6
|
-
Object.defineProperty(exports, "ButtonProps", {
|
7
|
-
enumerable: true,
|
8
|
-
get: function () {
|
9
|
-
return _button.NewButtonProps;
|
10
|
-
}
|
11
|
-
});
|
12
|
-
exports.default = void 0;
|
13
|
-
|
14
|
-
var _button = _interopRequireWildcard(require("./button"));
|
15
|
-
|
16
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
17
|
-
|
18
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
19
|
-
|
20
|
-
var _default = _button.default;
|
21
|
-
exports.default = _default;
|