@atlaskit/inline-edit 13.7.9 → 14.0.1
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 +26 -0
- package/dist/cjs/inline-edit.compiled.css +2 -0
- package/dist/cjs/inline-edit.js +46 -51
- package/dist/cjs/inline-editable-textfield.compiled.css +9 -0
- package/dist/cjs/inline-editable-textfield.js +18 -21
- package/dist/cjs/internal/buttons.compiled.css +18 -0
- package/dist/cjs/internal/buttons.js +35 -62
- package/dist/cjs/internal/read-view.compiled.css +28 -0
- package/dist/cjs/internal/read-view.js +21 -55
- package/dist/es2019/inline-edit.compiled.css +2 -0
- package/dist/es2019/inline-edit.js +20 -27
- package/dist/es2019/inline-editable-textfield.compiled.css +9 -0
- package/dist/es2019/inline-editable-textfield.js +16 -19
- package/dist/es2019/internal/buttons.compiled.css +18 -0
- package/dist/es2019/internal/buttons.js +18 -60
- package/dist/es2019/internal/read-view.compiled.css +28 -0
- package/dist/es2019/internal/read-view.js +18 -54
- package/dist/esm/inline-edit.compiled.css +2 -0
- package/dist/esm/inline-edit.js +45 -53
- package/dist/esm/inline-editable-textfield.compiled.css +9 -0
- package/dist/esm/inline-editable-textfield.js +16 -19
- package/dist/esm/internal/buttons.compiled.css +18 -0
- package/dist/esm/internal/buttons.js +32 -60
- package/dist/esm/internal/read-view.compiled.css +28 -0
- package/dist/esm/internal/read-view.js +21 -54
- package/dist/types/entry-points/types.d.ts +1 -1
- package/dist/types/inline-edit.d.ts +2 -2
- package/dist/types/internal/buttons.d.ts +1 -11
- package/dist/types/internal/read-view.d.ts +1 -2
- package/dist/types-ts4.5/entry-points/types.d.ts +1 -1
- package/dist/types-ts4.5/inline-edit.d.ts +2 -2
- package/dist/types-ts4.5/internal/buttons.d.ts +1 -11
- package/dist/types-ts4.5/internal/read-view.d.ts +1 -2
- package/package.json +12 -11
|
@@ -1,29 +1,26 @@
|
|
|
1
|
+
/* inline-editable-textfield.tsx generated by @compiled/babel-plugin v0.33.0 */
|
|
1
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
4
|
var _excluded = ["errorMessage", "isInvalid"];
|
|
5
|
+
import "./inline-editable-textfield.compiled.css";
|
|
6
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
4
7
|
import React, { useCallback, useRef } from 'react';
|
|
8
|
+
import { cx } from '@atlaskit/css';
|
|
5
9
|
import ErrorIcon from '@atlaskit/icon/glyph/error';
|
|
6
10
|
import InlineDialog from '@atlaskit/inline-dialog';
|
|
7
|
-
import { Box
|
|
11
|
+
import { Box } from '@atlaskit/primitives/compiled';
|
|
8
12
|
import Textfield from '@atlaskit/textfield';
|
|
9
13
|
import { R400 } from '@atlaskit/theme/colors';
|
|
10
14
|
import InlineEdit from './inline-edit';
|
|
11
|
-
var errorIconContainerStyles =
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
paddingInline: 'space.075',
|
|
21
|
-
wordBreak: 'break-word'
|
|
22
|
-
});
|
|
23
|
-
var compactStyles = xcss({
|
|
24
|
-
paddingBlock: 'space.050',
|
|
25
|
-
paddingInline: 'space.075'
|
|
26
|
-
});
|
|
15
|
+
var errorIconContainerStyles = {
|
|
16
|
+
root: "_vwz41osq _y4ti12x7"
|
|
17
|
+
};
|
|
18
|
+
var readViewForTextFieldStyles = {
|
|
19
|
+
root: "_11c81oud _1rjcu2gc _18zr12x7 _1e0c1txw _p12f1osq _1nmz1hna"
|
|
20
|
+
};
|
|
21
|
+
var compactStyles = {
|
|
22
|
+
root: "_1rjc1b66 _18zr12x7"
|
|
23
|
+
};
|
|
27
24
|
var InlineEditableTextfield = function InlineEditableTextfield(props) {
|
|
28
25
|
var _props$isCompact = props.isCompact,
|
|
29
26
|
isCompact = _props$isCompact === void 0 ? false : _props$isCompact,
|
|
@@ -54,7 +51,7 @@ var InlineEditableTextfield = function InlineEditableTextfield(props) {
|
|
|
54
51
|
}, /*#__PURE__*/React.createElement(Textfield, _extends({}, props, {
|
|
55
52
|
ref: textFieldRef,
|
|
56
53
|
elemAfterInput: isInvalid && /*#__PURE__*/React.createElement(Box, {
|
|
57
|
-
xcss: errorIconContainerStyles
|
|
54
|
+
xcss: errorIconContainerStyles.root
|
|
58
55
|
}, /*#__PURE__*/React.createElement(ErrorIcon, {
|
|
59
56
|
label: "error",
|
|
60
57
|
primaryColor: "var(--ds-icon-danger, ".concat(R400, ")")
|
|
@@ -66,7 +63,7 @@ var InlineEditableTextfield = function InlineEditableTextfield(props) {
|
|
|
66
63
|
},
|
|
67
64
|
readView: function readView() {
|
|
68
65
|
return /*#__PURE__*/React.createElement(Box, {
|
|
69
|
-
xcss:
|
|
66
|
+
xcss: cx(readViewForTextFieldStyles.root, isCompact && compactStyles.root),
|
|
70
67
|
"data-compact": isCompact,
|
|
71
68
|
testId: testId && "read-view-".concat(testId)
|
|
72
69
|
}, defaultValue || placeholder);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
._11c81oud{font:var(--ds-font-body,normal 400 14px/20px ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,system-ui,"Helvetica Neue",sans-serif)}
|
|
2
|
+
._2rko1sit{border-radius:var(--ds-border-radius,3px)}
|
|
3
|
+
._152t1osq{inset-block-start:100%}
|
|
4
|
+
._16qs1a23{box-shadow:var(--_3t1odq)}
|
|
5
|
+
._1bsbxy5q{width:var(--ds-space-400,2pc)}
|
|
6
|
+
._1e0c1txw{display:flex}
|
|
7
|
+
._1mpy1b66:last-child{margin-inline-start:var(--ds-space-050,4px)}
|
|
8
|
+
._1nlx13nm>button{background-color:var(--_12yx4z3)}
|
|
9
|
+
._1o9zidpf{flex-shrink:0}
|
|
10
|
+
._1pby1kze{z-index:200}
|
|
11
|
+
._1pfh12x7{margin-block-start:var(--ds-space-075,6px)}
|
|
12
|
+
._bfhk13b4{background-color:var(--_1f6rtr1)}
|
|
13
|
+
._kqswstnw{position:absolute}
|
|
14
|
+
._rjxpidpf{inset-inline-end:0}
|
|
15
|
+
._vchhusvi{box-sizing:border-box}
|
|
16
|
+
._l2uv11wk>button:hover{background-color:var(--_qfu7kd)}
|
|
17
|
+
._7mfvdecw>button:active{background-color:var(--ds-surface-overlay-pressed,rgba(179,212,255,.6))}
|
|
18
|
+
._szlb17km>button:active{color:var(--_1lrmnoy)}
|
|
@@ -1,86 +1,58 @@
|
|
|
1
|
+
/* buttons.tsx generated by @compiled/babel-plugin v0.33.0 */
|
|
1
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
|
+
import "./buttons.compiled.css";
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
2
6
|
/* eslint-disable @atlaskit/design-system/no-nested-styles */
|
|
3
7
|
/* eslint-disable @atlaskit/ui-styling-standard/no-nested-selectors */
|
|
4
|
-
/**
|
|
5
|
-
* @jsxRuntime classic
|
|
6
|
-
* @jsx jsx
|
|
7
|
-
*/
|
|
8
8
|
|
|
9
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
10
|
-
import { css, jsx } from '@emotion/react';
|
|
11
9
|
import { IconButton } from '@atlaskit/button/new';
|
|
12
10
|
import ConfirmIcon from '@atlaskit/icon/glyph/check';
|
|
13
11
|
import CancelIcon from '@atlaskit/icon/glyph/cross';
|
|
14
12
|
import { B400, N0, N20A, N30A, N50A, N60A } from '@atlaskit/theme/colors';
|
|
15
|
-
var buttonsContainerStyles =
|
|
16
|
-
|
|
17
|
-
position: 'absolute',
|
|
18
|
-
flexShrink: 0,
|
|
19
|
-
insetBlockStart: '100%',
|
|
20
|
-
insetInlineEnd: 0,
|
|
21
|
-
marginBlockStart: "var(--ds-space-075, 6px)"
|
|
22
|
-
});
|
|
23
|
-
var buttonWrapperBaseStyles = css({
|
|
24
|
-
boxSizing: 'border-box',
|
|
25
|
-
width: "var(--ds-space-400, 32px)",
|
|
26
|
-
zIndex: 200,
|
|
27
|
-
backgroundColor: "var(--ds-surface-overlay, ".concat(N0, ")"),
|
|
28
|
-
borderRadius: "var(--ds-border-radius, 3px)",
|
|
29
|
-
boxShadow: "var(--ds-shadow-overlay, ".concat("0 4px 8px -2px ".concat(N50A, ", 0 0 1px ").concat(N60A), ")"),
|
|
30
|
-
font: "var(--ds-font-body, normal 400 14px/20px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, system-ui, \"Helvetica Neue\", sans-serif)",
|
|
31
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
32
|
-
'&:last-child': {
|
|
33
|
-
marginInlineStart: "var(--ds-space-050, 4px)"
|
|
34
|
-
},
|
|
35
|
-
'& > button': {
|
|
36
|
-
backgroundColor: "var(--ds-surface-overlay, ".concat(N20A, ")")
|
|
37
|
-
},
|
|
38
|
-
'& > button:hover': {
|
|
39
|
-
backgroundColor: "var(--ds-surface-overlay-hovered, ".concat(N30A, ")")
|
|
40
|
-
},
|
|
41
|
-
'& > button:active': {
|
|
42
|
-
backgroundColor: "var(--ds-surface-overlay-pressed, rgba(179, 212, 255, 0.6))",
|
|
43
|
-
color: "var(--ds-text, ".concat(B400, ")")
|
|
44
|
-
}
|
|
45
|
-
});
|
|
46
|
-
// TODO: Fill in the component {description} and ensure links point to the correct {packageName} location.
|
|
47
|
-
// Remove links that the component does not have (such as usage). If there are no links remove them all.
|
|
48
|
-
/**
|
|
49
|
-
* __Buttons__
|
|
50
|
-
*
|
|
51
|
-
* A buttons {description}.
|
|
52
|
-
*
|
|
53
|
-
* - [Examples](https://atlassian.design/components/{packageName}/examples)
|
|
54
|
-
* - [Code](https://atlassian.design/components/{packageName}/code)
|
|
55
|
-
* - [Usage](https://atlassian.design/components/{packageName}/usage)
|
|
56
|
-
*/
|
|
13
|
+
var buttonsContainerStyles = null;
|
|
14
|
+
var buttonWrapperBaseStyles = null;
|
|
57
15
|
var Buttons = function Buttons(_ref) {
|
|
58
16
|
var confirmButtonLabel = _ref.confirmButtonLabel,
|
|
59
17
|
cancelButtonLabel = _ref.cancelButtonLabel,
|
|
60
18
|
onMouseDown = _ref.onMouseDown,
|
|
61
19
|
onCancelClick = _ref.onCancelClick,
|
|
62
20
|
testId = _ref.testId;
|
|
63
|
-
return
|
|
64
|
-
|
|
65
|
-
},
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
21
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
22
|
+
className: ax(["_1e0c1txw _kqswstnw _1o9zidpf _152t1osq _rjxpidpf _1pfh12x7"])
|
|
23
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
24
|
+
tabIndex: -1,
|
|
25
|
+
className: ax(["_2rko1sit _11c81oud _vchhusvi _1bsbxy5q _1pby1kze _bfhk13b4 _16qs1a23 _1mpy1b66 _1nlx13nm _l2uv11wk _7mfvdecw _szlb17km"]),
|
|
26
|
+
style: {
|
|
27
|
+
"--_1f6rtr1": ix("var(--ds-surface-overlay, ".concat(N0, ")")),
|
|
28
|
+
"--_3t1odq": ix("var(--ds-shadow-overlay, ".concat("0 4px 8px -2px ".concat(N50A, ", 0 0 1px ").concat(N60A), ")")),
|
|
29
|
+
"--_12yx4z3": ix("var(--ds-surface-overlay, ".concat(N20A, ")")),
|
|
30
|
+
"--_qfu7kd": ix("var(--ds-surface-overlay-hovered, ".concat(N30A, ")")),
|
|
31
|
+
"--_1lrmnoy": ix("var(--ds-text, ".concat(B400, ")"))
|
|
32
|
+
}
|
|
33
|
+
}, /*#__PURE__*/React.createElement(IconButton, {
|
|
69
34
|
type: "submit",
|
|
70
35
|
icon: function icon(iconProps) {
|
|
71
|
-
return
|
|
36
|
+
return /*#__PURE__*/React.createElement(ConfirmIcon, _extends({}, iconProps, {
|
|
72
37
|
size: "small"
|
|
73
38
|
}));
|
|
74
39
|
},
|
|
75
40
|
onMouseDown: onMouseDown,
|
|
76
41
|
label: confirmButtonLabel,
|
|
77
42
|
testId: testId && "".concat(testId, "--confirm")
|
|
78
|
-
})),
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
43
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
44
|
+
tabIndex: -1,
|
|
45
|
+
className: ax(["_2rko1sit _11c81oud _vchhusvi _1bsbxy5q _1pby1kze _bfhk13b4 _16qs1a23 _1mpy1b66 _1nlx13nm _l2uv11wk _7mfvdecw _szlb17km"]),
|
|
46
|
+
style: {
|
|
47
|
+
"--_1f6rtr1": ix("var(--ds-surface-overlay, ".concat(N0, ")")),
|
|
48
|
+
"--_3t1odq": ix("var(--ds-shadow-overlay, ".concat("0 4px 8px -2px ".concat(N50A, ", 0 0 1px ").concat(N60A), ")")),
|
|
49
|
+
"--_12yx4z3": ix("var(--ds-surface-overlay, ".concat(N20A, ")")),
|
|
50
|
+
"--_qfu7kd": ix("var(--ds-surface-overlay-hovered, ".concat(N30A, ")")),
|
|
51
|
+
"--_1lrmnoy": ix("var(--ds-text, ".concat(B400, ")"))
|
|
52
|
+
}
|
|
53
|
+
}, /*#__PURE__*/React.createElement(IconButton, {
|
|
82
54
|
icon: function icon(iconProps) {
|
|
83
|
-
return
|
|
55
|
+
return /*#__PURE__*/React.createElement(CancelIcon, _extends({}, iconProps, {
|
|
84
56
|
size: "small"
|
|
85
57
|
}));
|
|
86
58
|
},
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
|
|
2
|
+
._18s8ze3t{margin:var(--ds-space-0,0)}
|
|
3
|
+
._1yt4ze3t{padding:var(--ds-space-0,0)}
|
|
4
|
+
._2rko1sit{border-radius:var(--ds-border-radius,3px)}
|
|
5
|
+
._v564thzt{transition:background .2s}
|
|
6
|
+
._14ly1bk5:focus+div{border-width:var(--ds-border-width-outline,2px)}
|
|
7
|
+
._189e1bk5{border-width:var(--ds-border-width-outline,2px)}
|
|
8
|
+
._189e1grb{border-width:var(--ds-border-width-0,0)}
|
|
9
|
+
._1dqoglyw{border-style:none}
|
|
10
|
+
._1dqonqa1{border-style:solid}
|
|
11
|
+
._1h6d1j28{border-color:transparent}
|
|
12
|
+
._1j8znqa1:focus+div{border-style:solid}
|
|
13
|
+
._1xp41p6i:focus+div{border-color:var(--ds-border-focused,#388bff)}
|
|
14
|
+
._12ji1r31{outline-color:currentColor}
|
|
15
|
+
._12y3idpf{outline-width:0}
|
|
16
|
+
._1bsb1osq{width:100%}
|
|
17
|
+
._1bsb1wug{width:auto}
|
|
18
|
+
._1e0c1o8l{display:inline-block}
|
|
19
|
+
._1e0c1ule{display:block}
|
|
20
|
+
._1qu2glyw{outline-style:none}
|
|
21
|
+
._bfhk18uv{background-color:initial}
|
|
22
|
+
._p12f1osq{max-width:100%}
|
|
23
|
+
._r06hglyw{-webkit-appearance:none;appearance:none}
|
|
24
|
+
._vchhusvi{box-sizing:border-box}
|
|
25
|
+
._vwz4kb7n{line-height:1}._128midpf:focus-visible{outline-width:0}
|
|
26
|
+
._mizu1r31:focus-visible{outline-color:currentColor}
|
|
27
|
+
._ra3xglyw:focus-visible{outline-style:none}
|
|
28
|
+
._irr32tgk:hover{background-color:var(--_1y60f1n)}
|
|
@@ -1,51 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
*/
|
|
1
|
+
/* read-view.tsx generated by @compiled/babel-plugin v0.33.0 */
|
|
2
|
+
import "./read-view.compiled.css";
|
|
3
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
5
4
|
import React, { useRef } from 'react';
|
|
6
|
-
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
-
import { css, jsx } from '@emotion/react';
|
|
9
|
-
import { Pressable, xcss } from '@atlaskit/primitives';
|
|
5
|
+
import { Pressable } from '@atlaskit/primitives/compiled';
|
|
10
6
|
import { N30 } from '@atlaskit/theme/colors';
|
|
11
|
-
var readViewContainerStyles =
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
padding: 'space.0',
|
|
18
|
-
appearance: 'none',
|
|
19
|
-
background: 'transparent',
|
|
20
|
-
border: 0,
|
|
21
|
-
lineHeight: 1,
|
|
22
|
-
outline: 0,
|
|
23
|
-
':focus-visible': {
|
|
24
|
-
outline: 0
|
|
25
|
-
},
|
|
26
|
-
// @ts-expect-error
|
|
27
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
28
|
-
':focus + div': {
|
|
29
|
-
borderColor: 'color.border.focused',
|
|
30
|
-
borderWidth: 'border.width.outline',
|
|
31
|
-
borderStyle: 'solid'
|
|
32
|
-
}
|
|
33
|
-
});
|
|
34
|
-
var readViewWrapperStyles = css({
|
|
35
|
-
display: 'inline-block',
|
|
36
|
-
boxSizing: 'border-box',
|
|
37
|
-
width: 'auto',
|
|
38
|
-
maxWidth: '100%',
|
|
39
|
-
border: '2px solid transparent',
|
|
40
|
-
borderRadius: "var(--ds-border-radius, 3px)",
|
|
41
|
-
transition: 'background 0.2s',
|
|
42
|
-
'&:hover': {
|
|
43
|
-
background: "var(--ds-background-neutral-subtle-hovered, ".concat(N30, ")")
|
|
44
|
-
}
|
|
45
|
-
});
|
|
46
|
-
var readViewFitContainerWidthStyles = css({
|
|
47
|
-
width: '100%'
|
|
48
|
-
});
|
|
7
|
+
var readViewContainerStyles = null;
|
|
8
|
+
var editButtonStyles = {
|
|
9
|
+
root: "_18s8ze3t _1yt4ze3t _12ji1r31 _1qu2glyw _12y3idpf _189e1grb _1dqoglyw _1h6d1j28 _1e0c1ule _r06hglyw _bfhk18uv _vwz4kb7n _1xp41p6i _14ly1bk5 _1j8znqa1 _mizu1r31 _ra3xglyw _128midpf"
|
|
10
|
+
};
|
|
11
|
+
var readViewWrapperStyles = null;
|
|
12
|
+
var readViewFitContainerWidthStyles = null;
|
|
49
13
|
var DRAG_THRESHOLD = 5;
|
|
50
14
|
var ReadView = function ReadView(_ref) {
|
|
51
15
|
var editButtonLabel = _ref.editButtonLabel,
|
|
@@ -71,16 +35,15 @@ var ReadView = function ReadView(_ref) {
|
|
|
71
35
|
postReadViewClick();
|
|
72
36
|
}
|
|
73
37
|
};
|
|
74
|
-
return
|
|
75
|
-
|
|
76
|
-
},
|
|
77
|
-
xcss: editButtonStyles,
|
|
38
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
39
|
+
className: ax(["_vwz4kb7n"])
|
|
40
|
+
}, /*#__PURE__*/React.createElement(Pressable, {
|
|
41
|
+
xcss: editButtonStyles.root,
|
|
78
42
|
onClick: onEditRequested,
|
|
79
43
|
ref: editButtonRef,
|
|
80
44
|
testId: testId && "".concat(testId, "--edit-button"),
|
|
81
45
|
"aria-label": editButtonLabel
|
|
82
|
-
}),
|
|
83
|
-
css: [readViewWrapperStyles, readViewFitContainerWidth && readViewFitContainerWidthStyles]
|
|
46
|
+
}), /*#__PURE__*/React.createElement("div", {
|
|
84
47
|
/**
|
|
85
48
|
* It is not normally acceptable to add click handlers to non-interactive elements
|
|
86
49
|
* as this is an accessibility anti-pattern. However, because this instance is
|
|
@@ -88,14 +51,18 @@ var ReadView = function ReadView(_ref) {
|
|
|
88
51
|
* creating an inaccessible custom element, we can add role="presentation" so that
|
|
89
52
|
* there is no negative impacts to assistive technologies.
|
|
90
53
|
* (Why links are embeeded in inline-edit is for another day...)
|
|
91
|
-
|
|
54
|
+
*/
|
|
92
55
|
role: "presentation",
|
|
93
56
|
onClick: onReadViewClick,
|
|
94
57
|
onMouseDown: function onMouseDown(e) {
|
|
95
58
|
startX.current = e.clientX;
|
|
96
59
|
startY.current = e.clientY;
|
|
97
60
|
},
|
|
98
|
-
"data-read-view-fit-container-width": readViewFitContainerWidth
|
|
61
|
+
"data-read-view-fit-container-width": readViewFitContainerWidth,
|
|
62
|
+
className: ax(["_2rko1sit _v564thzt _1h6d1j28 _1dqonqa1 _189e1bk5 _1e0c1o8l _vchhusvi _1bsb1wug _p12f1osq _irr32tgk", readViewFitContainerWidth && "_1bsb1osq"]),
|
|
63
|
+
style: {
|
|
64
|
+
"--_1y60f1n": ix("var(--ds-background-neutral-subtle-hovered, ".concat(N30, ")"))
|
|
65
|
+
}
|
|
99
66
|
}, readView()));
|
|
100
67
|
};
|
|
101
68
|
export default ReadView;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type { InlineEditableTextfieldProps, InlineEditProps } from '../types';
|
|
1
|
+
export type { InlineEditableTextfieldProps, InlineEditProps, ExtendedFieldProps } from '../types';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import { type InlineEditProps } from './types';
|
|
3
|
-
declare const InlineEdit: <FieldValue extends unknown = string>(props: InlineEditProps<FieldValue>) =>
|
|
3
|
+
declare const InlineEdit: <FieldValue extends unknown = string>(props: InlineEditProps<FieldValue>) => JSX.Element;
|
|
4
4
|
export default InlineEdit;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
/// <reference types="react" />
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
interface ButtonsProp {
|
|
8
7
|
confirmButtonLabel: string;
|
|
9
8
|
cancelButtonLabel: string;
|
|
@@ -11,14 +10,5 @@ interface ButtonsProp {
|
|
|
11
10
|
onCancelClick: (event: React.MouseEvent<HTMLElement>) => void;
|
|
12
11
|
testId?: string;
|
|
13
12
|
}
|
|
14
|
-
|
|
15
|
-
* __Buttons__
|
|
16
|
-
*
|
|
17
|
-
* A buttons {description}.
|
|
18
|
-
*
|
|
19
|
-
* - [Examples](https://atlassian.design/components/{packageName}/examples)
|
|
20
|
-
* - [Code](https://atlassian.design/components/{packageName}/code)
|
|
21
|
-
* - [Usage](https://atlassian.design/components/{packageName}/usage)
|
|
22
|
-
*/
|
|
23
|
-
declare const Buttons: ({ confirmButtonLabel, cancelButtonLabel, onMouseDown, onCancelClick, testId, }: ButtonsProp) => jsx.JSX.Element;
|
|
13
|
+
declare const Buttons: ({ confirmButtonLabel, cancelButtonLabel, onMouseDown, onCancelClick, testId, }: ButtonsProp) => JSX.Element;
|
|
24
14
|
export default Buttons;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
interface ReadViewProps {
|
|
8
7
|
editButtonLabel: string;
|
|
9
8
|
onEditRequested: () => void;
|
|
@@ -13,5 +12,5 @@ interface ReadViewProps {
|
|
|
13
12
|
readView: () => React.ReactNode;
|
|
14
13
|
testId?: string;
|
|
15
14
|
}
|
|
16
|
-
declare const ReadView: ({ editButtonLabel, onEditRequested, postReadViewClick, editButtonRef, readViewFitContainerWidth, readView, testId, }: ReadViewProps) =>
|
|
15
|
+
declare const ReadView: ({ editButtonLabel, onEditRequested, postReadViewClick, editButtonRef, readViewFitContainerWidth, readView, testId, }: ReadViewProps) => JSX.Element;
|
|
17
16
|
export default ReadView;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type { InlineEditableTextfieldProps, InlineEditProps } from '../types';
|
|
1
|
+
export type { InlineEditableTextfieldProps, InlineEditProps, ExtendedFieldProps } from '../types';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import { type InlineEditProps } from './types';
|
|
3
|
-
declare const InlineEdit: <FieldValue extends unknown = string>(props: InlineEditProps<FieldValue>) =>
|
|
3
|
+
declare const InlineEdit: <FieldValue extends unknown = string>(props: InlineEditProps<FieldValue>) => JSX.Element;
|
|
4
4
|
export default InlineEdit;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsxRuntime classic
|
|
4
4
|
* @jsx jsx
|
|
5
5
|
*/
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
interface ButtonsProp {
|
|
8
7
|
confirmButtonLabel: string;
|
|
9
8
|
cancelButtonLabel: string;
|
|
@@ -11,14 +10,5 @@ interface ButtonsProp {
|
|
|
11
10
|
onCancelClick: (event: React.MouseEvent<HTMLElement>) => void;
|
|
12
11
|
testId?: string;
|
|
13
12
|
}
|
|
14
|
-
|
|
15
|
-
* __Buttons__
|
|
16
|
-
*
|
|
17
|
-
* A buttons {description}.
|
|
18
|
-
*
|
|
19
|
-
* - [Examples](https://atlassian.design/components/{packageName}/examples)
|
|
20
|
-
* - [Code](https://atlassian.design/components/{packageName}/code)
|
|
21
|
-
* - [Usage](https://atlassian.design/components/{packageName}/usage)
|
|
22
|
-
*/
|
|
23
|
-
declare const Buttons: ({ confirmButtonLabel, cancelButtonLabel, onMouseDown, onCancelClick, testId, }: ButtonsProp) => jsx.JSX.Element;
|
|
13
|
+
declare const Buttons: ({ confirmButtonLabel, cancelButtonLabel, onMouseDown, onCancelClick, testId, }: ButtonsProp) => JSX.Element;
|
|
24
14
|
export default Buttons;
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
|
-
import { jsx } from '@emotion/react';
|
|
7
6
|
interface ReadViewProps {
|
|
8
7
|
editButtonLabel: string;
|
|
9
8
|
onEditRequested: () => void;
|
|
@@ -13,5 +12,5 @@ interface ReadViewProps {
|
|
|
13
12
|
readView: () => React.ReactNode;
|
|
14
13
|
testId?: string;
|
|
15
14
|
}
|
|
16
|
-
declare const ReadView: ({ editButtonLabel, onEditRequested, postReadViewClick, editButtonRef, readViewFitContainerWidth, readView, testId, }: ReadViewProps) =>
|
|
15
|
+
declare const ReadView: ({ editButtonLabel, onEditRequested, postReadViewClick, editButtonRef, readViewFitContainerWidth, readView, testId, }: ReadViewProps) => JSX.Element;
|
|
17
16
|
export default ReadView;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/inline-edit",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "14.0.1",
|
|
4
4
|
"description": "An inline edit displays a custom input component that switches between reading and editing on the same page.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -34,20 +34,21 @@
|
|
|
34
34
|
"runReact18": true
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@atlaskit/analytics-next": "^10.
|
|
37
|
+
"@atlaskit/analytics-next": "^10.2.0",
|
|
38
38
|
"@atlaskit/button": "^20.3.0",
|
|
39
39
|
"@atlaskit/codemod-utils": "^4.2.0",
|
|
40
|
-
"@atlaskit/
|
|
41
|
-
"@atlaskit/
|
|
42
|
-
"@atlaskit/
|
|
40
|
+
"@atlaskit/css": "^0.7.0",
|
|
41
|
+
"@atlaskit/form": "^11.0.0",
|
|
42
|
+
"@atlaskit/icon": "^23.1.0",
|
|
43
|
+
"@atlaskit/inline-dialog": "^16.0.0",
|
|
43
44
|
"@atlaskit/platform-feature-flags": "^0.3.0",
|
|
44
45
|
"@atlaskit/primitives": "^13.3.0",
|
|
45
|
-
"@atlaskit/textfield": "^6.
|
|
46
|
+
"@atlaskit/textfield": "^6.7.0",
|
|
46
47
|
"@atlaskit/theme": "^14.0.0",
|
|
47
|
-
"@atlaskit/tokens": "^2.
|
|
48
|
+
"@atlaskit/tokens": "^2.5.0",
|
|
48
49
|
"@atlaskit/visually-hidden": "^1.5.0",
|
|
49
50
|
"@babel/runtime": "^7.0.0",
|
|
50
|
-
"@
|
|
51
|
+
"@compiled/react": "^0.18.1"
|
|
51
52
|
},
|
|
52
53
|
"peerDependencies": {
|
|
53
54
|
"react": "^16.8.0 || ^17.0.0 || ^18.0.0"
|
|
@@ -55,15 +56,15 @@
|
|
|
55
56
|
"devDependencies": {
|
|
56
57
|
"@af/accessibility-testing": "*",
|
|
57
58
|
"@af/integration-testing": "*",
|
|
58
|
-
"@atlaskit/datetime-picker": "^15.
|
|
59
|
+
"@atlaskit/datetime-picker": "^15.10.0",
|
|
59
60
|
"@atlaskit/docs": "*",
|
|
60
61
|
"@atlaskit/ds-lib": "^3.3.0",
|
|
61
62
|
"@atlaskit/section-message": "^6.8.0",
|
|
62
|
-
"@atlaskit/select": "^18.
|
|
63
|
+
"@atlaskit/select": "^18.9.0",
|
|
63
64
|
"@atlaskit/ssr": "*",
|
|
64
65
|
"@atlaskit/tag": "^12.6.0",
|
|
65
66
|
"@atlaskit/tag-group": "^11.0.0",
|
|
66
|
-
"@atlaskit/textarea": "^5.
|
|
67
|
+
"@atlaskit/textarea": "^5.7.0",
|
|
67
68
|
"@atlaskit/visual-regression": "*",
|
|
68
69
|
"@atlassian/feature-flags-test-utils": "*",
|
|
69
70
|
"@emotion/styled": "^11.0.0",
|