@atlaskit/calendar 15.1.0 → 15.1.2
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 +15 -0
- package/dist/cjs/calendar.js +52 -49
- package/dist/es2019/calendar.js +52 -49
- package/dist/esm/calendar.js +52 -49
- package/package.json +11 -9
- package/types/package.json +3 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# @atlaskit/calendar
|
|
2
2
|
|
|
3
|
+
## 15.1.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 15.1.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#166026](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/166026)
|
|
14
|
+
[`962b5e77810fb`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/962b5e77810fb) -
|
|
15
|
+
Adds side-effect config to support Compiled css extraction in third-party apps
|
|
16
|
+
- Updated dependencies
|
|
17
|
+
|
|
3
18
|
## 15.1.0
|
|
4
19
|
|
|
5
20
|
### Minor Changes
|
package/dist/cjs/calendar.js
CHANGED
|
@@ -36,7 +36,7 @@ var boxStyles = (0, _primitives.xcss)({
|
|
|
36
36
|
var analyticsAttributes = {
|
|
37
37
|
componentName: 'calendar',
|
|
38
38
|
packageName: "@atlaskit/calendar",
|
|
39
|
-
packageVersion: "15.1.
|
|
39
|
+
packageVersion: "15.1.2"
|
|
40
40
|
};
|
|
41
41
|
var InnerCalendar = /*#__PURE__*/(0, _react.forwardRef)(function Calendar(_ref, ref) {
|
|
42
42
|
var day = _ref.day,
|
|
@@ -188,54 +188,57 @@ var InnerCalendar = /*#__PURE__*/(0, _react.forwardRef)(function Calendar(_ref,
|
|
|
188
188
|
return "".concat(monthsLong[previousMonth], " ").concat(showPreviousYear ? yearValue - 1 : yearValue);
|
|
189
189
|
};
|
|
190
190
|
var headerId = (0, _useId.useId)();
|
|
191
|
-
return (
|
|
192
|
-
// eslint-disable-next-line
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
191
|
+
return (
|
|
192
|
+
// eslint-disable-next-line jsx-a11y/no-static-element-interactions
|
|
193
|
+
(0, _react2.jsx)("div", {
|
|
194
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
195
|
+
className: className
|
|
196
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
197
|
+
,
|
|
198
|
+
style: style,
|
|
199
|
+
onBlur: handleContainerBlur,
|
|
200
|
+
onFocus: handleContainerFocus,
|
|
201
|
+
"data-testid": testId && "".concat(testId, "--container"),
|
|
202
|
+
ref: ref
|
|
203
|
+
}, (0, _react2.jsx)(_primitives.Box, {
|
|
204
|
+
xcss: boxStyles,
|
|
205
|
+
padding: "space.200",
|
|
206
|
+
"aria-label": "calendar",
|
|
207
|
+
testId: testId && "".concat(testId, "--calendar")
|
|
208
|
+
}, (0, _react2.jsx)(_primitives.Stack, {
|
|
209
|
+
space: "space.150"
|
|
210
|
+
}, (0, _react2.jsx)(_header.default
|
|
211
|
+
// The month number needs to be translated to index in the month
|
|
212
|
+
// name array e.g. 1 (January) -> 0
|
|
213
|
+
, {
|
|
214
|
+
monthLongTitle: monthsLong[monthValue - 1],
|
|
215
|
+
year: yearValue,
|
|
216
|
+
nextMonthLabel: nextMonthLabel,
|
|
217
|
+
previousMonthLabel: previousMonthLabel,
|
|
218
|
+
nextHeading: getNextHeading(),
|
|
219
|
+
previousHeading: getPreviousHeading(),
|
|
220
|
+
handleClickNext: handleClickNext,
|
|
221
|
+
handleClickPrev: handleClickPrev,
|
|
222
|
+
headerId: headerId,
|
|
223
|
+
tabIndex: tabIndex,
|
|
224
|
+
testId: testId
|
|
225
|
+
}), (0, _react2.jsx)(_primitives.Box, {
|
|
226
|
+
role: "grid",
|
|
227
|
+
onKeyDown: handleContainerKeyDown,
|
|
228
|
+
"aria-labelledby": headerId,
|
|
229
|
+
testId: testId && "".concat(testId, "--calendar-dates")
|
|
230
|
+
}, (0, _react2.jsx)(_weekHeader.default, {
|
|
231
|
+
daysShort: daysShort,
|
|
232
|
+
testId: testId
|
|
233
|
+
}), (0, _react2.jsx)(_weekDays.default, {
|
|
234
|
+
weeks: weeks,
|
|
235
|
+
handleClickDay: handleClickDay,
|
|
236
|
+
monthsLong: monthsLong,
|
|
237
|
+
shouldSetFocus: shouldSetFocus || shouldSetFocusOnCurrentDay,
|
|
238
|
+
tabIndex: tabIndex,
|
|
239
|
+
testId: testId
|
|
240
|
+
})))))
|
|
241
|
+
);
|
|
239
242
|
});
|
|
240
243
|
|
|
241
244
|
/**
|
package/dist/es2019/calendar.js
CHANGED
|
@@ -28,7 +28,7 @@ const boxStyles = xcss({
|
|
|
28
28
|
const analyticsAttributes = {
|
|
29
29
|
componentName: 'calendar',
|
|
30
30
|
packageName: "@atlaskit/calendar",
|
|
31
|
-
packageVersion: "15.1.
|
|
31
|
+
packageVersion: "15.1.2"
|
|
32
32
|
};
|
|
33
33
|
const InnerCalendar = /*#__PURE__*/forwardRef(function Calendar({
|
|
34
34
|
day,
|
|
@@ -161,54 +161,57 @@ const InnerCalendar = /*#__PURE__*/forwardRef(function Calendar({
|
|
|
161
161
|
return `${monthsLong[previousMonth]} ${showPreviousYear ? yearValue - 1 : yearValue}`;
|
|
162
162
|
};
|
|
163
163
|
const headerId = useId();
|
|
164
|
-
return
|
|
165
|
-
// eslint-disable-next-line
|
|
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
|
-
|
|
210
|
-
|
|
211
|
-
|
|
164
|
+
return (
|
|
165
|
+
// eslint-disable-next-line jsx-a11y/no-static-element-interactions
|
|
166
|
+
jsx("div", {
|
|
167
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
168
|
+
className: className
|
|
169
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
170
|
+
,
|
|
171
|
+
style: style,
|
|
172
|
+
onBlur: handleContainerBlur,
|
|
173
|
+
onFocus: handleContainerFocus,
|
|
174
|
+
"data-testid": testId && `${testId}--container`,
|
|
175
|
+
ref: ref
|
|
176
|
+
}, jsx(Box, {
|
|
177
|
+
xcss: boxStyles,
|
|
178
|
+
padding: "space.200",
|
|
179
|
+
"aria-label": "calendar",
|
|
180
|
+
testId: testId && `${testId}--calendar`
|
|
181
|
+
}, jsx(Stack, {
|
|
182
|
+
space: "space.150"
|
|
183
|
+
}, jsx(Header
|
|
184
|
+
// The month number needs to be translated to index in the month
|
|
185
|
+
// name array e.g. 1 (January) -> 0
|
|
186
|
+
, {
|
|
187
|
+
monthLongTitle: monthsLong[monthValue - 1],
|
|
188
|
+
year: yearValue,
|
|
189
|
+
nextMonthLabel: nextMonthLabel,
|
|
190
|
+
previousMonthLabel: previousMonthLabel,
|
|
191
|
+
nextHeading: getNextHeading(),
|
|
192
|
+
previousHeading: getPreviousHeading(),
|
|
193
|
+
handleClickNext: handleClickNext,
|
|
194
|
+
handleClickPrev: handleClickPrev,
|
|
195
|
+
headerId: headerId,
|
|
196
|
+
tabIndex: tabIndex,
|
|
197
|
+
testId: testId
|
|
198
|
+
}), jsx(Box, {
|
|
199
|
+
role: "grid",
|
|
200
|
+
onKeyDown: handleContainerKeyDown,
|
|
201
|
+
"aria-labelledby": headerId,
|
|
202
|
+
testId: testId && `${testId}--calendar-dates`
|
|
203
|
+
}, jsx(WeekHeaderComponent, {
|
|
204
|
+
daysShort: daysShort,
|
|
205
|
+
testId: testId
|
|
206
|
+
}), jsx(WeekDaysComponent, {
|
|
207
|
+
weeks: weeks,
|
|
208
|
+
handleClickDay: handleClickDay,
|
|
209
|
+
monthsLong: monthsLong,
|
|
210
|
+
shouldSetFocus: shouldSetFocus || shouldSetFocusOnCurrentDay,
|
|
211
|
+
tabIndex: tabIndex,
|
|
212
|
+
testId: testId
|
|
213
|
+
})))))
|
|
214
|
+
);
|
|
212
215
|
});
|
|
213
216
|
|
|
214
217
|
/**
|
package/dist/esm/calendar.js
CHANGED
|
@@ -32,7 +32,7 @@ var boxStyles = xcss({
|
|
|
32
32
|
var analyticsAttributes = {
|
|
33
33
|
componentName: 'calendar',
|
|
34
34
|
packageName: "@atlaskit/calendar",
|
|
35
|
-
packageVersion: "15.1.
|
|
35
|
+
packageVersion: "15.1.2"
|
|
36
36
|
};
|
|
37
37
|
var InnerCalendar = /*#__PURE__*/forwardRef(function Calendar(_ref, ref) {
|
|
38
38
|
var day = _ref.day,
|
|
@@ -184,54 +184,57 @@ var InnerCalendar = /*#__PURE__*/forwardRef(function Calendar(_ref, ref) {
|
|
|
184
184
|
return "".concat(monthsLong[previousMonth], " ").concat(showPreviousYear ? yearValue - 1 : yearValue);
|
|
185
185
|
};
|
|
186
186
|
var headerId = useId();
|
|
187
|
-
return
|
|
188
|
-
// eslint-disable-next-line
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
187
|
+
return (
|
|
188
|
+
// eslint-disable-next-line jsx-a11y/no-static-element-interactions
|
|
189
|
+
jsx("div", {
|
|
190
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
191
|
+
className: className
|
|
192
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
193
|
+
,
|
|
194
|
+
style: style,
|
|
195
|
+
onBlur: handleContainerBlur,
|
|
196
|
+
onFocus: handleContainerFocus,
|
|
197
|
+
"data-testid": testId && "".concat(testId, "--container"),
|
|
198
|
+
ref: ref
|
|
199
|
+
}, jsx(Box, {
|
|
200
|
+
xcss: boxStyles,
|
|
201
|
+
padding: "space.200",
|
|
202
|
+
"aria-label": "calendar",
|
|
203
|
+
testId: testId && "".concat(testId, "--calendar")
|
|
204
|
+
}, jsx(Stack, {
|
|
205
|
+
space: "space.150"
|
|
206
|
+
}, jsx(Header
|
|
207
|
+
// The month number needs to be translated to index in the month
|
|
208
|
+
// name array e.g. 1 (January) -> 0
|
|
209
|
+
, {
|
|
210
|
+
monthLongTitle: monthsLong[monthValue - 1],
|
|
211
|
+
year: yearValue,
|
|
212
|
+
nextMonthLabel: nextMonthLabel,
|
|
213
|
+
previousMonthLabel: previousMonthLabel,
|
|
214
|
+
nextHeading: getNextHeading(),
|
|
215
|
+
previousHeading: getPreviousHeading(),
|
|
216
|
+
handleClickNext: handleClickNext,
|
|
217
|
+
handleClickPrev: handleClickPrev,
|
|
218
|
+
headerId: headerId,
|
|
219
|
+
tabIndex: tabIndex,
|
|
220
|
+
testId: testId
|
|
221
|
+
}), jsx(Box, {
|
|
222
|
+
role: "grid",
|
|
223
|
+
onKeyDown: handleContainerKeyDown,
|
|
224
|
+
"aria-labelledby": headerId,
|
|
225
|
+
testId: testId && "".concat(testId, "--calendar-dates")
|
|
226
|
+
}, jsx(WeekHeaderComponent, {
|
|
227
|
+
daysShort: daysShort,
|
|
228
|
+
testId: testId
|
|
229
|
+
}), jsx(WeekDaysComponent, {
|
|
230
|
+
weeks: weeks,
|
|
231
|
+
handleClickDay: handleClickDay,
|
|
232
|
+
monthsLong: monthsLong,
|
|
233
|
+
shouldSetFocus: shouldSetFocus || shouldSetFocusOnCurrentDay,
|
|
234
|
+
tabIndex: tabIndex,
|
|
235
|
+
testId: testId
|
|
236
|
+
})))))
|
|
237
|
+
);
|
|
235
238
|
});
|
|
236
239
|
|
|
237
240
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/calendar",
|
|
3
|
-
"version": "15.1.
|
|
3
|
+
"version": "15.1.2",
|
|
4
4
|
"description": "An interactive calendar for date selection experiences.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -12,26 +12,28 @@
|
|
|
12
12
|
"module": "dist/esm/index.js",
|
|
13
13
|
"module:es2019": "dist/es2019/index.js",
|
|
14
14
|
"types": "dist/types/index.d.ts",
|
|
15
|
-
"sideEffects":
|
|
15
|
+
"sideEffects": [
|
|
16
|
+
"**/*.compiled.css"
|
|
17
|
+
],
|
|
16
18
|
"atlaskit:src": "src/index.tsx",
|
|
17
19
|
"atlassian": {
|
|
18
20
|
"team": "Design System Team",
|
|
19
21
|
"website": {
|
|
20
22
|
"name": "Calendar",
|
|
21
|
-
"category": "
|
|
23
|
+
"category": "Forms and input"
|
|
22
24
|
},
|
|
23
25
|
"runReact18": true
|
|
24
26
|
},
|
|
25
27
|
"dependencies": {
|
|
26
28
|
"@atlaskit/analytics-next": "^10.1.0",
|
|
27
29
|
"@atlaskit/button": "^20.3.0",
|
|
28
|
-
"@atlaskit/ds-lib": "^3.
|
|
29
|
-
"@atlaskit/heading": "^
|
|
30
|
-
"@atlaskit/icon": "^22.
|
|
30
|
+
"@atlaskit/ds-lib": "^3.3.0",
|
|
31
|
+
"@atlaskit/heading": "^4.0.0",
|
|
32
|
+
"@atlaskit/icon": "^22.28.0",
|
|
31
33
|
"@atlaskit/locale": "^2.8.0",
|
|
32
|
-
"@atlaskit/primitives": "^13.
|
|
34
|
+
"@atlaskit/primitives": "^13.3.0",
|
|
33
35
|
"@atlaskit/theme": "^14.0.0",
|
|
34
|
-
"@atlaskit/tokens": "^2.
|
|
36
|
+
"@atlaskit/tokens": "^2.4.0",
|
|
35
37
|
"@babel/runtime": "^7.0.0",
|
|
36
38
|
"@emotion/react": "^11.7.1",
|
|
37
39
|
"date-fns": "^2.17.0"
|
|
@@ -50,7 +52,7 @@
|
|
|
50
52
|
"jest-in-case": "^1.0.2",
|
|
51
53
|
"jscodeshift": "^0.13.0",
|
|
52
54
|
"react-dom": "^16.8.0",
|
|
53
|
-
"storybook-addon-performance": "^0.
|
|
55
|
+
"storybook-addon-performance": "^0.17.3",
|
|
54
56
|
"typescript": "~5.4.2",
|
|
55
57
|
"wait-for-expect": "^1.2.0"
|
|
56
58
|
},
|
package/types/package.json
CHANGED
|
@@ -3,7 +3,9 @@
|
|
|
3
3
|
"main": "../dist/cjs/entry-points/types.js",
|
|
4
4
|
"module": "../dist/esm/entry-points/types.js",
|
|
5
5
|
"module:es2019": "../dist/es2019/entry-points/types.js",
|
|
6
|
-
"sideEffects":
|
|
6
|
+
"sideEffects": [
|
|
7
|
+
"**/*.compiled.css"
|
|
8
|
+
],
|
|
7
9
|
"types": "../dist/types/entry-points/types.d.ts",
|
|
8
10
|
"typesVersions": {
|
|
9
11
|
">=4.5 <5.4": {
|