@licklist/design 0.78.34 → 0.78.36
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/dist/index.d.ts +4 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -2
- package/dist/provider/location-input/LocationInput.js +1 -1
- package/dist/v2/components/ActionMenu/ActionMenu.d.ts.map +1 -1
- package/dist/v2/components/ActionMenu/ActionMenu.js +6 -16
- package/dist/v2/components/ActionMenu/ActionMenu.scss.js +1 -1
- package/dist/v2/components/Badge/Badge.d.ts +1 -0
- package/dist/v2/components/Badge/Badge.d.ts.map +1 -1
- package/dist/v2/components/Badge/Badge.js +2 -1
- package/dist/v2/components/Badge/Badge.scss.js +1 -1
- package/dist/v2/components/Button/Button.scss.js +1 -1
- package/dist/v2/components/Checkbox/Checkbox.scss.js +1 -1
- package/dist/v2/components/FormField/FormField.d.ts +3 -0
- package/dist/v2/components/FormField/FormField.d.ts.map +1 -1
- package/dist/v2/components/FormField/FormField.js +14 -3
- package/dist/v2/components/FormField/FormField.scss.js +1 -1
- package/dist/v2/components/IconButton/IconButton.d.ts +9 -0
- package/dist/v2/components/IconButton/IconButton.d.ts.map +1 -0
- package/dist/v2/components/IconButton/IconButton.js +137 -0
- package/dist/v2/components/IconButton/IconButton.scss.js +6 -0
- package/dist/v2/components/IconButton/index.d.ts +3 -0
- package/dist/v2/components/IconButton/index.d.ts.map +1 -0
- package/dist/v2/components/NewInput/NewInput.d.ts +1 -0
- package/dist/v2/components/NewInput/NewInput.d.ts.map +1 -1
- package/dist/v2/components/NewInput/NewInput.js +7 -4
- package/dist/v2/components/NewPageHeader/NewPageHeader.scss.js +1 -1
- package/dist/v2/components/QuickFilter/QuickFilter.scss.js +1 -1
- package/dist/v2/components/TableSortIcon/TableSortIcon.d.ts.map +1 -1
- package/dist/v2/components/TableSortIcon/TableSortIcon.js +5 -3
- package/dist/v2/components/ZoneCard/AddResourceButton.d.ts +8 -0
- package/dist/v2/components/ZoneCard/AddResourceButton.d.ts.map +1 -0
- package/dist/v2/components/ZoneCard/AddResourceButton.js +17 -0
- package/dist/v2/components/ZoneCard/ResourceRow.d.ts +28 -0
- package/dist/v2/components/ZoneCard/ResourceRow.d.ts.map +1 -0
- package/dist/v2/components/ZoneCard/ResourceRow.js +191 -0
- package/dist/v2/components/ZoneCard/ZoneCard.d.ts +25 -0
- package/dist/v2/components/ZoneCard/ZoneCard.d.ts.map +1 -0
- package/dist/v2/components/ZoneCard/ZoneCard.js +43 -0
- package/dist/v2/components/ZoneCard/ZoneCard.scss.js +6 -0
- package/dist/v2/components/ZoneCard/ZoneContainer.d.ts +12 -0
- package/dist/v2/components/ZoneCard/ZoneContainer.d.ts.map +1 -0
- package/dist/v2/components/ZoneCard/ZoneContainer.js +16 -0
- package/dist/v2/components/ZoneCard/ZoneHeader.d.ts +20 -0
- package/dist/v2/components/ZoneCard/ZoneHeader.d.ts.map +1 -0
- package/dist/v2/components/ZoneCard/ZoneHeader.js +149 -0
- package/dist/v2/components/ZoneCard/index.d.ts +11 -0
- package/dist/v2/components/ZoneCard/index.d.ts.map +1 -0
- package/dist/v2/components/index.d.ts +5 -1
- package/dist/v2/components/index.d.ts.map +1 -1
- package/dist/v2/icons/index.d.ts +36 -2
- package/dist/v2/icons/index.d.ts.map +1 -1
- package/dist/v2/icons/index.js +97 -29
- package/dist/v2/index.d.ts +10 -0
- package/dist/v2/index.d.ts.map +1 -1
- package/dist/v2/pages/Settings/components/SidebarCustomisation.js +5 -0
- package/dist/v2/pages/Settings/components/SidebarNavItem.js +5 -0
- package/dist/v2/pages/ZonesResources/ZonesResourcesPage.d.ts +12 -0
- package/dist/v2/pages/ZonesResources/ZonesResourcesPage.d.ts.map +1 -0
- package/dist/v2/pages/ZonesResources/ZonesResourcesPage.js +47 -0
- package/dist/v2/pages/ZonesResources/ZonesResourcesPage.scss.js +6 -0
- package/dist/v2/pages/ZonesResources/index.d.ts +3 -0
- package/dist/v2/pages/ZonesResources/index.d.ts.map +1 -0
- package/dist/v2/styles/form/NewInput.scss.js +1 -1
- package/package.json +3 -3
- package/src/index.ts +4 -1
- package/src/provider/location-input/LocationInput.tsx +1 -1
- package/src/v2/components/ActionMenu/ActionMenu.scss +7 -20
- package/src/v2/components/ActionMenu/ActionMenu.stories.tsx +58 -0
- package/src/v2/components/ActionMenu/ActionMenu.tsx +3 -6
- package/src/v2/components/Badge/Badge.scss +25 -23
- package/src/v2/components/Badge/Badge.tsx +3 -0
- package/src/v2/components/Checkbox/Checkbox.scss +3 -3
- package/src/v2/components/Customer/CustomersList.scss +60 -9
- package/src/v2/components/FormField/FormField.scss +20 -1
- package/src/v2/components/FormField/FormField.tsx +33 -19
- package/src/v2/components/IconButton/IconButton.scss +81 -0
- package/src/v2/components/IconButton/IconButton.stories.tsx +51 -0
- package/src/v2/components/IconButton/IconButton.tsx +50 -0
- package/src/v2/components/IconButton/index.ts +2 -0
- package/src/v2/components/NewInput/NewInput.tsx +5 -2
- package/src/v2/components/NewPageHeader/NewPageHeader.scss +1 -5
- package/src/v2/components/NewPageHeader/NewPageHeader.stories.tsx +28 -0
- package/src/v2/components/QuickFilter/QuickFilter.scss +14 -3
- package/src/v2/components/TableSortIcon/TableSortIcon.tsx +3 -5
- package/src/v2/components/ZoneCard/AddResourceButton.tsx +20 -0
- package/src/v2/components/ZoneCard/ResourceRow.tsx +115 -0
- package/src/v2/components/ZoneCard/ZoneCard.scss +226 -0
- package/src/v2/components/ZoneCard/ZoneCard.stories.tsx +137 -0
- package/src/v2/components/ZoneCard/ZoneCard.tsx +69 -0
- package/src/v2/components/ZoneCard/ZoneContainer.tsx +26 -0
- package/src/v2/components/ZoneCard/ZoneHeader.tsx +84 -0
- package/src/v2/components/ZoneCard/index.ts +14 -0
- package/src/v2/components/index.ts +13 -1
- package/src/v2/icons/index.tsx +147 -14
- package/src/v2/index.ts +21 -0
- package/src/v2/pages/ZonesResources/ZonesResourcesPage.scss +43 -0
- package/src/v2/pages/ZonesResources/ZonesResourcesPage.stories.tsx +46 -0
- package/src/v2/pages/ZonesResources/ZonesResourcesPage.tsx +49 -0
- package/src/v2/pages/ZonesResources/index.ts +2 -0
- package/src/v2/styles/components/Button.scss +1 -0
- package/src/v2/styles/form/NewInput.scss +39 -6
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
|
+
import { ArrowLeftIcon, PlusIcon, DeleteIcon } from '../../icons/index.js';
|
|
3
|
+
import './IconButton.scss.js';
|
|
4
|
+
|
|
5
|
+
function _define_property(obj, key, value) {
|
|
6
|
+
if (key in obj) {
|
|
7
|
+
Object.defineProperty(obj, key, {
|
|
8
|
+
value: value,
|
|
9
|
+
enumerable: true,
|
|
10
|
+
configurable: true,
|
|
11
|
+
writable: true
|
|
12
|
+
});
|
|
13
|
+
} else {
|
|
14
|
+
obj[key] = value;
|
|
15
|
+
}
|
|
16
|
+
return obj;
|
|
17
|
+
}
|
|
18
|
+
function _object_spread(target) {
|
|
19
|
+
for(var i = 1; i < arguments.length; i++){
|
|
20
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
21
|
+
var ownKeys = Object.keys(source);
|
|
22
|
+
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
23
|
+
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
24
|
+
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
25
|
+
}));
|
|
26
|
+
}
|
|
27
|
+
ownKeys.forEach(function(key) {
|
|
28
|
+
_define_property(target, key, source[key]);
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
return target;
|
|
32
|
+
}
|
|
33
|
+
function ownKeys(object, enumerableOnly) {
|
|
34
|
+
var keys = Object.keys(object);
|
|
35
|
+
if (Object.getOwnPropertySymbols) {
|
|
36
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
|
37
|
+
if (enumerableOnly) {
|
|
38
|
+
symbols = symbols.filter(function(sym) {
|
|
39
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
keys.push.apply(keys, symbols);
|
|
43
|
+
}
|
|
44
|
+
return keys;
|
|
45
|
+
}
|
|
46
|
+
function _object_spread_props(target, source) {
|
|
47
|
+
source = source != null ? source : {};
|
|
48
|
+
if (Object.getOwnPropertyDescriptors) {
|
|
49
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
50
|
+
} else {
|
|
51
|
+
ownKeys(Object(source)).forEach(function(key) {
|
|
52
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
return target;
|
|
56
|
+
}
|
|
57
|
+
function _object_without_properties(source, excluded) {
|
|
58
|
+
if (source == null) return {};
|
|
59
|
+
var target = _object_without_properties_loose(source, excluded);
|
|
60
|
+
var key, i;
|
|
61
|
+
if (Object.getOwnPropertySymbols) {
|
|
62
|
+
var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
|
|
63
|
+
for(i = 0; i < sourceSymbolKeys.length; i++){
|
|
64
|
+
key = sourceSymbolKeys[i];
|
|
65
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
66
|
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
67
|
+
target[key] = source[key];
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
return target;
|
|
71
|
+
}
|
|
72
|
+
function _object_without_properties_loose(source, excluded) {
|
|
73
|
+
if (source == null) return {};
|
|
74
|
+
var target = {};
|
|
75
|
+
var sourceKeys = Object.keys(source);
|
|
76
|
+
var key, i;
|
|
77
|
+
for(i = 0; i < sourceKeys.length; i++){
|
|
78
|
+
key = sourceKeys[i];
|
|
79
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
80
|
+
target[key] = source[key];
|
|
81
|
+
}
|
|
82
|
+
return target;
|
|
83
|
+
}
|
|
84
|
+
function IconButton(_param) {
|
|
85
|
+
var label = _param.label, _param_icon = _param.icon, icon = _param_icon === void 0 ? 'back' : _param_icon, _param_variant = _param.variant, variant = _param_variant === void 0 ? 'default' : _param_variant, _param_className = _param.className, className = _param_className === void 0 ? '' : _param_className, props = _object_without_properties(_param, [
|
|
86
|
+
"label",
|
|
87
|
+
"icon",
|
|
88
|
+
"variant",
|
|
89
|
+
"className"
|
|
90
|
+
]);
|
|
91
|
+
var isIconOnly = !label;
|
|
92
|
+
var classes = [
|
|
93
|
+
isIconOnly ? 'icon-button--icon-only' : 'icon-button',
|
|
94
|
+
variant === 'danger' ? 'icon-button--danger' : '',
|
|
95
|
+
className
|
|
96
|
+
].filter(Boolean).join(' ');
|
|
97
|
+
var iconSize = isIconOnly ? 32 : 16;
|
|
98
|
+
var renderIcon = function() {
|
|
99
|
+
if (icon === 'back') return ArrowLeftIcon({
|
|
100
|
+
width: iconSize,
|
|
101
|
+
height: iconSize
|
|
102
|
+
});
|
|
103
|
+
if (icon === 'add') return PlusIcon({
|
|
104
|
+
width: iconSize,
|
|
105
|
+
height: iconSize
|
|
106
|
+
});
|
|
107
|
+
if (icon === 'delete') return DeleteIcon({
|
|
108
|
+
width: iconSize,
|
|
109
|
+
height: iconSize
|
|
110
|
+
});
|
|
111
|
+
return icon;
|
|
112
|
+
};
|
|
113
|
+
if (isIconOnly) {
|
|
114
|
+
return /*#__PURE__*/ jsx("button", _object_spread_props(_object_spread({
|
|
115
|
+
type: "button",
|
|
116
|
+
className: classes
|
|
117
|
+
}, props), {
|
|
118
|
+
children: renderIcon()
|
|
119
|
+
}));
|
|
120
|
+
}
|
|
121
|
+
return /*#__PURE__*/ jsxs("button", _object_spread_props(_object_spread({
|
|
122
|
+
className: classes
|
|
123
|
+
}, props), {
|
|
124
|
+
children: [
|
|
125
|
+
/*#__PURE__*/ jsx("span", {
|
|
126
|
+
className: "icon-button__icon",
|
|
127
|
+
children: renderIcon()
|
|
128
|
+
}),
|
|
129
|
+
/*#__PURE__*/ jsx("span", {
|
|
130
|
+
className: "icon-button__label",
|
|
131
|
+
children: label
|
|
132
|
+
})
|
|
133
|
+
]
|
|
134
|
+
}));
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export { IconButton };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import styleInject from '/opt/atlassian/pipelines/agent/build/node_modules/style-inject/dist/style-inject.es.js';
|
|
2
|
+
|
|
3
|
+
var css_248z = ".icon-button{align-items:center;background:#0000;border:1px solid var(--border-primary);border-radius:8px;cursor:pointer;display:inline-flex;font-family:var(--font-family-sans,\"Geist\",sans-serif);gap:var(--spacing-sm,8px);height:36px;padding:0 16px 0 12px;transition:all .2s ease;width:fit-content}@media (max-width:768px){.icon-button{height:44px;padding:0 20px 0 16px}}.icon-button:hover{background:var(--surface-secondary)}.icon-button:hover,.icon-button:hover .icon-button__icon,.icon-button:hover .icon-button__label{color:var(--label-primary)}.icon-button:active{background:var(--surface-tertiary)}.icon-button__icon{align-items:center;color:var(--label-primary);display:flex}.icon-button__label{color:var(--label-primary);font-size:13px;font-weight:500;line-height:16px}.icon-button--icon-only{align-items:center;background:#0000;border:1px solid var(--border-primary);border-radius:8px;color:var(--label-primary);cursor:pointer;display:inline-flex;height:32px;justify-content:center;transition:all .2s ease;width:32px}.icon-button--icon-only:hover{background:var(--surface-primary,#fff)}.icon-button--icon-only:active{background:var(--surface-tertiary)}.icon-button--danger{color:var(--label-danger,#cc3c35)}.icon-button--danger:hover{background:var(--surface-primary,#fff)}";
|
|
4
|
+
styleInject(css_248z);
|
|
5
|
+
|
|
6
|
+
export { css_248z as default };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/IconButton/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AACzC,YAAY,EAAE,eAAe,EAAE,MAAM,cAAc,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NewInput.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/NewInput/NewInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAC,mBAAmB,EAAE,sBAAsB,EAAc,SAAS,EAAC,MAAM,OAAO,CAAC;AAChG,OAAO,iCAAiC,CAAC;AAEzC,KAAK,gBAAgB,GAAG;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAChC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"NewInput.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/NewInput/NewInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAC,mBAAmB,EAAE,sBAAsB,EAAc,SAAS,EAAC,MAAM,OAAO,CAAC;AAChG,OAAO,iCAAiC,CAAC;AAEzC,KAAK,gBAAgB,GAAG;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAChC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,OAAO,CAAC,EAAE,SAAS,GAAG,YAAY,CAAC;CACpC,CAAA;AAED,KAAK,UAAU,GAAG,gBAAgB,GAAG;IACnC,EAAE,CAAC,EAAE,OAAO,CAAC;CACd,GAAG,mBAAmB,CAAC,gBAAgB,CAAC,CAAA;AAEzC,KAAK,aAAa,GAAG,gBAAgB,GAAG;IACtC,EAAE,EAAE,UAAU,CAAC;CAChB,GAAG,sBAAsB,CAAC,mBAAmB,CAAC,CAAA;AAE/C,MAAM,MAAM,aAAa,GAAG,UAAU,GAAG,aAAa,CAAA;AAEtD,eAAO,MAAM,QAAQ,8GA8FpB,CAAC"}
|
|
@@ -58,7 +58,7 @@ function _object_without_properties_loose(source, excluded) {
|
|
|
58
58
|
return target;
|
|
59
59
|
}
|
|
60
60
|
var NewInput = /*#__PURE__*/ forwardRef(function(_param, ref) {
|
|
61
|
-
var label = _param.label, optional = _param.optional, helperText = _param.helperText, error = _param.error, icon = _param.icon, _param_iconPosition = _param.iconPosition, iconPosition = _param_iconPosition === void 0 ? 'left' : _param_iconPosition, _param_as = _param.as, as = _param_as === void 0 ? 'input' : _param_as; _param.required; var _param_className = _param.className, className = _param_className === void 0 ? '' : _param_className, onIconClick = _param.onIconClick, props = _object_without_properties(_param, [
|
|
61
|
+
var label = _param.label, optional = _param.optional, helperText = _param.helperText, error = _param.error, icon = _param.icon, _param_iconPosition = _param.iconPosition, iconPosition = _param_iconPosition === void 0 ? 'left' : _param_iconPosition, _param_as = _param.as, as = _param_as === void 0 ? 'input' : _param_as; _param.required; var variant = _param.variant, _param_className = _param.className, className = _param_className === void 0 ? '' : _param_className, onIconClick = _param.onIconClick, props = _object_without_properties(_param, [
|
|
62
62
|
"label",
|
|
63
63
|
"optional",
|
|
64
64
|
"helperText",
|
|
@@ -67,6 +67,7 @@ var NewInput = /*#__PURE__*/ forwardRef(function(_param, ref) {
|
|
|
67
67
|
"iconPosition",
|
|
68
68
|
"as",
|
|
69
69
|
"required",
|
|
70
|
+
"variant",
|
|
70
71
|
"className",
|
|
71
72
|
"onIconClick"
|
|
72
73
|
]);
|
|
@@ -76,6 +77,7 @@ var NewInput = /*#__PURE__*/ forwardRef(function(_param, ref) {
|
|
|
76
77
|
'new-form-input',
|
|
77
78
|
isError ? 'new-form-input--error' : '',
|
|
78
79
|
props.disabled ? 'new-form-input--disabled' : '',
|
|
80
|
+
variant === 'on-surface' ? 'new-form-input--on-surface' : '',
|
|
79
81
|
className
|
|
80
82
|
].filter(Boolean).join(' ');
|
|
81
83
|
// Merge refs
|
|
@@ -134,11 +136,12 @@ var NewInput = /*#__PURE__*/ forwardRef(function(_param, ref) {
|
|
|
134
136
|
(label || optional) && /*#__PURE__*/ jsxs("label", {
|
|
135
137
|
className: "new-form-input__label",
|
|
136
138
|
children: [
|
|
137
|
-
|
|
138
|
-
|
|
139
|
+
/*#__PURE__*/ jsx("span", {
|
|
140
|
+
children: label
|
|
141
|
+
}),
|
|
139
142
|
optional && /*#__PURE__*/ jsx("span", {
|
|
140
143
|
className: "new-form-input__label-optional",
|
|
141
|
-
children: "(
|
|
144
|
+
children: "(optional)"
|
|
142
145
|
})
|
|
143
146
|
]
|
|
144
147
|
}),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import styleInject from '/opt/atlassian/pipelines/agent/build/node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".new-page-header-container{align-items:flex-start;align-self:stretch;display:flex;flex-direction:column;gap:0;padding:32px 32px 0}@media (max-width:768px){.new-page-header-container{gap:0;padding:16px
|
|
3
|
+
var css_248z = ".new-page-header-container{align-items:flex-start;align-self:stretch;display:flex;flex-direction:column;gap:0;padding:32px 32px 0}@media (max-width:768px){.new-page-header-container{gap:0;padding:16px 0 0}}.new-page-header{align-items:center;align-self:stretch;display:flex;gap:16px;justify-content:space-between;width:100%}@media (max-width:768px){.new-page-header{gap:8px;padding-top:16px}}.new-page-header__title{color:var(--label-primary);font-family:var(--font-family-sans,\"Geist\",sans-serif);font-size:24px;font-style:normal;font-weight:600;line-height:28px;margin:0;padding:0}.new-page-header__actions{align-items:center;display:flex;flex-shrink:0;gap:16px}.new-page-header__divider{background-color:var(--border-primary,#e8e9ef);border:none;height:1px;width:100%}";
|
|
4
4
|
styleInject(css_248z);
|
|
5
5
|
|
|
6
6
|
export { css_248z as default };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import styleInject from '/opt/atlassian/pipelines/agent/build/node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".quick-filter{align-items:center;display:flex;gap:12px}.quick-filter__label{color:var(--label-secondary,#9399b3);font-size:var(--text-small-size,13px);font-weight:500;white-space:nowrap}.quick-filter__options{display:flex;flex-wrap:
|
|
3
|
+
var css_248z = ".quick-filter{align-items:center;display:flex;gap:12px}.quick-filter__label{color:var(--label-secondary,#9399b3);font-size:var(--text-small-size,13px);font-weight:500;white-space:nowrap}.quick-filter__options{-ms-overflow-style:none;display:flex;flex-wrap:nowrap;gap:8px;overflow-x:auto;padding-bottom:2px;scrollbar-width:none}.quick-filter__options::-webkit-scrollbar{display:none}.quick-filter__options .ghost-button{border-radius:100px;flex-shrink:0;font-family:var(--font-family-mono,\"Geist Mono\",monospace)}@media (max-width:768px){.quick-filter{align-items:center;display:flex;flex-direction:row;gap:12px;width:100%}.quick-filter__label{font-size:12px}.quick-filter__options{display:flex;flex:1;flex-wrap:nowrap;gap:6px;margin:0;min-width:0;overflow-x:auto;padding:0}.quick-filter__options .ghost-button{border-radius:100px;flex-shrink:0}}@media (max-width:480px){.quick-filter{gap:8px}.quick-filter__label{font-size:11px}.quick-filter__options{gap:4px}}";
|
|
4
4
|
styleInject(css_248z);
|
|
5
5
|
|
|
6
6
|
export { css_248z as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableSortIcon.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/TableSortIcon/TableSortIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,MAAM,MAAM,aAAa,GAAG,KAAK,GAAG,MAAM,GAAG,IAAI,CAAA;AAEjD,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,SAAS,EAAE,aAAa,CAAA;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,
|
|
1
|
+
{"version":3,"file":"TableSortIcon.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/TableSortIcon/TableSortIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,MAAM,MAAM,aAAa,GAAG,KAAK,GAAG,MAAM,GAAG,IAAI,CAAA;AAEjD,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,SAAS,EAAE,aAAa,CAAA;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAMtD,CAAA"}
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { TableHeaderArrowUpIcon, TableHeaderArrowDownIcon } from '../../icons/index.js';
|
|
4
4
|
|
|
5
5
|
var TableSortIcon = function(param) {
|
|
6
6
|
var _param_active = param.active, active = _param_active === void 0 ? false : _param_active, direction = param.direction, _param_className = param.className, className = _param_className === void 0 ? '' : _param_className;
|
|
7
|
-
if (!active || !direction) return null;
|
|
8
7
|
return /*#__PURE__*/ jsx("span", {
|
|
9
8
|
className: className,
|
|
10
|
-
|
|
9
|
+
style: {
|
|
10
|
+
visibility: active && direction ? 'visible' : 'hidden'
|
|
11
|
+
},
|
|
12
|
+
children: direction === 'asc' ? /*#__PURE__*/ jsx(TableHeaderArrowUpIcon, {}) : /*#__PURE__*/ jsx(TableHeaderArrowDownIcon, {})
|
|
11
13
|
});
|
|
12
14
|
};
|
|
13
15
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AddResourceButton.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/ZoneCard/AddResourceButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,MAAM,WAAW,sBAAsB;IACrC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,eAAO,MAAM,iBAAiB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CAU9D,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import 'react';
|
|
3
|
+
import { IconButton } from '../IconButton/IconButton.js';
|
|
4
|
+
|
|
5
|
+
var AddResourceButton = function(param) {
|
|
6
|
+
var _param_label = param.label, label = _param_label === void 0 ? 'Add Resource' : _param_label, onClick = param.onClick, _param_className = param.className, className = _param_className === void 0 ? '' : _param_className;
|
|
7
|
+
return /*#__PURE__*/ jsx("div", {
|
|
8
|
+
className: "zone-card__add-resource-wrapper ".concat(className),
|
|
9
|
+
children: /*#__PURE__*/ jsx(IconButton, {
|
|
10
|
+
label: label,
|
|
11
|
+
icon: "add",
|
|
12
|
+
onClick: onClick
|
|
13
|
+
})
|
|
14
|
+
});
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
export { AddResourceButton };
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ActionMenuItem } from '../ActionMenu';
|
|
3
|
+
import { DragHandleProps } from './ZoneContainer';
|
|
4
|
+
import './ZoneCard.scss';
|
|
5
|
+
export interface ResourceRowLabels {
|
|
6
|
+
quantity?: string;
|
|
7
|
+
capacity?: string;
|
|
8
|
+
total?: string;
|
|
9
|
+
}
|
|
10
|
+
export interface ResourceRowProps {
|
|
11
|
+
name: string;
|
|
12
|
+
quantity: number;
|
|
13
|
+
capacity: number;
|
|
14
|
+
labels?: ResourceRowLabels;
|
|
15
|
+
menuItems?: ActionMenuItem[];
|
|
16
|
+
draggable?: boolean;
|
|
17
|
+
dragHandleProps?: DragHandleProps;
|
|
18
|
+
onClick?: () => void;
|
|
19
|
+
className?: string;
|
|
20
|
+
style?: React.CSSProperties;
|
|
21
|
+
isMobile?: boolean;
|
|
22
|
+
isFirst?: boolean;
|
|
23
|
+
isLast?: boolean;
|
|
24
|
+
onMoveUp?: () => void;
|
|
25
|
+
onMoveDown?: () => void;
|
|
26
|
+
}
|
|
27
|
+
export declare const ResourceRow: React.ForwardRefExoticComponent<ResourceRowProps & React.RefAttributes<HTMLDivElement>>;
|
|
28
|
+
//# sourceMappingURL=ResourceRow.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ResourceRow.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/ZoneCard/ResourceRow.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAc,cAAc,EAAE,MAAM,eAAe,CAAA;AAE1D,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAA;AACjD,OAAO,iBAAiB,CAAA;AAExB,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,MAAM,CAAA;IAChB,QAAQ,EAAE,MAAM,CAAA;IAChB,MAAM,CAAC,EAAE,iBAAiB,CAAA;IAC1B,SAAS,CAAC,EAAE,cAAc,EAAE,CAAA;IAC5B,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,eAAe,CAAC,EAAE,eAAe,CAAA;IACjC,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAA;IAC3B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAA;IACrB,UAAU,CAAC,EAAE,MAAM,IAAI,CAAA;CACxB;AAED,eAAO,MAAM,WAAW,yFAkFtB,CAAA"}
|
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
2
|
+
import React__default from 'react';
|
|
3
|
+
import { ActionMenu } from '../ActionMenu/ActionMenu.js';
|
|
4
|
+
import { GripVerticalIcon, ArrowUpIcon, ArrowDownIcon } from '../../icons/index.js';
|
|
5
|
+
import './ZoneCard.scss.js';
|
|
6
|
+
|
|
7
|
+
function _define_property(obj, key, value) {
|
|
8
|
+
if (key in obj) {
|
|
9
|
+
Object.defineProperty(obj, key, {
|
|
10
|
+
value: value,
|
|
11
|
+
enumerable: true,
|
|
12
|
+
configurable: true,
|
|
13
|
+
writable: true
|
|
14
|
+
});
|
|
15
|
+
} else {
|
|
16
|
+
obj[key] = value;
|
|
17
|
+
}
|
|
18
|
+
return obj;
|
|
19
|
+
}
|
|
20
|
+
function _object_spread(target) {
|
|
21
|
+
for(var i = 1; i < arguments.length; i++){
|
|
22
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
23
|
+
var ownKeys = Object.keys(source);
|
|
24
|
+
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
25
|
+
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
26
|
+
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
27
|
+
}));
|
|
28
|
+
}
|
|
29
|
+
ownKeys.forEach(function(key) {
|
|
30
|
+
_define_property(target, key, source[key]);
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
return target;
|
|
34
|
+
}
|
|
35
|
+
function ownKeys(object, enumerableOnly) {
|
|
36
|
+
var keys = Object.keys(object);
|
|
37
|
+
if (Object.getOwnPropertySymbols) {
|
|
38
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
|
39
|
+
if (enumerableOnly) {
|
|
40
|
+
symbols = symbols.filter(function(sym) {
|
|
41
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
keys.push.apply(keys, symbols);
|
|
45
|
+
}
|
|
46
|
+
return keys;
|
|
47
|
+
}
|
|
48
|
+
function _object_spread_props(target, source) {
|
|
49
|
+
source = source != null ? source : {};
|
|
50
|
+
if (Object.getOwnPropertyDescriptors) {
|
|
51
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
52
|
+
} else {
|
|
53
|
+
ownKeys(Object(source)).forEach(function(key) {
|
|
54
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
return target;
|
|
58
|
+
}
|
|
59
|
+
var ResourceRow = /*#__PURE__*/ React__default.forwardRef(function(param, ref) {
|
|
60
|
+
var name = param.name, quantity = param.quantity, capacity = param.capacity, _param_labels = param.labels, labels = _param_labels === void 0 ? {} : _param_labels, _param_menuItems = param.menuItems, menuItems = _param_menuItems === void 0 ? [] : _param_menuItems, _param_draggable = param.draggable, draggable = _param_draggable === void 0 ? true : _param_draggable, dragHandleProps = param.dragHandleProps, onClick = param.onClick, _param_className = param.className, className = _param_className === void 0 ? '' : _param_className, style = param.style, _param_isMobile = param.isMobile, isMobile = _param_isMobile === void 0 ? false : _param_isMobile, _param_isFirst = param.isFirst, isFirst = _param_isFirst === void 0 ? false : _param_isFirst, _param_isLast = param.isLast, isLast = _param_isLast === void 0 ? false : _param_isLast, onMoveUp = param.onMoveUp, onMoveDown = param.onMoveDown;
|
|
61
|
+
var _labels_quantity;
|
|
62
|
+
var qtyLabel = (_labels_quantity = labels.quantity) !== null && _labels_quantity !== void 0 ? _labels_quantity : 'Qty';
|
|
63
|
+
var _labels_capacity;
|
|
64
|
+
var capLabel = (_labels_capacity = labels.capacity) !== null && _labels_capacity !== void 0 ? _labels_capacity : 'Cap';
|
|
65
|
+
var _labels_total;
|
|
66
|
+
var totalLabel = (_labels_total = labels.total) !== null && _labels_total !== void 0 ? _labels_total : 'Total';
|
|
67
|
+
var classes = [
|
|
68
|
+
'zone-card__resource',
|
|
69
|
+
onClick ? 'zone-card__resource--clickable' : '',
|
|
70
|
+
isMobile ? 'zone-card__resource--mobile' : '',
|
|
71
|
+
className
|
|
72
|
+
].filter(Boolean).join(' ');
|
|
73
|
+
return /*#__PURE__*/ jsxs("div", {
|
|
74
|
+
ref: ref,
|
|
75
|
+
className: classes,
|
|
76
|
+
style: style,
|
|
77
|
+
onClick: onClick,
|
|
78
|
+
children: [
|
|
79
|
+
draggable && !isMobile && /*#__PURE__*/ jsx("div", _object_spread_props(_object_spread({
|
|
80
|
+
className: "zone-card__drag-handle zone-card__drag-handle--resource"
|
|
81
|
+
}, dragHandleProps), {
|
|
82
|
+
onClick: function(e) {
|
|
83
|
+
return e.stopPropagation();
|
|
84
|
+
},
|
|
85
|
+
children: GripVerticalIcon({
|
|
86
|
+
width: 16,
|
|
87
|
+
height: 16
|
|
88
|
+
})
|
|
89
|
+
})),
|
|
90
|
+
draggable && isMobile && /*#__PURE__*/ jsxs("div", {
|
|
91
|
+
className: "zone-card__reorder-arrows zone-card__reorder-arrows--resource",
|
|
92
|
+
onClick: function(e) {
|
|
93
|
+
return e.stopPropagation();
|
|
94
|
+
},
|
|
95
|
+
children: [
|
|
96
|
+
/*#__PURE__*/ jsx("button", {
|
|
97
|
+
className: "zone-card__arrow-btn",
|
|
98
|
+
disabled: isFirst,
|
|
99
|
+
onClick: function(e) {
|
|
100
|
+
e.stopPropagation();
|
|
101
|
+
onMoveUp === null || onMoveUp === void 0 ? void 0 : onMoveUp();
|
|
102
|
+
},
|
|
103
|
+
children: /*#__PURE__*/ jsx(ArrowUpIcon, {})
|
|
104
|
+
}),
|
|
105
|
+
/*#__PURE__*/ jsx("button", {
|
|
106
|
+
className: "zone-card__arrow-btn",
|
|
107
|
+
disabled: isLast,
|
|
108
|
+
onClick: function(e) {
|
|
109
|
+
e.stopPropagation();
|
|
110
|
+
onMoveDown === null || onMoveDown === void 0 ? void 0 : onMoveDown();
|
|
111
|
+
},
|
|
112
|
+
children: /*#__PURE__*/ jsx(ArrowDownIcon, {})
|
|
113
|
+
})
|
|
114
|
+
]
|
|
115
|
+
}),
|
|
116
|
+
isMobile ? /*#__PURE__*/ jsxs("div", {
|
|
117
|
+
className: "zone-card__resource-info",
|
|
118
|
+
children: [
|
|
119
|
+
/*#__PURE__*/ jsx("span", {
|
|
120
|
+
className: "zone-card__resource-name",
|
|
121
|
+
children: name
|
|
122
|
+
}),
|
|
123
|
+
/*#__PURE__*/ jsxs("span", {
|
|
124
|
+
className: "zone-card__resource-stats-mobile",
|
|
125
|
+
children: [
|
|
126
|
+
qtyLabel,
|
|
127
|
+
": ",
|
|
128
|
+
quantity,
|
|
129
|
+
" \xb7 ",
|
|
130
|
+
capLabel,
|
|
131
|
+
": ",
|
|
132
|
+
capacity,
|
|
133
|
+
" \xb7 ",
|
|
134
|
+
totalLabel,
|
|
135
|
+
": ",
|
|
136
|
+
quantity * capacity
|
|
137
|
+
]
|
|
138
|
+
})
|
|
139
|
+
]
|
|
140
|
+
}) : /*#__PURE__*/ jsxs(Fragment, {
|
|
141
|
+
children: [
|
|
142
|
+
/*#__PURE__*/ jsx("span", {
|
|
143
|
+
className: "zone-card__resource-name",
|
|
144
|
+
children: name
|
|
145
|
+
}),
|
|
146
|
+
/*#__PURE__*/ jsxs("div", {
|
|
147
|
+
className: "zone-card__resource-stats",
|
|
148
|
+
children: [
|
|
149
|
+
/*#__PURE__*/ jsxs("span", {
|
|
150
|
+
className: "zone-card__resource-stat",
|
|
151
|
+
children: [
|
|
152
|
+
qtyLabel,
|
|
153
|
+
": ",
|
|
154
|
+
quantity
|
|
155
|
+
]
|
|
156
|
+
}),
|
|
157
|
+
/*#__PURE__*/ jsxs("span", {
|
|
158
|
+
className: "zone-card__resource-stat",
|
|
159
|
+
children: [
|
|
160
|
+
capLabel,
|
|
161
|
+
": ",
|
|
162
|
+
capacity
|
|
163
|
+
]
|
|
164
|
+
}),
|
|
165
|
+
/*#__PURE__*/ jsxs("span", {
|
|
166
|
+
className: "zone-card__resource-stat zone-card__resource-stat--total",
|
|
167
|
+
children: [
|
|
168
|
+
totalLabel,
|
|
169
|
+
": ",
|
|
170
|
+
quantity * capacity
|
|
171
|
+
]
|
|
172
|
+
})
|
|
173
|
+
]
|
|
174
|
+
})
|
|
175
|
+
]
|
|
176
|
+
}),
|
|
177
|
+
menuItems.length > 0 && /*#__PURE__*/ jsx("div", {
|
|
178
|
+
className: "zone-card__resource-actions",
|
|
179
|
+
onClick: function(e) {
|
|
180
|
+
return e.stopPropagation();
|
|
181
|
+
},
|
|
182
|
+
children: /*#__PURE__*/ jsx(ActionMenu, {
|
|
183
|
+
items: menuItems
|
|
184
|
+
})
|
|
185
|
+
})
|
|
186
|
+
]
|
|
187
|
+
});
|
|
188
|
+
});
|
|
189
|
+
ResourceRow.displayName = 'ResourceRow';
|
|
190
|
+
|
|
191
|
+
export { ResourceRow };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ActionMenuItem } from '../ActionMenu';
|
|
3
|
+
import { DragHandleProps } from './ZoneContainer';
|
|
4
|
+
export interface ZoneResource {
|
|
5
|
+
id: string;
|
|
6
|
+
name: string;
|
|
7
|
+
quantity: number;
|
|
8
|
+
capacity: number;
|
|
9
|
+
menuItems?: ActionMenuItem[];
|
|
10
|
+
dragHandleProps?: DragHandleProps;
|
|
11
|
+
}
|
|
12
|
+
export interface ZoneCardProps {
|
|
13
|
+
name: string;
|
|
14
|
+
totalCapacity: number;
|
|
15
|
+
resources?: ZoneResource[];
|
|
16
|
+
menuItems?: ActionMenuItem[];
|
|
17
|
+
onAddResource?: () => void;
|
|
18
|
+
className?: string;
|
|
19
|
+
draggable?: boolean;
|
|
20
|
+
onResourceClick?: (resource: ZoneResource) => void;
|
|
21
|
+
dragHandleProps?: DragHandleProps;
|
|
22
|
+
style?: React.CSSProperties;
|
|
23
|
+
}
|
|
24
|
+
export declare const ZoneCard: React.ForwardRefExoticComponent<ZoneCardProps & React.RefAttributes<HTMLDivElement>>;
|
|
25
|
+
//# sourceMappingURL=ZoneCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZoneCard.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/ZoneCard/ZoneCard.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAA;AAK9C,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAA;AAEjD,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,MAAM,CAAA;IAChB,QAAQ,EAAE,MAAM,CAAA;IAChB,SAAS,CAAC,EAAE,cAAc,EAAE,CAAA;IAC5B,eAAe,CAAC,EAAE,eAAe,CAAA;CAClC;AAED,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAA;IACZ,aAAa,EAAE,MAAM,CAAA;IACrB,SAAS,CAAC,EAAE,YAAY,EAAE,CAAA;IAC1B,SAAS,CAAC,EAAE,cAAc,EAAE,CAAA;IAC5B,aAAa,CAAC,EAAE,MAAM,IAAI,CAAA;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,eAAe,CAAC,EAAE,CAAC,QAAQ,EAAE,YAAY,KAAK,IAAI,CAAA;IAClD,eAAe,CAAC,EAAE,eAAe,CAAA;IACjC,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAA;CAC5B;AAED,eAAO,MAAM,QAAQ,sFAoCnB,CAAA"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
+
import React__default from 'react';
|
|
3
|
+
import { ZoneContainer } from './ZoneContainer.js';
|
|
4
|
+
import { ZoneHeader } from './ZoneHeader.js';
|
|
5
|
+
import { ResourceRow } from './ResourceRow.js';
|
|
6
|
+
import { AddResourceButton } from './AddResourceButton.js';
|
|
7
|
+
|
|
8
|
+
var ZoneCard = /*#__PURE__*/ React__default.forwardRef(function(param, ref) {
|
|
9
|
+
var name = param.name, totalCapacity = param.totalCapacity, _param_resources = param.resources, resources = _param_resources === void 0 ? [] : _param_resources, _param_menuItems = param.menuItems, menuItems = _param_menuItems === void 0 ? [] : _param_menuItems, onAddResource = param.onAddResource, _param_className = param.className, className = _param_className === void 0 ? '' : _param_className, _param_draggable = param.draggable, draggable = _param_draggable === void 0 ? true : _param_draggable, onResourceClick = param.onResourceClick, dragHandleProps = param.dragHandleProps, style = param.style;
|
|
10
|
+
return /*#__PURE__*/ jsxs(ZoneContainer, {
|
|
11
|
+
ref: ref,
|
|
12
|
+
className: className,
|
|
13
|
+
style: style,
|
|
14
|
+
children: [
|
|
15
|
+
/*#__PURE__*/ jsx(ZoneHeader, {
|
|
16
|
+
name: name,
|
|
17
|
+
totalCapacity: totalCapacity,
|
|
18
|
+
menuItems: menuItems,
|
|
19
|
+
draggable: draggable,
|
|
20
|
+
dragHandleProps: dragHandleProps
|
|
21
|
+
}),
|
|
22
|
+
resources.map(function(resource) {
|
|
23
|
+
return /*#__PURE__*/ jsx(ResourceRow, {
|
|
24
|
+
name: resource.name,
|
|
25
|
+
quantity: resource.quantity,
|
|
26
|
+
capacity: resource.capacity,
|
|
27
|
+
menuItems: resource.menuItems,
|
|
28
|
+
draggable: draggable,
|
|
29
|
+
dragHandleProps: resource.dragHandleProps,
|
|
30
|
+
onClick: onResourceClick ? function() {
|
|
31
|
+
return onResourceClick(resource);
|
|
32
|
+
} : undefined
|
|
33
|
+
}, resource.id);
|
|
34
|
+
}),
|
|
35
|
+
onAddResource && /*#__PURE__*/ jsx(AddResourceButton, {
|
|
36
|
+
onClick: onAddResource
|
|
37
|
+
})
|
|
38
|
+
]
|
|
39
|
+
});
|
|
40
|
+
});
|
|
41
|
+
ZoneCard.displayName = 'ZoneCard';
|
|
42
|
+
|
|
43
|
+
export { ZoneCard };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import styleInject from '/opt/atlassian/pipelines/agent/build/node_modules/style-inject/dist/style-inject.es.js';
|
|
2
|
+
|
|
3
|
+
var css_248z = ".zone-card{background:var(--surface-primary);border:1px solid var(--border-primary);border-radius:8px;overflow:visible}.zone-card__header{align-items:center;background:var(--surface-secondary);display:flex;gap:16px;padding:12px 16px}.zone-card__drag-handle{align-items:center;border-radius:6px;color:var(--label-tertiary,var(--label-secondary));cursor:grab;display:flex;flex-shrink:0;padding:6px;transition:all .2s ease}.zone-card__drag-handle:hover{background:var(--surface-primary);color:var(--label-secondary)}.zone-card__drag-handle:active{cursor:grabbing}.zone-card__drag-handle--resource{color:var(--label-tertiary,var(--label-secondary))}.zone-card__reorder-arrows{display:flex;flex-direction:column;flex-shrink:0;gap:2px}.zone-card__reorder-arrows--resource{margin-right:0}.zone-card__arrow-btn{align-items:center;background:#0000;border:none;border-radius:4px;color:var(--label-tertiary,var(--label-secondary));cursor:pointer;display:flex;height:28px;justify-content:center;padding:0;transition:all .2s ease;width:28px}.zone-card__arrow-btn:hover:not(:disabled){background:var(--surface-primary);color:var(--label-secondary)}.zone-card__arrow-btn:disabled{opacity:.25;pointer-events:none}.zone-card__name{color:var(--label-primary);flex:1;font-family:var(--font-family-sans,\"Geist\",sans-serif);font-size:15px;font-weight:600;line-height:20px;min-width:0}.zone-card__header-info{display:flex;flex:1;flex-direction:column;gap:2px;min-width:0}.zone-card__header-info .zone-card__total{min-width:auto;text-align:left}.zone-card__header-right{align-items:center;display:flex;flex-shrink:0;gap:16px}.zone-card__total{color:var(--label-secondary);font-family:var(--font-family-sans,\"Geist\",sans-serif);font-size:13px;font-weight:400;line-height:16px;min-width:72px;text-align:right;white-space:nowrap}.zone-card__resource{align-items:center;border-top:1px solid var(--border-primary);display:flex;gap:16px;padding:10px 16px 10px 32px;transition:background .2s ease}.zone-card__resource--clickable{cursor:pointer}.zone-card__resource--clickable:hover{background:var(--surface-secondary)}.zone-card__resource--mobile{padding-left:16px}.zone-card__resource-name{color:var(--label-primary);flex:1;font-family:var(--font-family-sans,\"Geist\",sans-serif);font-size:15px;font-weight:400;line-height:20px;min-width:0}.zone-card__resource-stats{align-items:center;display:flex;flex-shrink:0;gap:32px}.zone-card__resource-stat{color:var(--label-secondary);font-family:var(--font-family-sans,\"Geist\",sans-serif);font-size:13px;font-weight:400;line-height:16px;min-width:72px;white-space:nowrap}.zone-card__resource-stat--total{min-width:72px;text-align:right}.zone-card__resource-info{display:flex;flex:1;flex-direction:column;gap:2px;min-width:0}.zone-card__resource-stats-mobile{color:var(--label-secondary);font-family:var(--font-family-sans,\"Geist\",sans-serif);font-size:12px;font-weight:400;line-height:16px;white-space:nowrap}.zone-card__resource-actions{display:flex;flex-shrink:0;justify-content:flex-end;width:32px}.zone-card__add-resource-wrapper{border-top:1px solid var(--border-primary);padding:12px 16px}@media (max-width:768px){.zone-card__header{padding:10px 12px}.zone-card__resource{gap:12px;padding:10px 12px}.zone-card__resource-stats{gap:16px}.zone-card__resource-stat{min-width:auto}.zone-card__add-resource-wrapper{padding:10px 12px}}";
|
|
4
|
+
styleInject(css_248z);
|
|
5
|
+
|
|
6
|
+
export { css_248z as default };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './ZoneCard.scss';
|
|
3
|
+
export interface DragHandleProps {
|
|
4
|
+
[key: string]: unknown;
|
|
5
|
+
}
|
|
6
|
+
export interface ZoneContainerProps {
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
className?: string;
|
|
9
|
+
style?: React.CSSProperties;
|
|
10
|
+
}
|
|
11
|
+
export declare const ZoneContainer: React.ForwardRefExoticComponent<ZoneContainerProps & React.RefAttributes<HTMLDivElement>>;
|
|
12
|
+
//# sourceMappingURL=ZoneContainer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZoneContainer.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/ZoneCard/ZoneContainer.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,iBAAiB,CAAA;AAExB,MAAM,WAAW,eAAe;IAC9B,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;CACvB;AAED,MAAM,WAAW,kBAAkB;IACjC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,KAAK,CAAC,aAAa,CAAA;CAC5B;AAED,eAAO,MAAM,aAAa,2FAUxB,CAAA"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import React__default from 'react';
|
|
3
|
+
import './ZoneCard.scss.js';
|
|
4
|
+
|
|
5
|
+
var ZoneContainer = /*#__PURE__*/ React__default.forwardRef(function(param, ref) {
|
|
6
|
+
var children = param.children, _param_className = param.className, className = _param_className === void 0 ? '' : _param_className, style = param.style;
|
|
7
|
+
return /*#__PURE__*/ jsx("div", {
|
|
8
|
+
ref: ref,
|
|
9
|
+
className: "zone-card ".concat(className),
|
|
10
|
+
style: style,
|
|
11
|
+
children: children
|
|
12
|
+
});
|
|
13
|
+
});
|
|
14
|
+
ZoneContainer.displayName = 'ZoneContainer';
|
|
15
|
+
|
|
16
|
+
export { ZoneContainer };
|