@atlaskit/share 3.0.13 → 3.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 CHANGED
@@ -1,5 +1,26 @@
1
1
  # @atlaskit/share
2
2
 
3
+ ## 3.1.2
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 3.1.1
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
15
+ ## 3.1.0
16
+
17
+ ### Minor Changes
18
+
19
+ - [`c3963026311`](https://bitbucket.org/atlassian/atlassian-frontend/commits/c3963026311) - [ux] Instrumented `@atlaskit/share` with the new theming package, `@atlaskit/tokens`.
20
+
21
+ New tokens will be visible only in applications configured to use the new Tokens API (currently in alpha).
22
+ These changes are intended to be interoperable with the legacy theme implementation. Legacy dark mode users should expect no visual or breaking changes.
23
+
3
24
  ## 3.0.13
4
25
 
5
26
  ### Patch Changes
@@ -41,6 +41,8 @@ var _colors = require("@atlaskit/theme/colors");
41
41
 
42
42
  var _constants = require("@atlaskit/theme/constants");
43
43
 
44
+ var _tokens = require("@atlaskit/tokens");
45
+
44
46
  var _tooltip = _interopRequireDefault(require("@atlaskit/tooltip"));
45
47
 
46
48
  var _i18n = require("../i18n");
@@ -183,7 +185,7 @@ var CopyLinkButton = /*#__PURE__*/function (_React$Component) {
183
185
  content: function content() {
184
186
  return /*#__PURE__*/_react.default.createElement(_styled.InlineDialogContentWrapper, null, /*#__PURE__*/_react.default.createElement(MessageContainer, null, /*#__PURE__*/_react.default.createElement(_checkCircle.default, {
185
187
  label: "",
186
- primaryColor: _colors.G300
188
+ primaryColor: (0, _tokens.token)('color.icon.success', _colors.G300)
187
189
  }), /*#__PURE__*/_react.default.createElement(MessageSpan, null, /*#__PURE__*/_react.default.createElement(_reactIntlNext.FormattedMessage, _i18n.messages.copiedToClipboardMessage))));
188
190
  },
189
191
  isOpen: shouldShowCopiedMessage,
@@ -19,12 +19,14 @@ var _customThemeButton = _interopRequireDefault(require("@atlaskit/button/custom
19
19
 
20
20
  var _colors = require("@atlaskit/theme/colors");
21
21
 
22
+ var _tokens = require("@atlaskit/tokens");
23
+
22
24
  var _excluded = ["text", "textColor", "IntegrationIcon"];
23
25
 
24
26
  var _templateObject, _templateObject2;
25
27
 
26
28
  var IntegrationButtonCopyWrapper = _styledComponents.default.span(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n color: ", ";\n display: flex;\n justify-content: left;\n"])), function (props) {
27
- return props.theme.textColor || _colors.N500;
29
+ return props.theme.textColor || (0, _tokens.token)('color.text', _colors.N500);
28
30
  });
29
31
 
30
32
  var IntegrationIconWrapper = _styledComponents.default.span(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2.default)(["\n margin: 1px 8px 0 0;\n"])));
@@ -23,6 +23,6 @@ var CustomFooterWrapper = _styledComponents.default.div(_templateObject2 || (_te
23
23
 
24
24
  exports.CustomFooterWrapper = CustomFooterWrapper;
25
25
 
26
- var SpinnerWrapper = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n widht: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-content: center;\n"])));
26
+ var SpinnerWrapper = _styledComponents.default.div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2.default)(["\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-content: center;\n"])));
27
27
 
28
28
  exports.SpinnerWrapper = SpinnerWrapper;
@@ -47,6 +47,8 @@ var _colors = require("@atlaskit/theme/colors");
47
47
 
48
48
  var _constants = require("@atlaskit/theme/constants");
49
49
 
50
+ var _tokens = require("@atlaskit/tokens");
51
+
50
52
  var _tooltip = _interopRequireDefault(require("@atlaskit/tooltip"));
51
53
 
52
54
  var _i18n = require("../i18n");
