@atlaskit/textarea 5.1.1 → 5.2.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/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/textarea
2
2
 
3
+ ## 5.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#82028](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/82028) [`065756e95a09`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/065756e95a09) - [ux] This change includes a fix for the TextArea's text color when there is a placeholder and isDisabled is true.
8
+
9
+ ## 5.1.2
10
+
11
+ ### Patch Changes
12
+
13
+ - [#83116](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/83116) [`8d4e99057fe0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8d4e99057fe0) - Upgrade Typescript from `4.9.5` to `5.4.2`
14
+
3
15
  ## 5.1.1
4
16
 
5
17
  ### Patch Changes
@@ -6,7 +6,7 @@
6
6
  "sideEffects": false,
7
7
  "types": "../dist/types/component-tokens.d.ts",
8
8
  "typesVersions": {
9
- ">=4.5 <4.9": {
9
+ ">=4.5 <5.4": {
10
10
  "*": [
11
11
  "../dist/types-ts4.5/component-tokens.d.ts"
12
12
  ]
@@ -120,13 +120,14 @@ var bgAndBorderColorStyles = function bgAndBorderColorStyles(appearance) {
120
120
  }
121
121
  } : {}));
122
122
  };
123
- var placeholderStyle = function placeholderStyle(placeholderTextColor) {
124
- return (0, _react.css)({
125
- '&::placeholder': {
126
- color: placeholderTextColor
127
- }
128
- });
129
- };
123
+ var placeholderStyles = (0, _react.css)({
124
+ '&::placeholder': {
125
+ color: componentTokens.placeholderTextColor
126
+ },
127
+ '&:disabled::placeholder': {
128
+ color: disabledRules.textColor
129
+ }
130
+ });
130
131
  var hoverBackgroundAndBorderStyles = function hoverBackgroundAndBorderStyles(appearance) {
131
132
  return appearance && (0, _react.css)({
132
133
  '&:hover:not(:read-only):not(:focus)': {
@@ -234,7 +235,7 @@ var getBaseStyles = exports.getBaseStyles = function getBaseStyles(_ref) {
234
235
  var dynamicStyles = exports.dynamicStyles = function dynamicStyles(appearance) {
235
236
  return (
236
237
  // eslint-disable-next-line @repo/internal/styles/no-exported-styles
237
- (0, _react.css)([bgAndBorderColorStyles(appearance), hoverBackgroundAndBorderStyles(appearance), placeholderStyle(componentTokens.placeholderTextColor), {
238
+ (0, _react.css)([bgAndBorderColorStyles(appearance), hoverBackgroundAndBorderStyles(appearance), placeholderStyles, {
238
239
  color: componentTokens.textColor,
239
240
  '&:disabled': {
240
241
  color: disabledRules.textColor
@@ -21,7 +21,7 @@ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e;
21
21
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
22
22
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
23
23
  var packageName = "@atlaskit/textarea";
24
- var packageVersion = "5.1.1";
24
+ var packageVersion = "5.2.0";
25
25
  var analyticsParams = {
26
26
  componentName: 'textArea',
27
27
  packageName: packageName,
@@ -111,9 +111,12 @@ const bgAndBorderColorStyles = appearance => appearance && css({
111
111
  }
112
112
  } : {})
113
113
  });
114
- const placeholderStyle = placeholderTextColor => css({
114
+ const placeholderStyles = css({
115
115
  '&::placeholder': {
116
- color: placeholderTextColor
116
+ color: componentTokens.placeholderTextColor
117
+ },
118
+ '&:disabled::placeholder': {
119
+ color: disabledRules.textColor
117
120
  }
118
121
  });
119
122
  const hoverBackgroundAndBorderStyles = appearance => appearance && css({
@@ -214,7 +217,7 @@ css([staticStyles, borderPaddingAndHeightStyles(minimumRows, appearance), resize
214
217
  }]);
215
218
  export const dynamicStyles = appearance =>
216
219
  // eslint-disable-next-line @repo/internal/styles/no-exported-styles
217
- css([bgAndBorderColorStyles(appearance), hoverBackgroundAndBorderStyles(appearance), placeholderStyle(componentTokens.placeholderTextColor), {
220
+ css([bgAndBorderColorStyles(appearance), hoverBackgroundAndBorderStyles(appearance), placeholderStyles, {
218
221
  color: componentTokens.textColor,
219
222
  '&:disabled': {
220
223
  color: disabledRules.textColor
@@ -5,7 +5,7 @@ import { css, jsx } from '@emotion/react';
5
5
  import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next';
6
6
  import { borderWidth, dynamicStyles, getBaseStyles } from './styles';
7
7
  const packageName = "@atlaskit/textarea";
8
- const packageVersion = "5.1.1";
8
+ const packageVersion = "5.2.0";
9
9
  const analyticsParams = {
10
10
  componentName: 'textArea',
11
11
  packageName,
@@ -113,13 +113,14 @@ var bgAndBorderColorStyles = function bgAndBorderColorStyles(appearance) {
113
113
  }
114
114
  } : {}));
115
115
  };
116
- var placeholderStyle = function placeholderStyle(placeholderTextColor) {
117
- return css({
118
- '&::placeholder': {
119
- color: placeholderTextColor
120
- }
121
- });
122
- };
116
+ var placeholderStyles = css({
117
+ '&::placeholder': {
118
+ color: componentTokens.placeholderTextColor
119
+ },
120
+ '&:disabled::placeholder': {
121
+ color: disabledRules.textColor
122
+ }
123
+ });
123
124
  var hoverBackgroundAndBorderStyles = function hoverBackgroundAndBorderStyles(appearance) {
124
125
  return appearance && css({
125
126
  '&:hover:not(:read-only):not(:focus)': {
@@ -227,7 +228,7 @@ export var getBaseStyles = function getBaseStyles(_ref) {
227
228
  export var dynamicStyles = function dynamicStyles(appearance) {
228
229
  return (
229
230
  // eslint-disable-next-line @repo/internal/styles/no-exported-styles
230
- css([bgAndBorderColorStyles(appearance), hoverBackgroundAndBorderStyles(appearance), placeholderStyle(componentTokens.placeholderTextColor), {
231
+ css([bgAndBorderColorStyles(appearance), hoverBackgroundAndBorderStyles(appearance), placeholderStyles, {
231
232
  color: componentTokens.textColor,
232
233
  '&:disabled': {
233
234
  color: disabledRules.textColor
@@ -11,7 +11,7 @@ import { css, jsx } from '@emotion/react';
11
11
  import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next';
12
12
  import { borderWidth, dynamicStyles, getBaseStyles } from './styles';
13
13
  var packageName = "@atlaskit/textarea";
14
- var packageVersion = "5.1.1";
14
+ var packageVersion = "5.2.0";
15
15
  var analyticsParams = {
16
16
  componentName: 'textArea',
17
17
  packageName: packageName,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/textarea",
3
- "version": "5.1.1",
3
+ "version": "5.2.0",
4
4
  "description": "A text area lets users enter long form text which spans over multiple lines.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -44,7 +44,7 @@
44
44
  "@atlaskit/analytics-next": "^9.2.0",
45
45
  "@atlaskit/platform-feature-flags": "^0.2.0",
46
46
  "@atlaskit/theme": "^12.6.0",
47
- "@atlaskit/tokens": "^1.41.0",
47
+ "@atlaskit/tokens": "^1.42.0",
48
48
  "@babel/runtime": "^7.0.0",
49
49
  "@emotion/react": "^11.7.1"
50
50
  },
@@ -65,7 +65,7 @@
65
65
  "jscodeshift": "^0.13.0",
66
66
  "react-dom": "^16.8.0",
67
67
  "storybook-addon-performance": "^0.16.0",
68
- "typescript": "~4.9.5",
68
+ "typescript": "~5.4.2",
69
69
  "wait-for-expect": "^1.2.0"
70
70
  },
71
71
  "keywords": [
@@ -102,4 +102,4 @@
102
102
  }
103
103
  },
104
104
  "prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.1"
105
- }
105
+ }
@@ -6,7 +6,7 @@
6
6
  "sideEffects": false,
7
7
  "types": "../dist/types/styles.d.ts",
8
8
  "typesVersions": {
9
- ">=4.5 <4.9": {
9
+ ">=4.5 <5.4": {
10
10
  "*": [
11
11
  "../dist/types-ts4.5/styles.d.ts"
12
12
  ]
@@ -6,7 +6,7 @@
6
6
  "sideEffects": false,
7
7
  "types": "../dist/types/text-area.d.ts",
8
8
  "typesVersions": {
9
- ">=4.5 <4.9": {
9
+ ">=4.5 <5.4": {
10
10
  "*": [
11
11
  "../dist/types-ts4.5/text-area.d.ts"
12
12
  ]