@atlaskit/task-decision 19.2.4 → 19.2.5
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 +8 -0
- package/dist/cjs/components/TaskItem.js +5 -1
- package/dist/cjs/components/i18n.js +10 -0
- package/dist/es2019/components/TaskItem.js +6 -1
- package/dist/es2019/components/i18n.js +10 -0
- package/dist/esm/components/TaskItem.js +5 -1
- package/dist/esm/components/i18n.js +10 -0
- package/dist/types/components/i18n.d.ts +10 -0
- package/dist/types-ts4.5/components/i18n.d.ts +10 -0
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/task-decision
|
|
2
2
|
|
|
3
|
+
## 19.2.5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#177773](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/177773)
|
|
8
|
+
[`7c804d38fecdb`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/7c804d38fecdb) -
|
|
9
|
+
ENGHEALTH-28090 - fix renderer task a11y label
|
|
10
|
+
|
|
3
11
|
## 19.2.4
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -11,8 +11,10 @@ require("./TaskItem.compiled.css");
|
|
|
11
11
|
var _runtime = require("@compiled/react/runtime");
|
|
12
12
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
13
13
|
var _react = _interopRequireWildcard(require("react"));
|
|
14
|
+
var _reactIntlNext = require("react-intl-next");
|
|
14
15
|
var _baseNew = require("@atlaskit/icon/base-new");
|
|
15
16
|
var _checkboxChecked = _interopRequireDefault(require("@atlaskit/icon/core/checkbox-checked"));
|
|
17
|
+
var _i18n = require("./i18n");
|
|
16
18
|
var _Item = _interopRequireDefault(require("./Item"));
|
|
17
19
|
var _analyticsNext = require("@atlaskit/analytics-next");
|
|
18
20
|
var _analytics = require("../analytics");
|
|
@@ -52,6 +54,8 @@ var TaskItem = function TaskItem(props) {
|
|
|
52
54
|
onClick = props.onClick,
|
|
53
55
|
createAnalyticsEvent = props.createAnalyticsEvent,
|
|
54
56
|
inputRefFromProps = props.inputRef;
|
|
57
|
+
var _useIntl = (0, _reactIntlNext.useIntl)(),
|
|
58
|
+
formatMessage = _useIntl.formatMessage;
|
|
55
59
|
var checkBoxId = (0, _react.useMemo)(function () {
|
|
56
60
|
return getCheckBoxId(taskId);
|
|
57
61
|
}, [taskId]);
|
|
@@ -91,7 +95,7 @@ var TaskItem = function TaskItem(props) {
|
|
|
91
95
|
}
|
|
92
96
|
}, /*#__PURE__*/_react.default.createElement("input", {
|
|
93
97
|
id: checkBoxId,
|
|
94
|
-
"aria-
|
|
98
|
+
"aria-label": formatMessage(isDone ? _i18n.messages.markTaskAsNotCompleted : _i18n.messages.markTaskAsCompleted),
|
|
95
99
|
name: checkBoxId,
|
|
96
100
|
type: "checkbox",
|
|
97
101
|
onChange: handleOnChange,
|
|
@@ -10,5 +10,15 @@ var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
|
|
|
10
10
|
id: 'fabric.editor.fieldsetLabel',
|
|
11
11
|
defaultMessage: 'Action Item List',
|
|
12
12
|
description: 'Label for a list of tasks/ action items'
|
|
13
|
+
},
|
|
14
|
+
markTaskAsCompleted: {
|
|
15
|
+
id: 'platform.taskDecision.markTaskAsCompleted',
|
|
16
|
+
defaultMessage: 'Mark task as completed',
|
|
17
|
+
description: 'Button to mark a task as complete in the editor'
|
|
18
|
+
},
|
|
19
|
+
markTaskAsNotCompleted: {
|
|
20
|
+
id: 'platform.taskDecision.markTaskAsNotCompleted',
|
|
21
|
+
defaultMessage: 'Mark task as not completed',
|
|
22
|
+
description: 'Button to mark a task as not complete in the editor'
|
|
13
23
|
}
|
|
14
24
|
});
|
|
@@ -3,11 +3,13 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
import "./TaskItem.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
5
|
import React, { useMemo, useRef } from 'react';
|
|
6
|
+
import { useIntl } from 'react-intl-next';
|
|
6
7
|
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
7
8
|
import { Icon } from '@atlaskit/icon/base-new';
|
|
8
9
|
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
9
10
|
|
|
10
11
|
import CheckboxCheckedIcon from '@atlaskit/icon/core/checkbox-checked';
|
|
12
|
+
import { messages } from './i18n';
|
|
11
13
|
import Item from './Item';
|
|
12
14
|
import { withAnalyticsEvents } from '@atlaskit/analytics-next';
|
|
13
15
|
import { createAndFireEventInElementsChannel } from '../analytics';
|
|
@@ -42,6 +44,9 @@ const TaskItem = props => {
|
|
|
42
44
|
createAnalyticsEvent,
|
|
43
45
|
inputRef: inputRefFromProps
|
|
44
46
|
} = props;
|
|
47
|
+
const {
|
|
48
|
+
formatMessage
|
|
49
|
+
} = useIntl();
|
|
45
50
|
const checkBoxId = useMemo(() => getCheckBoxId(taskId), [taskId]);
|
|
46
51
|
const handleOnChange = useMemo(() => {
|
|
47
52
|
return _evt => {
|
|
@@ -74,7 +79,7 @@ const TaskItem = props => {
|
|
|
74
79
|
className: ax(["_16jlidpf _1o9zidpf _i0dl1tcg _1bsb1tcg _4t3i1tcg _kqswh2mm _1wpzv2br _1snx1r31 _1746glyw _dx3f1o36 _1h5xidpf _sqizidpf _fs2cidpf _1smcidpf _oezm15vq _1l0615vq _1abj1mn3 _18a711so _16np1elr _a27kkb7n _q3p7usvi _qhqx1nu9 _10cr1ssb _zfav1ssb _m7eu1ooe _l9o0n7od _1efjn7od _1u2istnw _32ro1j9a _1wn015vq _den5ugt7 _zh8l1b66 _g5w3stnw _whhepxbi _1stbpxbi _18tob3bt _1awt1ule _haf81ssb _ra781ssb _cr751ooe _1q8r7vkz _9l2s7vkz _1mh7kb7n _s3uktlke _1davidpf _8bo8stnw _psnc1ssb _4k421ssb _1rvv1ooe _13vl73ad _1t711tcg _1nuz1tcg _cs4qstnw _9j2j1ssb _1mwj1ssb _19l51ooe _12yy1d5g _1miy1elr _1umo18hz _tpz25w2r _k6dg18hz _1qduewfl _q8ft1fvw _1y9t5w2r _ut031fvw _gi9hr01l _1qp6muej _wxkgr01l _wo245w2r _c8dpmuej _d2dcsyzs _1eulsyzs _1bc7syzs _16fmsyzs _bhkusyzs _czfesyzs _1gxgsyzs _19w0syzs _1x1y1lg7"])
|
|
75
80
|
}, /*#__PURE__*/React.createElement("input", {
|
|
76
81
|
id: checkBoxId,
|
|
77
|
-
"aria-
|
|
82
|
+
"aria-label": formatMessage(isDone ? messages.markTaskAsNotCompleted : messages.markTaskAsCompleted),
|
|
78
83
|
name: checkBoxId,
|
|
79
84
|
type: "checkbox",
|
|
80
85
|
onChange: handleOnChange,
|
|
@@ -4,5 +4,15 @@ export const messages = defineMessages({
|
|
|
4
4
|
id: 'fabric.editor.fieldsetLabel',
|
|
5
5
|
defaultMessage: 'Action Item List',
|
|
6
6
|
description: 'Label for a list of tasks/ action items'
|
|
7
|
+
},
|
|
8
|
+
markTaskAsCompleted: {
|
|
9
|
+
id: 'platform.taskDecision.markTaskAsCompleted',
|
|
10
|
+
defaultMessage: 'Mark task as completed',
|
|
11
|
+
description: 'Button to mark a task as complete in the editor'
|
|
12
|
+
},
|
|
13
|
+
markTaskAsNotCompleted: {
|
|
14
|
+
id: 'platform.taskDecision.markTaskAsNotCompleted',
|
|
15
|
+
defaultMessage: 'Mark task as not completed',
|
|
16
|
+
description: 'Button to mark a task as not complete in the editor'
|
|
7
17
|
}
|
|
8
18
|
});
|
|
@@ -3,11 +3,13 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
import "./TaskItem.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
5
|
import React, { useMemo, useRef } from 'react';
|
|
6
|
+
import { useIntl } from 'react-intl-next';
|
|
6
7
|
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
7
8
|
import { Icon } from '@atlaskit/icon/base-new';
|
|
8
9
|
// eslint-disable-next-line @atlassian/tangerine/import/entry-points
|
|
9
10
|
|
|
10
11
|
import CheckboxCheckedIcon from '@atlaskit/icon/core/checkbox-checked';
|
|
12
|
+
import { messages } from './i18n';
|
|
11
13
|
import Item from './Item';
|
|
12
14
|
import { withAnalyticsEvents } from '@atlaskit/analytics-next';
|
|
13
15
|
import { createAndFireEventInElementsChannel } from '../analytics';
|
|
@@ -44,6 +46,8 @@ var TaskItem = function TaskItem(props) {
|
|
|
44
46
|
onClick = props.onClick,
|
|
45
47
|
createAnalyticsEvent = props.createAnalyticsEvent,
|
|
46
48
|
inputRefFromProps = props.inputRef;
|
|
49
|
+
var _useIntl = useIntl(),
|
|
50
|
+
formatMessage = _useIntl.formatMessage;
|
|
47
51
|
var checkBoxId = useMemo(function () {
|
|
48
52
|
return getCheckBoxId(taskId);
|
|
49
53
|
}, [taskId]);
|
|
@@ -83,7 +87,7 @@ var TaskItem = function TaskItem(props) {
|
|
|
83
87
|
}
|
|
84
88
|
}, /*#__PURE__*/React.createElement("input", {
|
|
85
89
|
id: checkBoxId,
|
|
86
|
-
"aria-
|
|
90
|
+
"aria-label": formatMessage(isDone ? messages.markTaskAsNotCompleted : messages.markTaskAsCompleted),
|
|
87
91
|
name: checkBoxId,
|
|
88
92
|
type: "checkbox",
|
|
89
93
|
onChange: handleOnChange,
|
|
@@ -4,5 +4,15 @@ export var messages = defineMessages({
|
|
|
4
4
|
id: 'fabric.editor.fieldsetLabel',
|
|
5
5
|
defaultMessage: 'Action Item List',
|
|
6
6
|
description: 'Label for a list of tasks/ action items'
|
|
7
|
+
},
|
|
8
|
+
markTaskAsCompleted: {
|
|
9
|
+
id: 'platform.taskDecision.markTaskAsCompleted',
|
|
10
|
+
defaultMessage: 'Mark task as completed',
|
|
11
|
+
description: 'Button to mark a task as complete in the editor'
|
|
12
|
+
},
|
|
13
|
+
markTaskAsNotCompleted: {
|
|
14
|
+
id: 'platform.taskDecision.markTaskAsNotCompleted',
|
|
15
|
+
defaultMessage: 'Mark task as not completed',
|
|
16
|
+
description: 'Button to mark a task as not complete in the editor'
|
|
7
17
|
}
|
|
8
18
|
});
|
|
@@ -4,4 +4,14 @@ export declare const messages: {
|
|
|
4
4
|
defaultMessage: string;
|
|
5
5
|
description: string;
|
|
6
6
|
};
|
|
7
|
+
markTaskAsCompleted: {
|
|
8
|
+
id: string;
|
|
9
|
+
defaultMessage: string;
|
|
10
|
+
description: string;
|
|
11
|
+
};
|
|
12
|
+
markTaskAsNotCompleted: {
|
|
13
|
+
id: string;
|
|
14
|
+
defaultMessage: string;
|
|
15
|
+
description: string;
|
|
16
|
+
};
|
|
7
17
|
};
|
|
@@ -4,4 +4,14 @@ export declare const messages: {
|
|
|
4
4
|
defaultMessage: string;
|
|
5
5
|
description: string;
|
|
6
6
|
};
|
|
7
|
+
markTaskAsCompleted: {
|
|
8
|
+
id: string;
|
|
9
|
+
defaultMessage: string;
|
|
10
|
+
description: string;
|
|
11
|
+
};
|
|
12
|
+
markTaskAsNotCompleted: {
|
|
13
|
+
id: string;
|
|
14
|
+
defaultMessage: string;
|
|
15
|
+
description: string;
|
|
16
|
+
};
|
|
7
17
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/task-decision",
|
|
3
|
-
"version": "19.2.
|
|
3
|
+
"version": "19.2.5",
|
|
4
4
|
"description": "Tasks and decisions react components",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -43,9 +43,9 @@
|
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@atlaskit/analytics-namespaced-context": "^7.0.0",
|
|
45
45
|
"@atlaskit/analytics-next": "^11.1.0",
|
|
46
|
-
"@atlaskit/icon": "^27.
|
|
46
|
+
"@atlaskit/icon": "^27.2.0",
|
|
47
47
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
48
|
-
"@atlaskit/tokens": "^5.
|
|
48
|
+
"@atlaskit/tokens": "^5.4.0",
|
|
49
49
|
"@atlaskit/util-service-support": "^6.3.0",
|
|
50
50
|
"@babel/runtime": "^7.0.0",
|
|
51
51
|
"@compiled/react": "^0.18.3",
|