@@ -200,7 +202,7 @@ var InternalForm = /*#__PURE__*/function (_React$PureComponent) {
200
202
  position: "top"
201
203
  }, /*#__PURE__*/_react.default.createElement(_error.default, {
202
204
  label: formatMessage(_i18n.messages.shareFailureIconLabel),
203
- primaryColor: _colors.R400
205
+ primaryColor: (0, _tokens.token)('color.icon.danger', _colors.R400)
204
206
  }))), /*#__PURE__*/_react.default.createElement(_customThemeButton.default, {
205
207
  appearance: buttonAppearance,
206
208
  type: "submit",
@@ -31,6 +31,8 @@ var _colors = require("@atlaskit/theme/colors");
31
31
 
32
32
  var _constants = require("@atlaskit/theme/constants");
33
33
 
34
+ var _tokens = require("@atlaskit/tokens");
35
+
34
36
  var _i18n = require("../i18n");
35
37
 
36
38
  var _analytics = require("./analytics");
@@ -101,7 +103,7 @@ var SplitButtonDropdown = function SplitButtonDropdown(props) {
101
103
  key: integration.type,
102
104
  testId: "split-button-dropdownitem-".concat(integration.type)
103
105
  }, /*#__PURE__*/_react.default.createElement(DropDownIntegrationButtonWrapper, null, /*#__PURE__*/_react.default.createElement(_IntegrationButton.default, {
104
- textColor: _colors.N800,
106
+ textColor: (0, _tokens.token)('color.text', _colors.N800),
105
107
  appearance: "subtle",
106
108
  onClick: function onClick() {
107
109
  return onIntegrationButtonClick(integration);
@@ -9,6 +9,8 @@ exports.default = void 0;
9
9
 
10
10
  var _react = _interopRequireDefault(require("react"));
11
11
 
12
+ /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
13
+ // TODO : https://product-fabric.atlassian.net/browse/DSP-3518
12
14
  var SlackIcon = function SlackIcon() {
13
15
  return /*#__PURE__*/_react.default.createElement("svg", {
14
16
  width: "100",
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "name": "@atlaskit/share",
3
- "version": "3.0.13"
3
+ "version": "3.1.2"
4
4
  }
@@ -8,6 +8,7 @@ import LinkFilledIcon from '@atlaskit/icon/glyph/link-filled';
8
8
  import Popup from '@atlaskit/popup';
9
9
  import { G300 } from '@atlaskit/theme/colors';
10
10
  import { layers } from '@atlaskit/theme/constants';
11
+ import { token } from '@atlaskit/tokens';
11
12
  import Tooltip from '@atlaskit/tooltip';
12
13
  import { messages } from '../i18n';
13
14
  import { InlineDialogContentWrapper } from './ShareFormWrapper/styled';
@@ -126,7 +127,7 @@ export class CopyLinkButton extends React.Component {
126
127
  zIndex: Z_INDEX,
127
128
  content: () => /*#__PURE__*/React.createElement(InlineDialogContentWrapper, null, /*#__PURE__*/React.createElement(MessageContainer, null, /*#__PURE__*/React.createElement(CheckCircleIcon, {
128
129
  label: "",
129
- primaryColor: G300
130
+ primaryColor: token('color.icon.success', G300)
130
131
  }), /*#__PURE__*/React.createElement(MessageSpan, null, /*#__PURE__*/React.createElement(FormattedMessage, messages.copiedToClipboardMessage)))),
131
132
  isOpen: shouldShowCopiedMessage,
132
133
  onClose: this.handleDismissCopiedMessage,
@@ -2,8 +2,9 @@ import React from 'react';
2
2
  import styled from 'styled-components';
3
3
  import Button from '@atlaskit/button/custom-theme-button';
4
4
  import { N500 } from '@atlaskit/theme/colors';
5
+ import { token } from '@atlaskit/tokens';
5
6
  const IntegrationButtonCopyWrapper = styled.span`
6
- color: ${props => props.theme.textColor || N500};
7
+ color: ${props => props.theme.textColor || token('color.text', N500)};
7
8
  display: flex;
8
9
  justify-content: left;
9
10
  `;
@@ -8,7 +8,7 @@ export const CustomFooterWrapper = styled.div`
8
8
  margin: 0 ${-gridSize() * 3}px ${-gridSize() * 2}px ${-gridSize() * 3}px;
9
9
  `;
10
10
  export const SpinnerWrapper = styled.div`
11
- widht: 100%;
11
+ width: 100%;
12
12
  height: 100%;
13
13
  display: flex;
14
14
  justify-content: center;
@@ -10,6 +10,7 @@ import ErrorIcon from '@atlaskit/icon/glyph/error';
10
10
  import Tabs, { Tab, TabList, TabPanel } from '@atlaskit/tabs';
11
11
  import { R400 } from '@atlaskit/theme/colors';
12
12
  import { gridSize } from '@atlaskit/theme/constants';
13
+ import { token } from '@atlaskit/tokens';
13
14
  import Tooltip from '@atlaskit/tooltip';
14
15
  import { messages } from '../i18n';
15
16
  import { TabType } from '../types';
@@ -153,7 +154,7 @@ class InternalForm extends React.PureComponent {
153
154
  position: "top"
154
155
  }, /*#__PURE__*/React.createElement(ErrorIcon, {
155
156
  label: formatMessage(messages.shareFailureIconLabel),
156
- primaryColor: R400
157
+ primaryColor: token('color.icon.danger', R400)
157
158
  }))), /*#__PURE__*/React.createElement(Button, {
158
159
  appearance: buttonAppearance,
159
160
  type: "submit",
@@ -7,6 +7,7 @@ import DropdownMenu, { DropdownItem, DropdownItemGroup } from '@atlaskit/dropdow
7
7
  import ChevronDownIcon from '@atlaskit/icon/glyph/chevron-down';
8
8
  import { N800 } from '@atlaskit/theme/colors';
9
9
  import { borderRadius } from '@atlaskit/theme/constants';
10
+ import { token } from '@atlaskit/tokens';
10
11
  import { messages } from '../i18n';
11
12
  import { shareIntegrationButtonEvent } from './analytics';
12
13
  import IntegrationButton from './IntegrationButton';
@@ -82,7 +83,7 @@ const SplitButtonDropdown = props => {
82
83
  key: integration.type,
83
84
  testId: `split-button-dropdownitem-${integration.type}`
84
85
  }, /*#__PURE__*/React.createElement(DropDownIntegrationButtonWrapper, null, /*#__PURE__*/React.createElement(IntegrationButton, {
85
- textColor: N800,
86
+ textColor: token('color.text', N800),
86
87
  appearance: "subtle",
87
88
  onClick: () => onIntegrationButtonClick(integration),
88
89
  shouldFitContainer: true,
@@ -1,3 +1,5 @@
1
+ /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
2
+ // TODO : https://product-fabric.atlassian.net/browse/DSP-3518
1
3
  import React from 'react';
2
4
 
3
5
  const SlackIcon = () => {
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "name": "@atlaskit/share",
3
- "version": "3.0.13"
3
+ "version": "3.1.2"
4
4
  }
@@ -22,6 +22,7 @@ import LinkFilledIcon from '@atlaskit/icon/glyph/link-filled';
22
22
  import Popup from '@atlaskit/popup';
23
23
  import { G300 } from '@atlaskit/theme/colors';
24
24
  import { layers } from '@atlaskit/theme/constants';
25
+ import { token } from '@atlaskit/tokens';
25
26
  import Tooltip from '@atlaskit/tooltip';
26
27
  import { messages } from '../i18n';
27
28
  import { InlineDialogContentWrapper } from './ShareFormWrapper/styled';
@@ -151,7 +152,7 @@ export var CopyLinkButton = /*#__PURE__*/function (_React$Component) {
151
152
  content: function content() {
152
153
  return /*#__PURE__*/React.createElement(InlineDialogContentWrapper, null, /*#__PURE__*/React.createElement(MessageContainer, null, /*#__PURE__*/React.createElement(CheckCircleIcon, {
153
154
  label: "",
154
- primaryColor: G300
155
+ primaryColor: token('color.icon.success', G300)
155
156
  }), /*#__PURE__*/React.createElement(MessageSpan, null, /*#__PURE__*/React.createElement(FormattedMessage, messages.copiedToClipboardMessage))));
156
157
  },
157
158
  isOpen: shouldShowCopiedMessage,
@@ -8,8 +8,9 @@ import React from 'react';
8
8
  import styled from 'styled-components';
9
9
  import Button from '@atlaskit/button/custom-theme-button';
10
10
  import { N500 } from '@atlaskit/theme/colors';
11
+ import { token } from '@atlaskit/tokens';
11
12
  var IntegrationButtonCopyWrapper = styled.span(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n color: ", ";\n display: flex;\n justify-content: left;\n"])), function (props) {
12
- return props.theme.textColor || N500;
13
+ return props.theme.textColor || token('color.text', N500);
13
14
  });
14
15
  var IntegrationIconWrapper = styled.span(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n margin: 1px 8px 0 0;\n"])));
15
16
 
@@ -6,4 +6,4 @@ import styled from 'styled-components';
6
6
  import { gridSize } from '@atlaskit/theme/constants';
7
7
  export var BottomMessageWrapper = styled.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n width: ", "px;\n"])), gridSize() * 44);
8
8
  export var CustomFooterWrapper = styled.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n /* Must match inline dialog padding. */\n margin: 0 ", "px ", "px ", "px;\n"])), -gridSize() * 3, -gridSize() * 2, -gridSize() * 3);
9
- export var SpinnerWrapper = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n widht: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-content: center;\n"])));
9
+ export var SpinnerWrapper = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-content: center;\n"])));
@@ -28,6 +28,7 @@ import ErrorIcon from '@atlaskit/icon/glyph/error';
28
28
  import Tabs, { Tab, TabList, TabPanel } from '@atlaskit/tabs';
29
29
  import { R400 } from '@atlaskit/theme/colors';
30
30
  import { gridSize } from '@atlaskit/theme/constants';
31
+ import { token } from '@atlaskit/tokens';
31
32
  import Tooltip from '@atlaskit/tooltip';
32
33
  import { messages } from '../i18n';
33
34
  import { TabType } from '../types';
@@ -151,7 +152,7 @@ var InternalForm = /*#__PURE__*/function (_React$PureComponent) {
151
152
  position: "top"
152
153
  }, /*#__PURE__*/React.createElement(ErrorIcon, {
153
154
  label: formatMessage(messages.shareFailureIconLabel),
154
- primaryColor: R400
155
+ primaryColor: token('color.icon.danger', R400)
155
156
  }))), /*#__PURE__*/React.createElement(Button, {
156
157
  appearance: buttonAppearance,
157
158
  type: "submit",
@@ -13,6 +13,7 @@ import DropdownMenu, { DropdownItem, DropdownItemGroup } from '@atlaskit/dropdow
13
13
  import ChevronDownIcon from '@atlaskit/icon/glyph/chevron-down';
14
14
  import { N800 } from '@atlaskit/theme/colors';
15
15
  import { borderRadius } from '@atlaskit/theme/constants';
16
+ import { token } from '@atlaskit/tokens';
16
17
  import { messages } from '../i18n';
17
18
  import { shareIntegrationButtonEvent } from './analytics';
18
19
  import IntegrationButton from './IntegrationButton';
@@ -71,7 +72,7 @@ var SplitButtonDropdown = function SplitButtonDropdown(props) {
71
72
  key: integration.type,
72
73
  testId: "split-button-dropdownitem-".concat(integration.type)
73
74
  }, /*#__PURE__*/React.createElement(DropDownIntegrationButtonWrapper, null, /*#__PURE__*/React.createElement(IntegrationButton, {
74
- textColor: N800,
75
+ textColor: token('color.text', N800),
75
76
  appearance: "subtle",
76
77
  onClick: function onClick() {
77
78
  return onIntegrationButtonClick(integration);
@@ -1,3 +1,5 @@
1
+ /* eslint-disable @atlaskit/design-system/ensure-design-token-usage */
2
+ // TODO : https://product-fabric.atlassian.net/browse/DSP-3518
1
3
  import React from 'react';
2
4
 
3
5
  var SlackIcon = function SlackIcon() {
@@ -1,4 +1,4 @@
1
1
  {
2
2
  "name": "@atlaskit/share",
3
- "version": "3.0.13"
3
+ "version": "3.1.2"
4
4
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/share",
3
- "version": "3.0.13",
3
+ "version": "3.1.2",
4
4
  "description": "Fabric Share Element",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -31,7 +31,7 @@
31
31
  },
32
32
  "dependencies": {
33
33
  "@atlaskit/analytics-next": "^8.2.0",
34
- "@atlaskit/button": "^16.0.0",
34
+ "@atlaskit/button": "^16.2.0",
35
35
  "@atlaskit/dropdown-menu": "^11.1.0",
36
36
  "@atlaskit/form": "^8.5.0",
37
37
  "@atlaskit/icon": "^21.10.0",
@@ -42,8 +42,9 @@
42
42
  "@atlaskit/tabs": "^13.2.3",
43
43
  "@atlaskit/textarea": "^4.3.0",
44
44
  "@atlaskit/theme": "^12.1.0",
45
+ "@atlaskit/tokens": "^0.8.0",
45
46
  "@atlaskit/tooltip": "^17.5.0",
46
- "@atlaskit/user-picker": "^8.6.0",
47
+ "@atlaskit/user-picker": "^8.8.0",
47
48
  "@atlaskit/util-service-support": "^6.1.0",
48
49
  "@babel/runtime": "^7.0.0",
49
50
  "fast-deep-equal": "^3.1.1",
@@ -58,7 +59,7 @@
58
59
  },
59
60
  "devDependencies": {
60
61
  "@atlaskit/docs": "^9.0.0",
61
- "@atlaskit/editor-test-helpers": "^16.1.0",
62
+ "@atlaskit/editor-test-helpers": "^17.0.0",
62
63
  "@atlaskit/flag": "^14.5.0",
63
64
  "@atlaskit/section-message": "^6.0.0",
64
65
  "@atlaskit/select": "^15.0.0",
@@ -100,7 +101,8 @@
100
101
  "@repo/internal": {
101
102
  "ui-components": "lite-mode",
102
103
  "analytics": "analytics-next",
103
- "deprecation": "no-deprecated-imports"
104
+ "deprecation": "no-deprecated-imports",
105
+ "theming": "tokens"
104
106
  }
105
107
  },
106
108
  "prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.1"