@cumulus-ui/components 0.4.0 → 0.5.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/dist/annotation-context/index.d.ts +6 -0
- package/dist/annotation-context/index.d.ts.map +1 -0
- package/dist/annotation-context/internal.d.ts +26 -0
- package/dist/annotation-context/internal.d.ts.map +1 -0
- package/dist/code-editor/index.d.ts +5 -0
- package/dist/code-editor/index.d.ts.map +1 -0
- package/dist/code-editor/internal.d.ts +33 -0
- package/dist/code-editor/internal.d.ts.map +1 -0
- package/dist/code-editor/styles.d.ts +5 -0
- package/dist/code-editor/styles.d.ts.map +1 -0
- package/dist/container/internal.d.ts.map +1 -1
- package/dist/copy-to-clipboard/internal.d.ts.map +1 -1
- package/dist/drawer/index.d.ts +5 -0
- package/dist/drawer/index.d.ts.map +1 -0
- package/dist/drawer/internal.d.ts +15 -0
- package/dist/drawer/internal.d.ts.map +1 -0
- package/dist/drawer/styles.d.ts +5 -0
- package/dist/drawer/styles.d.ts.map +1 -0
- package/dist/error-boundary/internal.d.ts.map +1 -1
- package/dist/header/internal.d.ts.map +1 -1
- package/dist/help-panel/index.d.ts +5 -0
- package/dist/help-panel/index.d.ts.map +1 -0
- package/dist/help-panel/internal.d.ts +10 -0
- package/dist/help-panel/internal.d.ts.map +1 -0
- package/dist/help-panel/styles.d.ts +5 -0
- package/dist/help-panel/styles.d.ts.map +1 -0
- package/dist/hotspot/index.d.ts +5 -0
- package/dist/hotspot/index.d.ts.map +1 -0
- package/dist/hotspot/internal.d.ts +22 -0
- package/dist/hotspot/internal.d.ts.map +1 -0
- package/dist/hotspot/styles.d.ts +5 -0
- package/dist/hotspot/styles.d.ts.map +1 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3473 -170
- package/dist/input/internal.d.ts.map +1 -1
- package/dist/internal/styles/code-editor-resizable-box.d.ts +2 -0
- package/dist/internal/styles/code-editor-resizable-box.d.ts.map +1 -0
- package/dist/internal/styles/split-panel-icons.d.ts +2 -0
- package/dist/internal/styles/split-panel-icons.d.ts.map +1 -0
- package/dist/key-value-pairs/internal.d.ts.map +1 -1
- package/dist/list/internal.d.ts.map +1 -1
- package/dist/progress-bar/internal.d.ts.map +1 -1
- package/dist/prompt-input/internal.d.ts +2 -0
- package/dist/prompt-input/internal.d.ts.map +1 -1
- package/dist/side-navigation/index.d.ts +5 -0
- package/dist/side-navigation/index.d.ts.map +1 -0
- package/dist/side-navigation/internal.d.ts +29 -0
- package/dist/side-navigation/internal.d.ts.map +1 -0
- package/dist/side-navigation/styles.d.ts +5 -0
- package/dist/side-navigation/styles.d.ts.map +1 -0
- package/dist/split-panel/index.d.ts +5 -0
- package/dist/split-panel/index.d.ts.map +1 -0
- package/dist/split-panel/internal.d.ts +22 -0
- package/dist/split-panel/internal.d.ts.map +1 -0
- package/dist/split-panel/styles.d.ts +5 -0
- package/dist/split-panel/styles.d.ts.map +1 -0
- package/dist/steps/internal.d.ts.map +1 -1
- package/dist/table/internal.d.ts.map +1 -1
- package/dist/tabs/internal.d.ts.map +1 -1
- package/dist/token/internal.d.ts.map +1 -1
- package/dist/token-group/internal.d.ts.map +1 -1
- package/dist/top-navigation/index.d.ts +5 -0
- package/dist/top-navigation/index.d.ts.map +1 -0
- package/dist/top-navigation/internal.d.ts +19 -0
- package/dist/top-navigation/internal.d.ts.map +1 -0
- package/dist/top-navigation/styles.d.ts +5 -0
- package/dist/top-navigation/styles.d.ts.map +1 -0
- package/dist/tree-view/internal.d.ts.map +1 -1
- package/dist/tutorial-panel/index.d.ts +5 -0
- package/dist/tutorial-panel/index.d.ts.map +1 -0
- package/dist/tutorial-panel/internal.d.ts +28 -0
- package/dist/tutorial-panel/internal.d.ts.map +1 -0
- package/dist/tutorial-panel/styles.d.ts +5 -0
- package/dist/tutorial-panel/styles.d.ts.map +1 -0
- package/dist/wizard/index.d.ts +5 -0
- package/dist/wizard/index.d.ts.map +1 -0
- package/dist/wizard/internal.d.ts +32 -0
- package/dist/wizard/internal.d.ts.map +1 -0
- package/dist/wizard/styles.d.ts +5 -0
- package/dist/wizard/styles.d.ts.map +1 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -64,8 +64,8 @@ function FormAssociatedMixin(superClass) {
|
|
|
64
64
|
this._defaultValue = this.value;
|
|
65
65
|
}
|
|
66
66
|
// ── Public API (thin wrappers around ElementInternals) ────────────
|
|
67
|
-
setFormValue(value,
|
|
68
|
-
this._internals.setFormValue(value,
|
|
67
|
+
setFormValue(value, state23) {
|
|
68
|
+
this._internals.setFormValue(value, state23);
|
|
69
69
|
}
|
|
70
70
|
setValidity(flags, message, anchor) {
|
|
71
71
|
if (flags && message) {
|
|
@@ -99,9 +99,9 @@ function FormAssociatedMixin(superClass) {
|
|
|
99
99
|
* @param state - Previously saved value or `FormData` entry.
|
|
100
100
|
* @param _mode - `'restore'` (bfcache) or `'autocomplete'`.
|
|
101
101
|
*/
|
|
102
|
-
formStateRestoreCallback(
|
|
103
|
-
if (typeof
|
|
104
|
-
this.value =
|
|
102
|
+
formStateRestoreCallback(state23, _mode) {
|
|
103
|
+
if (typeof state23 === "string") {
|
|
104
|
+
this.value = state23;
|
|
105
105
|
}
|
|
106
106
|
}
|
|
107
107
|
}
|
|
@@ -1254,7 +1254,7 @@ var CsButtonInternal = class extends Base {
|
|
|
1254
1254
|
role="button"
|
|
1255
1255
|
>
|
|
1256
1256
|
${this._renderIcon("left")}
|
|
1257
|
-
<slot></slot>
|
|
1257
|
+
<span class="content"><slot></slot></span>
|
|
1258
1258
|
${this._renderIcon("right")}
|
|
1259
1259
|
${this._renderExternalIcon()}
|
|
1260
1260
|
</a>
|
|
@@ -1274,7 +1274,7 @@ var CsButtonInternal = class extends Base {
|
|
|
1274
1274
|
form=${ifDefined2(this.form)}
|
|
1275
1275
|
>
|
|
1276
1276
|
${this._renderIcon("left")}
|
|
1277
|
-
|
|
1277
|
+
<span class="content">${this.loading && this.loadingText ? html3`<span>${this.loadingText}</span>` : html3`<slot></slot>`}</span>
|
|
1278
1278
|
${this._renderIcon("right")}
|
|
1279
1279
|
</button>
|
|
1280
1280
|
`;
|
|
@@ -3053,6 +3053,19 @@ var structuredItemStyles = css22`
|
|
|
3053
3053
|
|
|
3054
3054
|
// src/list/internal.ts
|
|
3055
3055
|
var hostStyles9 = css23`:host { display: block; }`;
|
|
3056
|
+
var inventedStyles = css23`
|
|
3057
|
+
.structured-item--icon {
|
|
3058
|
+
display: flex;
|
|
3059
|
+
align-items: center;
|
|
3060
|
+
margin-inline-end: var(--space-xs-ymlm0b, 8px);
|
|
3061
|
+
flex-shrink: 0;
|
|
3062
|
+
}
|
|
3063
|
+
.structured-item--secondary {
|
|
3064
|
+
color: var(--color-text-body-secondary-fdstdf, #5f6b7a);
|
|
3065
|
+
font-size: var(--font-body-s-size-ukbcbk, 12px);
|
|
3066
|
+
line-height: var(--line-height-body-s-2vlpm2, 16px);
|
|
3067
|
+
}
|
|
3068
|
+
`;
|
|
3056
3069
|
var CsListInternal = class extends CsBaseElement {
|
|
3057
3070
|
constructor() {
|
|
3058
3071
|
super(...arguments);
|
|
@@ -3066,7 +3079,7 @@ var CsListInternal = class extends CsBaseElement {
|
|
|
3066
3079
|
this.disablePaddings = false;
|
|
3067
3080
|
}
|
|
3068
3081
|
static {
|
|
3069
|
-
this.styles = [sharedStyles, componentStyles9, structuredItemStyles, hostStyles9];
|
|
3082
|
+
this.styles = [sharedStyles, componentStyles9, structuredItemStyles, hostStyles9, inventedStyles];
|
|
3070
3083
|
}
|
|
3071
3084
|
_renderListItem(rendered) {
|
|
3072
3085
|
const itemClasses = {
|
|
@@ -3385,6 +3398,16 @@ var treeViewVerticalConnectorStyles = css27`
|
|
|
3385
3398
|
|
|
3386
3399
|
// src/tree-view/internal.ts
|
|
3387
3400
|
var hostStyles10 = css28`:host { display: block; }`;
|
|
3401
|
+
var inventedStyles2 = css28`
|
|
3402
|
+
.expandable {}
|
|
3403
|
+
.expanded {}
|
|
3404
|
+
.structured-item--icon {
|
|
3405
|
+
display: flex;
|
|
3406
|
+
align-items: center;
|
|
3407
|
+
margin-inline-end: var(--space-xs-ymlm0b, 8px);
|
|
3408
|
+
flex-shrink: 0;
|
|
3409
|
+
}
|
|
3410
|
+
`;
|
|
3388
3411
|
var CsTreeViewInternal = class extends CsBaseElement {
|
|
3389
3412
|
constructor() {
|
|
3390
3413
|
super(...arguments);
|
|
@@ -3395,7 +3418,7 @@ var CsTreeViewInternal = class extends CsBaseElement {
|
|
|
3395
3418
|
this._expandedSet = /* @__PURE__ */ new Set();
|
|
3396
3419
|
}
|
|
3397
3420
|
static {
|
|
3398
|
-
this.styles = [sharedStyles, componentStyles10, treeViewTreeItemStyles, expandToggleButtonStyles, treeViewVerticalConnectorStyles, structuredItemStyles, hostStyles10];
|
|
3421
|
+
this.styles = [sharedStyles, componentStyles10, treeViewTreeItemStyles, expandToggleButtonStyles, treeViewVerticalConnectorStyles, structuredItemStyles, hostStyles10, inventedStyles2];
|
|
3399
3422
|
}
|
|
3400
3423
|
willUpdate(changed) {
|
|
3401
3424
|
if (changed.has("expandedItems")) {
|
|
@@ -6096,7 +6119,7 @@ function computeCoordsFromPlacement(_ref, placement, rtl) {
|
|
|
6096
6119
|
}
|
|
6097
6120
|
return coords;
|
|
6098
6121
|
}
|
|
6099
|
-
async function detectOverflow(
|
|
6122
|
+
async function detectOverflow(state23, options) {
|
|
6100
6123
|
var _await$platform$isEle;
|
|
6101
6124
|
if (options === void 0) {
|
|
6102
6125
|
options = {};
|
|
@@ -6108,14 +6131,14 @@ async function detectOverflow(state21, options) {
|
|
|
6108
6131
|
rects,
|
|
6109
6132
|
elements,
|
|
6110
6133
|
strategy
|
|
6111
|
-
} =
|
|
6134
|
+
} = state23;
|
|
6112
6135
|
const {
|
|
6113
6136
|
boundary = "clippingAncestors",
|
|
6114
6137
|
rootBoundary = "viewport",
|
|
6115
6138
|
elementContext = "floating",
|
|
6116
6139
|
altBoundary = false,
|
|
6117
6140
|
padding = 0
|
|
6118
|
-
} = evaluate(options,
|
|
6141
|
+
} = evaluate(options, state23);
|
|
6119
6142
|
const paddingObject = getPaddingObject(padding);
|
|
6120
6143
|
const altContext = elementContext === "floating" ? "reference" : "floating";
|
|
6121
6144
|
const element = elements[altBoundary ? altContext : elementContext];
|
|
@@ -6247,7 +6270,7 @@ var flip = function(options) {
|
|
|
6247
6270
|
return {
|
|
6248
6271
|
name: "flip",
|
|
6249
6272
|
options,
|
|
6250
|
-
async fn(
|
|
6273
|
+
async fn(state23) {
|
|
6251
6274
|
var _middlewareData$arrow, _middlewareData$flip;
|
|
6252
6275
|
const {
|
|
6253
6276
|
placement,
|
|
@@ -6256,7 +6279,7 @@ var flip = function(options) {
|
|
|
6256
6279
|
initialPlacement,
|
|
6257
6280
|
platform: platform2,
|
|
6258
6281
|
elements
|
|
6259
|
-
} =
|
|
6282
|
+
} = state23;
|
|
6260
6283
|
const {
|
|
6261
6284
|
mainAxis: checkMainAxis = true,
|
|
6262
6285
|
crossAxis: checkCrossAxis = true,
|
|
@@ -6265,7 +6288,7 @@ var flip = function(options) {
|
|
|
6265
6288
|
fallbackAxisSideDirection = "none",
|
|
6266
6289
|
flipAlignment = true,
|
|
6267
6290
|
...detectOverflowOptions
|
|
6268
|
-
} = evaluate(options,
|
|
6291
|
+
} = evaluate(options, state23);
|
|
6269
6292
|
if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
|
|
6270
6293
|
return {};
|
|
6271
6294
|
}
|
|
@@ -6279,7 +6302,7 @@ var flip = function(options) {
|
|
|
6279
6302
|
fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
|
|
6280
6303
|
}
|
|
6281
6304
|
const placements2 = [initialPlacement, ...fallbackPlacements];
|
|
6282
|
-
const overflow = await platform2.detectOverflow(
|
|
6305
|
+
const overflow = await platform2.detectOverflow(state23, detectOverflowOptions);
|
|
6283
6306
|
const overflows = [];
|
|
6284
6307
|
let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
|
|
6285
6308
|
if (checkMainAxis) {
|
|
@@ -6350,19 +6373,19 @@ var flip = function(options) {
|
|
|
6350
6373
|
};
|
|
6351
6374
|
};
|
|
6352
6375
|
var originSides = /* @__PURE__ */ new Set(["left", "top"]);
|
|
6353
|
-
async function convertValueToCoords(
|
|
6376
|
+
async function convertValueToCoords(state23, options) {
|
|
6354
6377
|
const {
|
|
6355
6378
|
placement,
|
|
6356
6379
|
platform: platform2,
|
|
6357
6380
|
elements
|
|
6358
|
-
} =
|
|
6381
|
+
} = state23;
|
|
6359
6382
|
const rtl = await (platform2.isRTL == null ? void 0 : platform2.isRTL(elements.floating));
|
|
6360
6383
|
const side = getSide(placement);
|
|
6361
6384
|
const alignment = getAlignment(placement);
|
|
6362
6385
|
const isVertical = getSideAxis(placement) === "y";
|
|
6363
6386
|
const mainAxisMulti = originSides.has(side) ? -1 : 1;
|
|
6364
6387
|
const crossAxisMulti = rtl && isVertical ? -1 : 1;
|
|
6365
|
-
const rawValue = evaluate(options,
|
|
6388
|
+
const rawValue = evaluate(options, state23);
|
|
6366
6389
|
let {
|
|
6367
6390
|
mainAxis,
|
|
6368
6391
|
crossAxis,
|
|
@@ -6394,15 +6417,15 @@ var offset = function(options) {
|
|
|
6394
6417
|
return {
|
|
6395
6418
|
name: "offset",
|
|
6396
6419
|
options,
|
|
6397
|
-
async fn(
|
|
6420
|
+
async fn(state23) {
|
|
6398
6421
|
var _middlewareData$offse, _middlewareData$arrow;
|
|
6399
6422
|
const {
|
|
6400
6423
|
x,
|
|
6401
6424
|
y,
|
|
6402
6425
|
placement,
|
|
6403
6426
|
middlewareData
|
|
6404
|
-
} =
|
|
6405
|
-
const diffCoords = await convertValueToCoords(
|
|
6427
|
+
} = state23;
|
|
6428
|
+
const diffCoords = await convertValueToCoords(state23, options);
|
|
6406
6429
|
if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
|
|
6407
6430
|
return {};
|
|
6408
6431
|
}
|
|
@@ -6424,13 +6447,13 @@ var shift = function(options) {
|
|
|
6424
6447
|
return {
|
|
6425
6448
|
name: "shift",
|
|
6426
6449
|
options,
|
|
6427
|
-
async fn(
|
|
6450
|
+
async fn(state23) {
|
|
6428
6451
|
const {
|
|
6429
6452
|
x,
|
|
6430
6453
|
y,
|
|
6431
6454
|
placement,
|
|
6432
6455
|
platform: platform2
|
|
6433
|
-
} =
|
|
6456
|
+
} = state23;
|
|
6434
6457
|
const {
|
|
6435
6458
|
mainAxis: checkMainAxis = true,
|
|
6436
6459
|
crossAxis: checkCrossAxis = false,
|
|
@@ -6447,12 +6470,12 @@ var shift = function(options) {
|
|
|
6447
6470
|
}
|
|
6448
6471
|
},
|
|
6449
6472
|
...detectOverflowOptions
|
|
6450
|
-
} = evaluate(options,
|
|
6473
|
+
} = evaluate(options, state23);
|
|
6451
6474
|
const coords = {
|
|
6452
6475
|
x,
|
|
6453
6476
|
y
|
|
6454
6477
|
};
|
|
6455
|
-
const overflow = await platform2.detectOverflow(
|
|
6478
|
+
const overflow = await platform2.detectOverflow(state23, detectOverflowOptions);
|
|
6456
6479
|
const crossAxis = getSideAxis(getSide(placement));
|
|
6457
6480
|
const mainAxis = getOppositeAxis(crossAxis);
|
|
6458
6481
|
let mainAxisCoord = coords[mainAxis];
|
|
@@ -6472,7 +6495,7 @@ var shift = function(options) {
|
|
|
6472
6495
|
crossAxisCoord = clamp(min2, crossAxisCoord, max2);
|
|
6473
6496
|
}
|
|
6474
6497
|
const limitedCoords = limiter.fn({
|
|
6475
|
-
...
|
|
6498
|
+
...state23,
|
|
6476
6499
|
[mainAxis]: mainAxisCoord,
|
|
6477
6500
|
[crossAxis]: crossAxisCoord
|
|
6478
6501
|
});
|
|
@@ -6563,8 +6586,8 @@ var containRe = /paint|layout|strict|content/;
|
|
|
6563
6586
|
var isNotNone = (value) => !!value && value !== "none";
|
|
6564
6587
|
var isWebKitValue;
|
|
6565
6588
|
function isContainingBlock(elementOrCss) {
|
|
6566
|
-
const
|
|
6567
|
-
return isNotNone(
|
|
6589
|
+
const css153 = isElement(elementOrCss) ? getComputedStyle2(elementOrCss) : elementOrCss;
|
|
6590
|
+
return isNotNone(css153.transform) || isNotNone(css153.translate) || isNotNone(css153.scale) || isNotNone(css153.rotate) || isNotNone(css153.perspective) || !isWebKit() && (isNotNone(css153.backdropFilter) || isNotNone(css153.filter)) || willChangeRe.test(css153.willChange || "") || containRe.test(css153.contain || "");
|
|
6568
6591
|
}
|
|
6569
6592
|
function getContainingBlock(element) {
|
|
6570
6593
|
let currentNode = getParentNode(element);
|
|
@@ -6649,9 +6672,9 @@ function getFrameElement(win) {
|
|
|
6649
6672
|
|
|
6650
6673
|
// node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs
|
|
6651
6674
|
function getCssDimensions(element) {
|
|
6652
|
-
const
|
|
6653
|
-
let width = parseFloat(
|
|
6654
|
-
let height = parseFloat(
|
|
6675
|
+
const css153 = getComputedStyle2(element);
|
|
6676
|
+
let width = parseFloat(css153.width) || 0;
|
|
6677
|
+
let height = parseFloat(css153.height) || 0;
|
|
6655
6678
|
const hasOffset = isHTMLElement(element);
|
|
6656
6679
|
const offsetWidth = hasOffset ? element.offsetWidth : width;
|
|
6657
6680
|
const offsetHeight = hasOffset ? element.offsetHeight : height;
|
|
@@ -6745,9 +6768,9 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
6745
6768
|
while (currentIFrame && offsetParent && offsetWin !== currentWin) {
|
|
6746
6769
|
const iframeScale = getScale(currentIFrame);
|
|
6747
6770
|
const iframeRect = currentIFrame.getBoundingClientRect();
|
|
6748
|
-
const
|
|
6749
|
-
const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(
|
|
6750
|
-
const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(
|
|
6771
|
+
const css153 = getComputedStyle2(currentIFrame);
|
|
6772
|
+
const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css153.paddingLeft)) * iframeScale.x;
|
|
6773
|
+
const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css153.paddingTop)) * iframeScale.y;
|
|
6751
6774
|
x *= iframeScale.x;
|
|
6752
6775
|
y *= iframeScale.y;
|
|
6753
6776
|
width *= iframeScale.x;
|
|
@@ -6824,15 +6847,15 @@ function getClientRects(element) {
|
|
|
6824
6847
|
return Array.from(element.getClientRects());
|
|
6825
6848
|
}
|
|
6826
6849
|
function getDocumentRect(element) {
|
|
6827
|
-
const
|
|
6850
|
+
const html73 = getDocumentElement(element);
|
|
6828
6851
|
const scroll = getNodeScroll(element);
|
|
6829
6852
|
const body = element.ownerDocument.body;
|
|
6830
|
-
const width = max(
|
|
6831
|
-
const height = max(
|
|
6853
|
+
const width = max(html73.scrollWidth, html73.clientWidth, body.scrollWidth, body.clientWidth);
|
|
6854
|
+
const height = max(html73.scrollHeight, html73.clientHeight, body.scrollHeight, body.clientHeight);
|
|
6832
6855
|
let x = -scroll.scrollLeft + getWindowScrollBarX(element);
|
|
6833
6856
|
const y = -scroll.scrollTop;
|
|
6834
6857
|
if (getComputedStyle2(body).direction === "rtl") {
|
|
6835
|
-
x += max(
|
|
6858
|
+
x += max(html73.clientWidth, body.clientWidth) - width;
|
|
6836
6859
|
}
|
|
6837
6860
|
return {
|
|
6838
6861
|
width,
|
|
@@ -6844,10 +6867,10 @@ function getDocumentRect(element) {
|
|
|
6844
6867
|
var SCROLLBAR_MAX = 25;
|
|
6845
6868
|
function getViewportRect(element, strategy) {
|
|
6846
6869
|
const win = getWindow(element);
|
|
6847
|
-
const
|
|
6870
|
+
const html73 = getDocumentElement(element);
|
|
6848
6871
|
const visualViewport = win.visualViewport;
|
|
6849
|
-
let width =
|
|
6850
|
-
let height =
|
|
6872
|
+
let width = html73.clientWidth;
|
|
6873
|
+
let height = html73.clientHeight;
|
|
6851
6874
|
let x = 0;
|
|
6852
6875
|
let y = 0;
|
|
6853
6876
|
if (visualViewport) {
|
|
@@ -6859,13 +6882,13 @@ function getViewportRect(element, strategy) {
|
|
|
6859
6882
|
y = visualViewport.offsetTop;
|
|
6860
6883
|
}
|
|
6861
6884
|
}
|
|
6862
|
-
const windowScrollbarX = getWindowScrollBarX(
|
|
6885
|
+
const windowScrollbarX = getWindowScrollBarX(html73);
|
|
6863
6886
|
if (windowScrollbarX <= 0) {
|
|
6864
|
-
const doc =
|
|
6887
|
+
const doc = html73.ownerDocument;
|
|
6865
6888
|
const body = doc.body;
|
|
6866
6889
|
const bodyStyles = getComputedStyle(body);
|
|
6867
6890
|
const bodyMarginInline = doc.compatMode === "CSS1Compat" ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;
|
|
6868
|
-
const clippingStableScrollbarWidth = Math.abs(
|
|
6891
|
+
const clippingStableScrollbarWidth = Math.abs(html73.clientWidth - body.clientWidth - bodyMarginInline);
|
|
6869
6892
|
if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {
|
|
6870
6893
|
width -= clippingStableScrollbarWidth;
|
|
6871
6894
|
}
|
|
@@ -7803,14 +7826,16 @@ var CsErrorBoundaryInternal = class extends CsBaseElement {
|
|
|
7803
7826
|
render() {
|
|
7804
7827
|
if (this._hasError) {
|
|
7805
7828
|
return html21`
|
|
7806
|
-
<
|
|
7807
|
-
<
|
|
7808
|
-
|
|
7809
|
-
|
|
7810
|
-
|
|
7829
|
+
<div class="error-boundary">
|
|
7830
|
+
<cs-alert type="error" .visible=${true}>
|
|
7831
|
+
<span slot="header">Something went wrong</span>
|
|
7832
|
+
An error occurred. Please try refreshing.
|
|
7833
|
+
<cs-button slot="action" @click=${this._retry}>Retry</cs-button>
|
|
7834
|
+
</cs-alert>
|
|
7835
|
+
</div>
|
|
7811
7836
|
`;
|
|
7812
7837
|
}
|
|
7813
|
-
return html21`<slot></slot>`;
|
|
7838
|
+
return html21`<div class="error-boundary"><slot></slot></div>`;
|
|
7814
7839
|
}
|
|
7815
7840
|
};
|
|
7816
7841
|
__decorateClass([
|
|
@@ -9958,6 +9983,18 @@ var componentStyles26 = css63`
|
|
|
9958
9983
|
|
|
9959
9984
|
// src/token/internal.ts
|
|
9960
9985
|
var hostStyles28 = css64`:host { display: inline-block; }`;
|
|
9986
|
+
var inventedStyles3 = css64`
|
|
9987
|
+
.label-tag {
|
|
9988
|
+
display: inline-block;
|
|
9989
|
+
margin-inline-start: var(--space-xxs-hwfkai, 4px);
|
|
9990
|
+
font-size: var(--font-body-s-size-ukbcbk, 12px);
|
|
9991
|
+
color: var(--color-text-body-secondary-fdstdf, #5f6b7a);
|
|
9992
|
+
}
|
|
9993
|
+
.description {
|
|
9994
|
+
font-size: var(--font-body-s-size-ukbcbk, 12px);
|
|
9995
|
+
color: var(--color-text-body-secondary-fdstdf, #5f6b7a);
|
|
9996
|
+
}
|
|
9997
|
+
`;
|
|
9961
9998
|
var CsTokenInternal = class extends CsBaseElement {
|
|
9962
9999
|
constructor() {
|
|
9963
10000
|
super(...arguments);
|
|
@@ -9974,7 +10011,7 @@ var CsTokenInternal = class extends CsBaseElement {
|
|
|
9974
10011
|
};
|
|
9975
10012
|
}
|
|
9976
10013
|
static {
|
|
9977
|
-
this.styles = [sharedStyles, componentStyles26, hostStyles28];
|
|
10014
|
+
this.styles = [sharedStyles, componentStyles26, hostStyles28, inventedStyles3];
|
|
9978
10015
|
}
|
|
9979
10016
|
render() {
|
|
9980
10017
|
const isInline = this.variant === "inline";
|
|
@@ -10101,6 +10138,18 @@ var componentStyles27 = css65`
|
|
|
10101
10138
|
|
|
10102
10139
|
// src/token-group/internal.ts
|
|
10103
10140
|
var hostStyles29 = css66`:host { display: block; }`;
|
|
10141
|
+
var inventedStyles4 = css66`
|
|
10142
|
+
.label-tag {
|
|
10143
|
+
display: inline-block;
|
|
10144
|
+
margin-inline-start: var(--space-xxs-hwfkai, 4px);
|
|
10145
|
+
font-size: var(--font-body-s-size-ukbcbk, 12px);
|
|
10146
|
+
color: var(--color-text-body-secondary-fdstdf, #5f6b7a);
|
|
10147
|
+
}
|
|
10148
|
+
.tags {
|
|
10149
|
+
display: inline;
|
|
10150
|
+
margin-inline-start: var(--space-xxs-hwfkai, 4px);
|
|
10151
|
+
}
|
|
10152
|
+
`;
|
|
10104
10153
|
var tokenListStyles = css66`
|
|
10105
10154
|
.list {
|
|
10106
10155
|
display: flex;
|
|
@@ -10146,7 +10195,7 @@ var CsTokenGroupInternal = class extends CsBaseElement {
|
|
|
10146
10195
|
this._expanded = false;
|
|
10147
10196
|
}
|
|
10148
10197
|
static {
|
|
10149
|
-
this.styles = [sharedStyles, componentStyles27, componentStyles26, tokenListStyles, hostStyles29];
|
|
10198
|
+
this.styles = [sharedStyles, componentStyles27, componentStyles26, tokenListStyles, hostStyles29, inventedStyles4];
|
|
10150
10199
|
}
|
|
10151
10200
|
_onDismiss(itemIndex) {
|
|
10152
10201
|
const item = this.items[itemIndex];
|
|
@@ -10631,6 +10680,7 @@ var CsContainerInternal = class extends CsBaseElement {
|
|
|
10631
10680
|
render() {
|
|
10632
10681
|
const rootClasses = {
|
|
10633
10682
|
"root": true,
|
|
10683
|
+
"refresh": true,
|
|
10634
10684
|
[`variant-${this.variant}`]: true,
|
|
10635
10685
|
"fit-height": this.fitHeight,
|
|
10636
10686
|
"with-side-media": false,
|
|
@@ -10990,6 +11040,7 @@ var CsHeaderInternal = class extends CsBaseElement {
|
|
|
10990
11040
|
const tag = this.headingTagOverride || variantToTag[this.variant] || "h2";
|
|
10991
11041
|
const headingClasses = {
|
|
10992
11042
|
"heading": true,
|
|
11043
|
+
"heading-text": true,
|
|
10993
11044
|
[`heading-variant-${this.variant}`]: true,
|
|
10994
11045
|
[`heading-text-variant-${this.variant}`]: true
|
|
10995
11046
|
};
|
|
@@ -11012,6 +11063,7 @@ var CsHeaderInternal = class extends CsBaseElement {
|
|
|
11012
11063
|
const hasDescription = !!this.description || this._hasDescription;
|
|
11013
11064
|
const rootClasses = {
|
|
11014
11065
|
"root": true,
|
|
11066
|
+
"refresh": true,
|
|
11015
11067
|
[`root-variant-${this.variant}`]: true,
|
|
11016
11068
|
"root-no-actions": !this._hasActions,
|
|
11017
11069
|
"root-has-description": hasDescription
|
|
@@ -11806,7 +11858,7 @@ var CsFlashbarInternal = class extends CsBaseElement {
|
|
|
11806
11858
|
<div class="flash-focus-container" tabindex="-1">
|
|
11807
11859
|
<div class="flash-message">
|
|
11808
11860
|
${item.header ? html33`<div class="flash-header">${item.header}</div>` : nothing15}
|
|
11809
|
-
${item.content ? html33`<div class="flash-content">${item.content}</div>` : nothing15}
|
|
11861
|
+
${item.content ? html33`<div class="flash-content"><span class="flash-text">${item.content}</span></div>` : nothing15}
|
|
11810
11862
|
</div>
|
|
11811
11863
|
</div>
|
|
11812
11864
|
${item.buttonText ? html33`<div class="action-button-wrapper">
|
|
@@ -12744,6 +12796,8 @@ var CsPromptInputInternal = class extends CsBaseElement {
|
|
|
12744
12796
|
this.placeholder = "";
|
|
12745
12797
|
this.disabled = false;
|
|
12746
12798
|
this.readOnly = false;
|
|
12799
|
+
this.invalid = false;
|
|
12800
|
+
this.warning = false;
|
|
12747
12801
|
this.actionButtonAriaLabel = "Submit";
|
|
12748
12802
|
this.actionButtonIconName = "send";
|
|
12749
12803
|
this.disableActionButton = false;
|
|
@@ -12778,11 +12832,15 @@ var CsPromptInputInternal = class extends CsBaseElement {
|
|
|
12778
12832
|
const rootClasses = {
|
|
12779
12833
|
"root": true,
|
|
12780
12834
|
"disabled": this.disabled,
|
|
12781
|
-
"textarea-readonly": this.readOnly
|
|
12835
|
+
"textarea-readonly": this.readOnly,
|
|
12836
|
+
"textarea-invalid": this.invalid,
|
|
12837
|
+
"textarea-warning": this.warning && !this.invalid
|
|
12782
12838
|
};
|
|
12783
12839
|
const textareaClasses = {
|
|
12784
12840
|
"textarea": true,
|
|
12785
|
-
"textarea-readonly": this.readOnly
|
|
12841
|
+
"textarea-readonly": this.readOnly,
|
|
12842
|
+
"textarea-invalid": this.invalid,
|
|
12843
|
+
"textarea-warning": this.warning && !this.invalid
|
|
12786
12844
|
};
|
|
12787
12845
|
return html36`
|
|
12788
12846
|
<div class=${classMap32(rootClasses)}>
|
|
@@ -12825,6 +12883,12 @@ __decorateClass([
|
|
|
12825
12883
|
__decorateClass([
|
|
12826
12884
|
property35({ type: Boolean, reflect: true })
|
|
12827
12885
|
], CsPromptInputInternal.prototype, "readOnly", 2);
|
|
12886
|
+
__decorateClass([
|
|
12887
|
+
property35({ type: Boolean, reflect: true })
|
|
12888
|
+
], CsPromptInputInternal.prototype, "invalid", 2);
|
|
12889
|
+
__decorateClass([
|
|
12890
|
+
property35({ type: Boolean, reflect: true })
|
|
12891
|
+
], CsPromptInputInternal.prototype, "warning", 2);
|
|
12828
12892
|
__decorateClass([
|
|
12829
12893
|
property35({ type: String })
|
|
12830
12894
|
], CsPromptInputInternal.prototype, "actionButtonAriaLabel", 2);
|
|
@@ -12846,6 +12910,7 @@ customElements.define("cs-prompt-input", CsPromptInput);
|
|
|
12846
12910
|
// src/copy-to-clipboard/internal.ts
|
|
12847
12911
|
import { css as css80, html as html37 } from "lit";
|
|
12848
12912
|
import { property as property36, state as state8 } from "lit/decorators.js";
|
|
12913
|
+
import { classMap as classMap33 } from "lit/directives/class-map.js";
|
|
12849
12914
|
|
|
12850
12915
|
// src/copy-to-clipboard/styles.ts
|
|
12851
12916
|
import { css as css79 } from "lit";
|
|
@@ -12929,18 +12994,25 @@ var CsCopyToClipboardInternal = class extends CsBaseElement {
|
|
|
12929
12994
|
}
|
|
12930
12995
|
render() {
|
|
12931
12996
|
const isIconOnly = this.variant === "icon" || this.variant === "inline";
|
|
12997
|
+
const isInline = this.variant === "inline";
|
|
12932
12998
|
const buttonVariant = isIconOnly ? "icon" : "normal";
|
|
12933
12999
|
const buttonText = this._getButtonText();
|
|
12934
13000
|
const iconName = this._getIconName();
|
|
13001
|
+
const rootClasses = {
|
|
13002
|
+
"root": true,
|
|
13003
|
+
"inline-container": isInline
|
|
13004
|
+
};
|
|
12935
13005
|
return html37`
|
|
12936
|
-
<span class
|
|
12937
|
-
<
|
|
12938
|
-
|
|
12939
|
-
|
|
12940
|
-
|
|
12941
|
-
|
|
12942
|
-
|
|
12943
|
-
|
|
13006
|
+
<span class=${classMap33(rootClasses)}>
|
|
13007
|
+
<span class=${classMap33({ "inline-container-trigger": isInline })}>
|
|
13008
|
+
<cs-button
|
|
13009
|
+
variant=${buttonVariant}
|
|
13010
|
+
icon-name=${iconName}
|
|
13011
|
+
?disabled=${this.disabled}
|
|
13012
|
+
aria-label=${isIconOnly ? buttonText : ""}
|
|
13013
|
+
@click=${this._onCopyClick}
|
|
13014
|
+
>${!isIconOnly ? buttonText : ""}</cs-button>
|
|
13015
|
+
</span>
|
|
12944
13016
|
</span>
|
|
12945
13017
|
`;
|
|
12946
13018
|
}
|
|
@@ -13128,7 +13200,7 @@ customElements.define("cs-file-input", CsFileInput);
|
|
|
13128
13200
|
// src/tabs/internal.ts
|
|
13129
13201
|
import { css as css84, html as html39, nothing as nothing16 } from "lit";
|
|
13130
13202
|
import { property as property38, state as state9 } from "lit/decorators.js";
|
|
13131
|
-
import { classMap as
|
|
13203
|
+
import { classMap as classMap34 } from "lit/directives/class-map.js";
|
|
13132
13204
|
|
|
13133
13205
|
// src/tabs/styles.ts
|
|
13134
13206
|
import { css as css83 } from "lit";
|
|
@@ -13522,11 +13594,11 @@ var CsTabsInternal = class extends CsBaseElement {
|
|
|
13522
13594
|
"refresh": true
|
|
13523
13595
|
};
|
|
13524
13596
|
return html39`
|
|
13525
|
-
<li class
|
|
13526
|
-
<div class=${
|
|
13597
|
+
<li class=${classMap34({ "tabs-tab": true, "tabs-tab-focusable": true })} role="presentation">
|
|
13598
|
+
<div class=${classMap34(headerContainerClasses)}>
|
|
13527
13599
|
<a
|
|
13528
13600
|
role="tab"
|
|
13529
|
-
class=${
|
|
13601
|
+
class=${classMap34(linkClasses)}
|
|
13530
13602
|
aria-selected=${isActive ? "true" : "false"}
|
|
13531
13603
|
aria-disabled=${isDisabled ? "true" : "false"}
|
|
13532
13604
|
aria-controls=${`panel-${tab.id}`}
|
|
@@ -13568,19 +13640,21 @@ var CsTabsInternal = class extends CsBaseElement {
|
|
|
13568
13640
|
};
|
|
13569
13641
|
const isContainerVariant = this.variant === "container" || this.variant === "stacked";
|
|
13570
13642
|
return html39`
|
|
13571
|
-
<div class=${
|
|
13572
|
-
<div class=${
|
|
13573
|
-
<
|
|
13574
|
-
|
|
13575
|
-
|
|
13643
|
+
<div class=${classMap34(rootClasses)}>
|
|
13644
|
+
<div class=${classMap34(headerClasses)}>
|
|
13645
|
+
<div class="tab-header-scroll-container">
|
|
13646
|
+
<ul class="tabs-header-list" role="tablist">
|
|
13647
|
+
${this.tabs.map((tab) => this._renderTab(tab))}
|
|
13648
|
+
</ul>
|
|
13649
|
+
</div>
|
|
13576
13650
|
</div>
|
|
13577
|
-
<div class=${
|
|
13578
|
-
${isContainerVariant ? html39`<div class=${
|
|
13651
|
+
<div class=${classMap34(contentWrapperClasses)}>
|
|
13652
|
+
${isContainerVariant ? html39`<div class=${classMap34(containerContentWrapperClasses)}>
|
|
13579
13653
|
${this.tabs.map((tab) => html39`
|
|
13580
13654
|
<div
|
|
13581
13655
|
role="tabpanel"
|
|
13582
13656
|
id=${`panel-${tab.id}`}
|
|
13583
|
-
class=${
|
|
13657
|
+
class=${classMap34({
|
|
13584
13658
|
"tabs-content": true,
|
|
13585
13659
|
"tabs-content-active": tab.id === activeId
|
|
13586
13660
|
})}
|
|
@@ -13595,7 +13669,7 @@ var CsTabsInternal = class extends CsBaseElement {
|
|
|
13595
13669
|
<div
|
|
13596
13670
|
role="tabpanel"
|
|
13597
13671
|
id=${`panel-${tab.id}`}
|
|
13598
|
-
class=${
|
|
13672
|
+
class=${classMap34({
|
|
13599
13673
|
"tabs-content": true,
|
|
13600
13674
|
"tabs-content-active": tab.id === activeId
|
|
13601
13675
|
})}
|
|
@@ -13638,7 +13712,7 @@ customElements.define("cs-tabs", CsTabs);
|
|
|
13638
13712
|
// src/expandable-section/internal.ts
|
|
13639
13713
|
import { css as css86, html as html40, nothing as nothing17 } from "lit";
|
|
13640
13714
|
import { property as property39, state as state10 } from "lit/decorators.js";
|
|
13641
|
-
import { classMap as
|
|
13715
|
+
import { classMap as classMap35 } from "lit/directives/class-map.js";
|
|
13642
13716
|
|
|
13643
13717
|
// src/expandable-section/styles.ts
|
|
13644
13718
|
import { css as css85 } from "lit";
|
|
@@ -14001,19 +14075,19 @@ var CsExpandableSectionInternal = class extends CsBaseElement {
|
|
|
14001
14075
|
"header-wrapper": true
|
|
14002
14076
|
};
|
|
14003
14077
|
if (!tag) {
|
|
14004
|
-
return html40`<div class=${
|
|
14078
|
+
return html40`<div class=${classMap35(headingClasses)}>${content}</div>`;
|
|
14005
14079
|
}
|
|
14006
14080
|
switch (tag) {
|
|
14007
14081
|
case "h1":
|
|
14008
|
-
return html40`<h1 class=${
|
|
14082
|
+
return html40`<h1 class=${classMap35(headingClasses)}>${content}</h1>`;
|
|
14009
14083
|
case "h3":
|
|
14010
|
-
return html40`<h3 class=${
|
|
14084
|
+
return html40`<h3 class=${classMap35(headingClasses)}>${content}</h3>`;
|
|
14011
14085
|
case "h4":
|
|
14012
|
-
return html40`<h4 class=${
|
|
14086
|
+
return html40`<h4 class=${classMap35(headingClasses)}>${content}</h4>`;
|
|
14013
14087
|
case "h5":
|
|
14014
|
-
return html40`<h5 class=${
|
|
14088
|
+
return html40`<h5 class=${classMap35(headingClasses)}>${content}</h5>`;
|
|
14015
14089
|
default:
|
|
14016
|
-
return html40`<h2 class=${
|
|
14090
|
+
return html40`<h2 class=${classMap35(headingClasses)}>${content}</h2>`;
|
|
14017
14091
|
}
|
|
14018
14092
|
}
|
|
14019
14093
|
_isContainerVariant() {
|
|
@@ -14053,10 +14127,10 @@ var CsExpandableSectionInternal = class extends CsBaseElement {
|
|
|
14053
14127
|
"header-actions-wrapper": true
|
|
14054
14128
|
};
|
|
14055
14129
|
return html40`
|
|
14056
|
-
<div class=${
|
|
14057
|
-
<div class=${
|
|
14130
|
+
<div class=${classMap35(rootClasses)}>
|
|
14131
|
+
<div class=${classMap35(headerActionsWrapperClasses)}>
|
|
14058
14132
|
<div
|
|
14059
|
-
class=${
|
|
14133
|
+
class=${classMap35(wrapperClasses)}
|
|
14060
14134
|
role="button"
|
|
14061
14135
|
tabindex="0"
|
|
14062
14136
|
aria-expanded=${expanded ? "true" : "false"}
|
|
@@ -14064,9 +14138,9 @@ var CsExpandableSectionInternal = class extends CsBaseElement {
|
|
|
14064
14138
|
@click=${this._onHeaderClick}
|
|
14065
14139
|
@keydown=${this._onHeaderKeyDown}
|
|
14066
14140
|
>
|
|
14067
|
-
<div class=${
|
|
14068
|
-
<div class=${
|
|
14069
|
-
<span class=${
|
|
14141
|
+
<div class=${classMap35(buttonClasses)}>
|
|
14142
|
+
<div class=${classMap35(iconContainerClasses)}>
|
|
14143
|
+
<span class=${classMap35(iconClasses)}>
|
|
14070
14144
|
<cs-icon name="caret-down-filled"></cs-icon>
|
|
14071
14145
|
</span>
|
|
14072
14146
|
</div>
|
|
@@ -14078,7 +14152,7 @@ var CsExpandableSectionInternal = class extends CsBaseElement {
|
|
|
14078
14152
|
</div>
|
|
14079
14153
|
<slot name="headerActions"></slot>
|
|
14080
14154
|
</div>
|
|
14081
|
-
<div class=${
|
|
14155
|
+
<div class=${classMap35(contentClasses)}>
|
|
14082
14156
|
<slot></slot>
|
|
14083
14157
|
</div>
|
|
14084
14158
|
</div>
|
|
@@ -14124,7 +14198,7 @@ customElements.define("cs-expandable-section", CsExpandableSection);
|
|
|
14124
14198
|
// src/button-dropdown/internal.ts
|
|
14125
14199
|
import { css as css89, html as html41, nothing as nothing18 } from "lit";
|
|
14126
14200
|
import { property as property40, state as state11, query as query3 } from "lit/decorators.js";
|
|
14127
|
-
import { classMap as
|
|
14201
|
+
import { classMap as classMap36 } from "lit/directives/class-map.js";
|
|
14128
14202
|
import { ifDefined as ifDefined20 } from "lit/directives/if-defined.js";
|
|
14129
14203
|
|
|
14130
14204
|
// src/button-dropdown/styles.ts
|
|
@@ -14615,7 +14689,7 @@ var CsButtonDropdownInternal = class extends CsBaseElement {
|
|
|
14615
14689
|
if (isIcon) {
|
|
14616
14690
|
return html41`
|
|
14617
14691
|
<button
|
|
14618
|
-
class=${
|
|
14692
|
+
class=${classMap36(buttonClasses)}
|
|
14619
14693
|
type="button"
|
|
14620
14694
|
aria-haspopup="true"
|
|
14621
14695
|
aria-expanded=${this._open}
|
|
@@ -14634,7 +14708,7 @@ var CsButtonDropdownInternal = class extends CsBaseElement {
|
|
|
14634
14708
|
};
|
|
14635
14709
|
return html41`
|
|
14636
14710
|
<button
|
|
14637
|
-
class=${
|
|
14711
|
+
class=${classMap36(buttonClasses)}
|
|
14638
14712
|
type="button"
|
|
14639
14713
|
aria-haspopup="true"
|
|
14640
14714
|
aria-expanded=${this._open}
|
|
@@ -14645,7 +14719,7 @@ var CsButtonDropdownInternal = class extends CsBaseElement {
|
|
|
14645
14719
|
>
|
|
14646
14720
|
${this.loading ? html41`<span class="icon icon-left"><cs-icon name="status-in-progress"></cs-icon></span>` : nothing18}
|
|
14647
14721
|
<slot></slot>
|
|
14648
|
-
<span class=${
|
|
14722
|
+
<span class=${classMap36(caretClasses)}>
|
|
14649
14723
|
<cs-icon name="caret-down-filled"></cs-icon>
|
|
14650
14724
|
</span>
|
|
14651
14725
|
</button>
|
|
@@ -14669,7 +14743,7 @@ var CsButtonDropdownInternal = class extends CsBaseElement {
|
|
|
14669
14743
|
};
|
|
14670
14744
|
return html41`
|
|
14671
14745
|
<li
|
|
14672
|
-
class=${
|
|
14746
|
+
class=${classMap36(itemClasses)}
|
|
14673
14747
|
role="menuitem"
|
|
14674
14748
|
aria-disabled=${item.disabled ? "true" : "false"}
|
|
14675
14749
|
@click=${(e) => this._onItemClick(item, e)}
|
|
@@ -14679,7 +14753,7 @@ var CsButtonDropdownInternal = class extends CsBaseElement {
|
|
|
14679
14753
|
>
|
|
14680
14754
|
${item.href ? html41`
|
|
14681
14755
|
<a
|
|
14682
|
-
class=${
|
|
14756
|
+
class=${classMap36(menuItemClasses)}
|
|
14683
14757
|
href=${item.disabled ? "javascript:void(0)" : item.href}
|
|
14684
14758
|
tabindex="-1"
|
|
14685
14759
|
@click=${(e) => {
|
|
@@ -14690,7 +14764,7 @@ var CsButtonDropdownInternal = class extends CsBaseElement {
|
|
|
14690
14764
|
<span>${item.text}</span>
|
|
14691
14765
|
</a>
|
|
14692
14766
|
` : html41`
|
|
14693
|
-
<span class=${
|
|
14767
|
+
<span class=${classMap36(menuItemClasses)} tabindex="-1">
|
|
14694
14768
|
${item.iconName ? html41`<span class="button-dropdown-item-element--icon"><cs-icon name=${item.iconName}></cs-icon></span>` : nothing18}
|
|
14695
14769
|
<span>${item.text}</span>
|
|
14696
14770
|
</span>
|
|
@@ -14912,7 +14986,7 @@ customElements.define("cs-button-group", CsButtonGroup);
|
|
|
14912
14986
|
// src/breadcrumb-group/internal.ts
|
|
14913
14987
|
import { css as css94, html as html43 } from "lit";
|
|
14914
14988
|
import { property as property42 } from "lit/decorators.js";
|
|
14915
|
-
import { classMap as
|
|
14989
|
+
import { classMap as classMap37 } from "lit/directives/class-map.js";
|
|
14916
14990
|
import { ifDefined as ifDefined22 } from "lit/directives/if-defined.js";
|
|
14917
14991
|
|
|
14918
14992
|
// src/breadcrumb-group/styles.ts
|
|
@@ -15190,14 +15264,14 @@ var CsBreadcrumbGroupInternal = class extends CsBaseElement {
|
|
|
15190
15264
|
};
|
|
15191
15265
|
return html43`
|
|
15192
15266
|
<li class="item">
|
|
15193
|
-
<div class=${
|
|
15267
|
+
<div class=${classMap37(breadcrumbClasses)}>
|
|
15194
15268
|
${isLast ? html43`
|
|
15195
|
-
<span class=${
|
|
15269
|
+
<span class=${classMap37(anchorClasses)} aria-current="page">
|
|
15196
15270
|
<span class="breadcrumb-group-item--text">${item.text}</span>
|
|
15197
15271
|
</span>
|
|
15198
15272
|
` : html43`
|
|
15199
15273
|
<a
|
|
15200
|
-
class=${
|
|
15274
|
+
class=${classMap37(anchorClasses)}
|
|
15201
15275
|
href=${item.href}
|
|
15202
15276
|
@click=${(e) => this._onItemClick(item, index, e)}
|
|
15203
15277
|
>
|
|
@@ -15239,7 +15313,7 @@ customElements.define("cs-breadcrumb-group", CsBreadcrumbGroup);
|
|
|
15239
15313
|
// src/select/internal.ts
|
|
15240
15314
|
import { css as css97, html as html44, nothing as nothing19 } from "lit";
|
|
15241
15315
|
import { property as property43, state as state12, query as query4 } from "lit/decorators.js";
|
|
15242
|
-
import { classMap as
|
|
15316
|
+
import { classMap as classMap38 } from "lit/directives/class-map.js";
|
|
15243
15317
|
import { ifDefined as ifDefined23 } from "lit/directives/if-defined.js";
|
|
15244
15318
|
|
|
15245
15319
|
// src/select/styles.ts
|
|
@@ -15768,7 +15842,7 @@ var CsSelectInternal = class extends Base6 {
|
|
|
15768
15842
|
};
|
|
15769
15843
|
return html44`
|
|
15770
15844
|
<li
|
|
15771
|
-
class=${
|
|
15845
|
+
class=${classMap38(classes)}
|
|
15772
15846
|
role="option"
|
|
15773
15847
|
aria-selected=${isSelected}
|
|
15774
15848
|
aria-disabled=${ifDefined23(opt.disabled ? "true" : void 0)}
|
|
@@ -15834,7 +15908,7 @@ var CsSelectInternal = class extends Base6 {
|
|
|
15834
15908
|
return html44`
|
|
15835
15909
|
<div class="root">
|
|
15836
15910
|
<button
|
|
15837
|
-
class=${
|
|
15911
|
+
class=${classMap38(triggerClasses)}
|
|
15838
15912
|
type="button"
|
|
15839
15913
|
aria-haspopup="listbox"
|
|
15840
15914
|
aria-expanded=${this._open}
|
|
@@ -15911,7 +15985,7 @@ customElements.define("cs-select", CsSelect);
|
|
|
15911
15985
|
// src/multiselect/internal.ts
|
|
15912
15986
|
import { css as css99, html as html45, nothing as nothing20 } from "lit";
|
|
15913
15987
|
import { property as property44, state as state13, query as query5 } from "lit/decorators.js";
|
|
15914
|
-
import { classMap as
|
|
15988
|
+
import { classMap as classMap39 } from "lit/directives/class-map.js";
|
|
15915
15989
|
import { ifDefined as ifDefined24 } from "lit/directives/if-defined.js";
|
|
15916
15990
|
|
|
15917
15991
|
// src/multiselect/styles.ts
|
|
@@ -16384,7 +16458,7 @@ var CsMultiselectInternal = class extends Base7 {
|
|
|
16384
16458
|
};
|
|
16385
16459
|
return html45`
|
|
16386
16460
|
<li
|
|
16387
|
-
class=${
|
|
16461
|
+
class=${classMap39(classes)}
|
|
16388
16462
|
role="option"
|
|
16389
16463
|
aria-selected=${isSelected}
|
|
16390
16464
|
aria-disabled=${ifDefined24(opt.disabled ? "true" : void 0)}
|
|
@@ -16393,7 +16467,7 @@ var CsMultiselectInternal = class extends Base7 {
|
|
|
16393
16467
|
if (!opt.disabled) this._highlightedIndex = index;
|
|
16394
16468
|
}}
|
|
16395
16469
|
>
|
|
16396
|
-
<div class=${
|
|
16470
|
+
<div class=${classMap39(checkboxClasses)}></div>
|
|
16397
16471
|
<div class="option-content">
|
|
16398
16472
|
<div class="option-label">
|
|
16399
16473
|
${opt.label || opt.value || ""}
|
|
@@ -16467,7 +16541,7 @@ var CsMultiselectInternal = class extends Base7 {
|
|
|
16467
16541
|
return html45`
|
|
16468
16542
|
<div class="root">
|
|
16469
16543
|
<button
|
|
16470
|
-
class=${
|
|
16544
|
+
class=${classMap39(triggerClasses)}
|
|
16471
16545
|
type="button"
|
|
16472
16546
|
aria-haspopup="listbox"
|
|
16473
16547
|
aria-expanded=${this._open}
|
|
@@ -16554,7 +16628,7 @@ customElements.define("cs-multiselect", CsMultiselect);
|
|
|
16554
16628
|
// src/autosuggest/internal.ts
|
|
16555
16629
|
import { css as css102, html as html46, nothing as nothing21 } from "lit";
|
|
16556
16630
|
import { property as property45, state as state14, query as query6 } from "lit/decorators.js";
|
|
16557
|
-
import { classMap as
|
|
16631
|
+
import { classMap as classMap40 } from "lit/directives/class-map.js";
|
|
16558
16632
|
import { ifDefined as ifDefined25 } from "lit/directives/if-defined.js";
|
|
16559
16633
|
|
|
16560
16634
|
// src/autosuggest/styles.ts
|
|
@@ -16952,7 +17026,7 @@ var CsAutosuggestInternal = class extends Base8 {
|
|
|
16952
17026
|
<div class="root">
|
|
16953
17027
|
<div class="layout-strut">
|
|
16954
17028
|
<input
|
|
16955
|
-
class=${
|
|
17029
|
+
class=${classMap40(inputClasses)}
|
|
16956
17030
|
type="text"
|
|
16957
17031
|
.value=${this.value}
|
|
16958
17032
|
placeholder=${ifDefined25(this.placeholder || void 0)}
|
|
@@ -16996,7 +17070,7 @@ var CsAutosuggestInternal = class extends Base8 {
|
|
|
16996
17070
|
};
|
|
16997
17071
|
return html46`
|
|
16998
17072
|
<div
|
|
16999
|
-
class=${
|
|
17073
|
+
class=${classMap40(classes)}
|
|
17000
17074
|
id=${`${this._listboxId}-option-${index}`}
|
|
17001
17075
|
role="option"
|
|
17002
17076
|
aria-selected=${isHighlighted ? "true" : "false"}
|
|
@@ -17053,7 +17127,7 @@ customElements.define("cs-autosuggest", CsAutosuggest);
|
|
|
17053
17127
|
// src/segmented-control/internal.ts
|
|
17054
17128
|
import { css as css104, html as html47 } from "lit";
|
|
17055
17129
|
import { property as property46 } from "lit/decorators.js";
|
|
17056
|
-
import { classMap as
|
|
17130
|
+
import { classMap as classMap41 } from "lit/directives/class-map.js";
|
|
17057
17131
|
import { ifDefined as ifDefined26 } from "lit/directives/if-defined.js";
|
|
17058
17132
|
|
|
17059
17133
|
// src/segmented-control/styles.ts
|
|
@@ -17323,9 +17397,9 @@ var CsSegmentedControlInternal = class extends CsBaseElement {
|
|
|
17323
17397
|
const count = Math.min(this.options.length, 6);
|
|
17324
17398
|
const segmentCountClass = `segment-count-${count}`;
|
|
17325
17399
|
return html47`
|
|
17326
|
-
<div class
|
|
17400
|
+
<div class=${classMap41({ "root": true, "refresh": true })}>
|
|
17327
17401
|
<div
|
|
17328
|
-
class=${
|
|
17402
|
+
class=${classMap41({ "segment-part": true, [segmentCountClass]: true })}
|
|
17329
17403
|
role="group"
|
|
17330
17404
|
aria-label=${ifDefined26(this.label || void 0)}
|
|
17331
17405
|
aria-labelledby=${ifDefined26(!this.label && this.ariaLabelledby ? this.ariaLabelledby : void 0)}
|
|
@@ -17345,7 +17419,7 @@ var CsSegmentedControlInternal = class extends CsBaseElement {
|
|
|
17345
17419
|
};
|
|
17346
17420
|
return html47`
|
|
17347
17421
|
<button
|
|
17348
|
-
class=${
|
|
17422
|
+
class=${classMap41(segmentClasses)}
|
|
17349
17423
|
type="button"
|
|
17350
17424
|
?disabled=${isDisabled}
|
|
17351
17425
|
aria-pressed=${isSelected ? "true" : "false"}
|
|
@@ -17386,7 +17460,7 @@ customElements.define("cs-segmented-control", CsSegmentedControl);
|
|
|
17386
17460
|
// src/cards/internal.ts
|
|
17387
17461
|
import { css as css106, html as html48, nothing as nothing22 } from "lit";
|
|
17388
17462
|
import { property as property47, state as state15 } from "lit/decorators.js";
|
|
17389
|
-
import { classMap as
|
|
17463
|
+
import { classMap as classMap42 } from "lit/directives/class-map.js";
|
|
17390
17464
|
|
|
17391
17465
|
// src/cards/styles.ts
|
|
17392
17466
|
import { css as css105 } from "lit";
|
|
@@ -17674,10 +17748,10 @@ var CsCardsInternal = class extends CsBaseElement {
|
|
|
17674
17748
|
};
|
|
17675
17749
|
const selectionLabel = this.ariaLabels?.itemSelectionLabel ? this.ariaLabels.itemSelectionLabel({ selectedItems: [...this.selectedItems] }, item) : void 0;
|
|
17676
17750
|
return html48`
|
|
17677
|
-
<li class=${
|
|
17751
|
+
<li class=${classMap42(cardClasses)} data-item-index=${index}>
|
|
17678
17752
|
<cs-container variant="default">
|
|
17679
17753
|
<div slot="header" style="position: relative;">
|
|
17680
|
-
<div class=${
|
|
17754
|
+
<div class=${classMap42(cardHeaderClasses)}>
|
|
17681
17755
|
${headerContent ?? nothing22}
|
|
17682
17756
|
</div>
|
|
17683
17757
|
${isSelectable ? html48`
|
|
@@ -17715,7 +17789,7 @@ var CsCardsInternal = class extends CsBaseElement {
|
|
|
17715
17789
|
</div>
|
|
17716
17790
|
<slot name="filter"></slot>
|
|
17717
17791
|
<slot name="pagination"></slot>
|
|
17718
|
-
<div class=${
|
|
17792
|
+
<div class=${classMap42(bodyClasses)}>
|
|
17719
17793
|
${showLoading ? html48`
|
|
17720
17794
|
<div class="loading" role="status">
|
|
17721
17795
|
<cs-spinner size="large"></cs-spinner>
|
|
@@ -17726,7 +17800,7 @@ var CsCardsInternal = class extends CsBaseElement {
|
|
|
17726
17800
|
<slot name="empty"></slot>
|
|
17727
17801
|
</div>
|
|
17728
17802
|
` : html48`
|
|
17729
|
-
<ol class=${
|
|
17803
|
+
<ol class=${classMap42(listClasses)} aria-label=${groupLabel}>
|
|
17730
17804
|
${this.items.map((item, i) => this._renderCard(item, i))}
|
|
17731
17805
|
</ol>
|
|
17732
17806
|
`}
|
|
@@ -18156,7 +18230,7 @@ customElements.define("cs-collection-preferences", CsCollectionPreferences);
|
|
|
18156
18230
|
// src/progress-bar/internal.ts
|
|
18157
18231
|
import { css as css110, html as html50, nothing as nothing24 } from "lit";
|
|
18158
18232
|
import { property as property49 } from "lit/decorators.js";
|
|
18159
|
-
import { classMap as
|
|
18233
|
+
import { classMap as classMap43 } from "lit/directives/class-map.js";
|
|
18160
18234
|
|
|
18161
18235
|
// src/progress-bar/styles.ts
|
|
18162
18236
|
import { css as css109 } from "lit";
|
|
@@ -18307,6 +18381,33 @@ var componentStyles48 = css109`
|
|
|
18307
18381
|
|
|
18308
18382
|
// src/progress-bar/internal.ts
|
|
18309
18383
|
var hostStyles49 = css110`:host { display: block; }`;
|
|
18384
|
+
var inventedStyles5 = css110`
|
|
18385
|
+
.label {
|
|
18386
|
+
font-size: var(--font-body-m-size-sregvd, 14px);
|
|
18387
|
+
font-weight: var(--font-body-m-weight-7v1jxr, 400);
|
|
18388
|
+
color: var(--color-text-body-default-ajf1h5, #0f141a);
|
|
18389
|
+
margin-block-end: var(--space-xxs-hwfkai, 4px);
|
|
18390
|
+
}
|
|
18391
|
+
.description {
|
|
18392
|
+
font-size: var(--font-body-s-size-ukbcbk, 12px);
|
|
18393
|
+
color: var(--color-text-body-secondary-fdstdf, #5f6b7a);
|
|
18394
|
+
margin-block-end: var(--space-xs-ymlm0b, 8px);
|
|
18395
|
+
}
|
|
18396
|
+
.result-button-trigger {
|
|
18397
|
+
display: inline-block;
|
|
18398
|
+
margin-block-start: var(--space-xs-ymlm0b, 8px);
|
|
18399
|
+
background: none;
|
|
18400
|
+
border: none;
|
|
18401
|
+
padding: 0;
|
|
18402
|
+
color: var(--color-text-button-inline-icon-default-sm4ql6, #006ce0);
|
|
18403
|
+
cursor: pointer;
|
|
18404
|
+
font-size: inherit;
|
|
18405
|
+
}
|
|
18406
|
+
.result-button-trigger:hover {
|
|
18407
|
+
color: var(--color-text-button-inline-icon-hover-rbyzfc, #002b66);
|
|
18408
|
+
text-decoration: underline;
|
|
18409
|
+
}
|
|
18410
|
+
`;
|
|
18310
18411
|
var CsProgressBarInternal = class extends CsBaseElement {
|
|
18311
18412
|
constructor() {
|
|
18312
18413
|
super(...arguments);
|
|
@@ -18316,7 +18417,7 @@ var CsProgressBarInternal = class extends CsBaseElement {
|
|
|
18316
18417
|
this.ariaLabel = null;
|
|
18317
18418
|
}
|
|
18318
18419
|
static {
|
|
18319
|
-
this.styles = [sharedStyles, componentStyles48, hostStyles49];
|
|
18420
|
+
this.styles = [sharedStyles, componentStyles48, hostStyles49, inventedStyles5];
|
|
18320
18421
|
}
|
|
18321
18422
|
get _clampedValue() {
|
|
18322
18423
|
return Math.round(Math.min(100, Math.max(0, this.value ?? 0)));
|
|
@@ -18337,8 +18438,12 @@ var CsProgressBarInternal = class extends CsBaseElement {
|
|
|
18337
18438
|
};
|
|
18338
18439
|
const statusType = this.status === "success" ? "success" : "error";
|
|
18339
18440
|
return html50`
|
|
18340
|
-
<div class=${
|
|
18341
|
-
<div class
|
|
18441
|
+
<div class=${classMap43(rootClasses)}>
|
|
18442
|
+
<div class=${classMap43({
|
|
18443
|
+
"label": true,
|
|
18444
|
+
"label-flash": this.variant === "flash",
|
|
18445
|
+
"label-key-value": this.variant === "key-value"
|
|
18446
|
+
})}>
|
|
18342
18447
|
<slot name="label"></slot>
|
|
18343
18448
|
</div>
|
|
18344
18449
|
<div class="description">
|
|
@@ -18348,7 +18453,7 @@ var CsProgressBarInternal = class extends CsBaseElement {
|
|
|
18348
18453
|
${isInProgress ? html50`
|
|
18349
18454
|
<div class="progress-container">
|
|
18350
18455
|
<progress
|
|
18351
|
-
class=${
|
|
18456
|
+
class=${classMap43(progressClasses)}
|
|
18352
18457
|
value=${clamped}
|
|
18353
18458
|
max="100"
|
|
18354
18459
|
aria-label=${this.ariaLabel || "Progress"}
|
|
@@ -18359,7 +18464,12 @@ var CsProgressBarInternal = class extends CsBaseElement {
|
|
|
18359
18464
|
<span class="percentage-container">${clamped}%</span>
|
|
18360
18465
|
</div>
|
|
18361
18466
|
` : html50`
|
|
18362
|
-
<div class
|
|
18467
|
+
<div class=${classMap43({
|
|
18468
|
+
"result-state": true,
|
|
18469
|
+
"with-result-button": !!this.resultButtonText,
|
|
18470
|
+
"result-container-error": this.status === "error",
|
|
18471
|
+
"result-container-success": this.status === "success"
|
|
18472
|
+
})}>
|
|
18363
18473
|
<cs-status-indicator type=${statusType}>
|
|
18364
18474
|
<slot name="resultText"></slot>
|
|
18365
18475
|
</cs-status-indicator>
|
|
@@ -18412,7 +18522,7 @@ customElements.define("cs-progress-bar", CsProgressBar);
|
|
|
18412
18522
|
// src/steps/internal.ts
|
|
18413
18523
|
import { css as css112, html as html51, nothing as nothing25 } from "lit";
|
|
18414
18524
|
import { property as property50 } from "lit/decorators.js";
|
|
18415
|
-
import { classMap as
|
|
18525
|
+
import { classMap as classMap44 } from "lit/directives/class-map.js";
|
|
18416
18526
|
|
|
18417
18527
|
// src/steps/styles.ts
|
|
18418
18528
|
import { css as css111 } from "lit";
|
|
@@ -18519,6 +18629,13 @@ var componentStyles49 = css111`
|
|
|
18519
18629
|
|
|
18520
18630
|
// src/steps/internal.ts
|
|
18521
18631
|
var hostStyles50 = css112`:host { display: block; }`;
|
|
18632
|
+
var inventedStyles6 = css112`
|
|
18633
|
+
.title {
|
|
18634
|
+
font-size: var(--font-body-m-size-sregvd, 14px);
|
|
18635
|
+
font-weight: var(--font-heading-s-weight-k8ys7j, 700);
|
|
18636
|
+
color: var(--color-text-body-default-ajf1h5, #0f141a);
|
|
18637
|
+
}
|
|
18638
|
+
`;
|
|
18522
18639
|
var iconNameMap4 = {
|
|
18523
18640
|
"success": "status-positive",
|
|
18524
18641
|
"error": "status-negative",
|
|
@@ -18536,7 +18653,7 @@ var CsStepsInternal = class extends CsBaseElement {
|
|
|
18536
18653
|
this.ariaLabel = null;
|
|
18537
18654
|
}
|
|
18538
18655
|
static {
|
|
18539
|
-
this.styles = [sharedStyles, componentStyles49, hostStyles50];
|
|
18656
|
+
this.styles = [sharedStyles, componentStyles49, hostStyles50, inventedStyles6];
|
|
18540
18657
|
}
|
|
18541
18658
|
_renderIcon(step) {
|
|
18542
18659
|
if (step.status === "loading") {
|
|
@@ -18597,7 +18714,7 @@ var CsStepsInternal = class extends CsBaseElement {
|
|
|
18597
18714
|
};
|
|
18598
18715
|
const total = this.steps.length;
|
|
18599
18716
|
return html51`
|
|
18600
|
-
<div class=${
|
|
18717
|
+
<div class=${classMap44(rootClasses)}>
|
|
18601
18718
|
<ol
|
|
18602
18719
|
class="list"
|
|
18603
18720
|
role="list"
|
|
@@ -18708,6 +18825,12 @@ var layoutStyles = css114`
|
|
|
18708
18825
|
gap: var(--space-scaled-m-m892r9, 16px);
|
|
18709
18826
|
}
|
|
18710
18827
|
`;
|
|
18828
|
+
var inventedStyles7 = css114`
|
|
18829
|
+
.pair {
|
|
18830
|
+
break-inside: avoid;
|
|
18831
|
+
padding-block-end: var(--space-l-t419sm, 20px);
|
|
18832
|
+
}
|
|
18833
|
+
`;
|
|
18711
18834
|
var CsKeyValuePairsInternal = class extends CsBaseElement {
|
|
18712
18835
|
constructor() {
|
|
18713
18836
|
super(...arguments);
|
|
@@ -18716,7 +18839,7 @@ var CsKeyValuePairsInternal = class extends CsBaseElement {
|
|
|
18716
18839
|
this.ariaLabel = null;
|
|
18717
18840
|
}
|
|
18718
18841
|
static {
|
|
18719
|
-
this.styles = [sharedStyles, componentStyles50, layoutStyles, hostStyles51];
|
|
18842
|
+
this.styles = [sharedStyles, componentStyles50, layoutStyles, hostStyles51, inventedStyles7];
|
|
18720
18843
|
}
|
|
18721
18844
|
_renderPair(pair) {
|
|
18722
18845
|
return html52`
|
|
@@ -19178,7 +19301,7 @@ customElements.define("cs-property-filter", CsPropertyFilter);
|
|
|
19178
19301
|
// src/table/internal.ts
|
|
19179
19302
|
import { css as css118, html as html54, nothing as nothing28 } from "lit";
|
|
19180
19303
|
import { property as property53 } from "lit/decorators.js";
|
|
19181
|
-
import { classMap as
|
|
19304
|
+
import { classMap as classMap45 } from "lit/directives/class-map.js";
|
|
19182
19305
|
|
|
19183
19306
|
// src/table/styles.ts
|
|
19184
19307
|
import { css as css117 } from "lit";
|
|
@@ -19624,6 +19747,7 @@ var CsTableInternal = class extends CsBaseElement {
|
|
|
19624
19747
|
render() {
|
|
19625
19748
|
const rootClasses = {
|
|
19626
19749
|
"root": true,
|
|
19750
|
+
"is-visual-refresh": true,
|
|
19627
19751
|
[`content-density-${this.contentDensity}`]: true
|
|
19628
19752
|
};
|
|
19629
19753
|
const headerSecondaryClasses = {
|
|
@@ -19636,9 +19760,9 @@ var CsTableInternal = class extends CsBaseElement {
|
|
|
19636
19760
|
[`variant-${this.variant}`]: true
|
|
19637
19761
|
};
|
|
19638
19762
|
return html54`
|
|
19639
|
-
<div class=${
|
|
19640
|
-
<div class=${
|
|
19641
|
-
<div class=${
|
|
19763
|
+
<div class=${classMap45(rootClasses)}>
|
|
19764
|
+
<div class=${classMap45(headerSecondaryClasses)} style=${this._hasHeader || this._hasTools ? nothing28 : "display:none"}>
|
|
19765
|
+
<div class=${classMap45(headerControlsClasses)}>
|
|
19642
19766
|
<slot name="header" @slotchange=${this._onHeaderSlotChange}></slot>
|
|
19643
19767
|
${this._hasTools ? html54`
|
|
19644
19768
|
<div class="tools">
|
|
@@ -19682,7 +19806,7 @@ var CsTableInternal = class extends CsBaseElement {
|
|
|
19682
19806
|
[`variant-${this.variant}`]: true
|
|
19683
19807
|
};
|
|
19684
19808
|
return html54`
|
|
19685
|
-
<div class=${
|
|
19809
|
+
<div class=${classMap45(wrapperClasses)}>
|
|
19686
19810
|
<table class="table" role="table">
|
|
19687
19811
|
<thead>
|
|
19688
19812
|
<tr>
|
|
@@ -19730,13 +19854,13 @@ var CsTableInternal = class extends CsBaseElement {
|
|
|
19730
19854
|
const widthStyle = col.width ? `width: ${typeof col.width === "number" ? `${col.width}px` : col.width}` : void 0;
|
|
19731
19855
|
return html54`
|
|
19732
19856
|
<th
|
|
19733
|
-
class=${
|
|
19857
|
+
class=${classMap45(cellClasses)}
|
|
19734
19858
|
aria-sort=${ariaSort}
|
|
19735
19859
|
style=${widthStyle ?? nothing28}
|
|
19736
19860
|
@click=${() => this._onSort(col)}
|
|
19737
19861
|
>
|
|
19738
19862
|
<span class="header-cell-text">${col.header}</span>
|
|
19739
|
-
${isSortable ? html54`<span class=${
|
|
19863
|
+
${isSortable ? html54`<span class=${classMap45(iconClasses)}><cs-icon name="caret-down-filled" size="small"></cs-icon></span>` : nothing28}
|
|
19740
19864
|
</th>
|
|
19741
19865
|
`;
|
|
19742
19866
|
}
|
|
@@ -19748,9 +19872,9 @@ var CsTableInternal = class extends CsBaseElement {
|
|
|
19748
19872
|
"row-striped": this.stripedRows && index % 2 === 1
|
|
19749
19873
|
};
|
|
19750
19874
|
return html54`
|
|
19751
|
-
<tr class=${
|
|
19875
|
+
<tr class=${classMap45(rowClasses)} @click=${() => this._onRowClick(item, index)}>
|
|
19752
19876
|
${this._hasSelection ? this._renderSelectionCell(item) : nothing28}
|
|
19753
|
-
${this.columnDefinitions.map((col) => this._renderBodyCell(item, col))}
|
|
19877
|
+
${this.columnDefinitions.map((col) => this._renderBodyCell(item, col, index))}
|
|
19754
19878
|
</tr>
|
|
19755
19879
|
`;
|
|
19756
19880
|
}
|
|
@@ -19777,15 +19901,17 @@ var CsTableInternal = class extends CsBaseElement {
|
|
|
19777
19901
|
</td>
|
|
19778
19902
|
`;
|
|
19779
19903
|
}
|
|
19780
|
-
_renderBodyCell(item, col) {
|
|
19904
|
+
_renderBodyCell(item, col, rowIndex) {
|
|
19781
19905
|
const cellClasses = {
|
|
19782
19906
|
"body-cell": true,
|
|
19783
|
-
"body-cell-wrap": this.wrapLines
|
|
19907
|
+
"body-cell-wrap": this.wrapLines,
|
|
19908
|
+
"body-cell-first-row": rowIndex === 0,
|
|
19909
|
+
"body-cell-last-row": rowIndex === this.items.length - 1
|
|
19784
19910
|
};
|
|
19785
19911
|
const widthStyle = col.width ? `width: ${typeof col.width === "number" ? `${col.width}px` : col.width}` : void 0;
|
|
19786
19912
|
return html54`
|
|
19787
|
-
<td class=${
|
|
19788
|
-
|
|
19913
|
+
<td class=${classMap45(cellClasses)} style=${widthStyle ?? nothing28}>
|
|
19914
|
+
<span class="body-cell-content">${col.cell(item)}</span>
|
|
19789
19915
|
</td>
|
|
19790
19916
|
`;
|
|
19791
19917
|
}
|
|
@@ -19973,7 +20099,7 @@ customElements.define("cs-form", CsForm);
|
|
|
19973
20099
|
// src/modal/internal.ts
|
|
19974
20100
|
import { css as css122, html as html56 } from "lit";
|
|
19975
20101
|
import { property as property55 } from "lit/decorators.js";
|
|
19976
|
-
import { classMap as
|
|
20102
|
+
import { classMap as classMap46 } from "lit/directives/class-map.js";
|
|
19977
20103
|
import { ifDefined as ifDefined27 } from "lit/directives/if-defined.js";
|
|
19978
20104
|
|
|
19979
20105
|
// src/modal/styles.ts
|
|
@@ -20309,12 +20435,12 @@ var CsModalInternal = class extends CsBaseElement {
|
|
|
20309
20435
|
};
|
|
20310
20436
|
return html56`
|
|
20311
20437
|
<div
|
|
20312
|
-
class=${
|
|
20438
|
+
class=${classMap46(rootClasses)}
|
|
20313
20439
|
@click=${this._onBackdropClick}
|
|
20314
20440
|
>
|
|
20315
|
-
<div class=${
|
|
20441
|
+
<div class=${classMap46(focusLockClasses)}>
|
|
20316
20442
|
<div
|
|
20317
|
-
class=${
|
|
20443
|
+
class=${classMap46(dialogClasses)}
|
|
20318
20444
|
role="dialog"
|
|
20319
20445
|
aria-modal="true"
|
|
20320
20446
|
aria-label=${ifDefined27(this.header || void 0)}
|
|
@@ -20334,11 +20460,11 @@ var CsModalInternal = class extends CsBaseElement {
|
|
|
20334
20460
|
</div>
|
|
20335
20461
|
</div>
|
|
20336
20462
|
|
|
20337
|
-
<div class=${
|
|
20463
|
+
<div class=${classMap46(contentClasses)}>
|
|
20338
20464
|
<slot></slot>
|
|
20339
20465
|
</div>
|
|
20340
20466
|
|
|
20341
|
-
${this._hasFooter ? html56`<div class=${
|
|
20467
|
+
${this._hasFooter ? html56`<div class=${classMap46(footerClasses)}><slot name="footer" @slotchange=${this._onFooterSlotChange}></slot></div>` : html56`<slot name="footer" @slotchange=${this._onFooterSlotChange} style="display:none"></slot>`}
|
|
20342
20468
|
</div>
|
|
20343
20469
|
</div>
|
|
20344
20470
|
</div>
|
|
@@ -20373,7 +20499,7 @@ customElements.define("cs-modal", CsModal);
|
|
|
20373
20499
|
// src/file-upload/internal.ts
|
|
20374
20500
|
import { css as css124, html as html57, nothing as nothing30 } from "lit";
|
|
20375
20501
|
import { property as property56 } from "lit/decorators.js";
|
|
20376
|
-
import { classMap as
|
|
20502
|
+
import { classMap as classMap47 } from "lit/directives/class-map.js";
|
|
20377
20503
|
import { ifDefined as ifDefined28 } from "lit/directives/if-defined.js";
|
|
20378
20504
|
|
|
20379
20505
|
// src/file-upload/styles.ts
|
|
@@ -20567,7 +20693,7 @@ var CsFileUploadInternal = class extends CsBaseElement {
|
|
|
20567
20693
|
"file-item-error": !!error
|
|
20568
20694
|
};
|
|
20569
20695
|
return html57`
|
|
20570
|
-
<li class=${
|
|
20696
|
+
<li class=${classMap47(itemClasses)}>
|
|
20571
20697
|
${this.showFileThumbnail && isImage ? html57`<img class="file-thumbnail" src=${this._getThumbnailUrl(file)} alt="" />` : nothing30}
|
|
20572
20698
|
<div class="file-info">
|
|
20573
20699
|
<div class="file-name">${file.name}</div>
|
|
@@ -20614,7 +20740,7 @@ var CsFileUploadInternal = class extends CsBaseElement {
|
|
|
20614
20740
|
${this.errorText ? html57`<div class="error-text">${this.errorText}</div>` : nothing30}
|
|
20615
20741
|
|
|
20616
20742
|
${hasFiles ? html57`
|
|
20617
|
-
<ul class=${
|
|
20743
|
+
<ul class=${classMap47(listClasses)} role="list">
|
|
20618
20744
|
${this.value.map((file, i) => this._renderFileItem(file, i))}
|
|
20619
20745
|
</ul>
|
|
20620
20746
|
` : nothing30}
|
|
@@ -20673,7 +20799,7 @@ customElements.define("cs-file-upload", CsFileUpload);
|
|
|
20673
20799
|
// src/calendar/internal.ts
|
|
20674
20800
|
import { css as css126, html as html58, nothing as nothing31 } from "lit";
|
|
20675
20801
|
import { property as property57, state as state18 } from "lit/decorators.js";
|
|
20676
|
-
import { classMap as
|
|
20802
|
+
import { classMap as classMap48 } from "lit/directives/class-map.js";
|
|
20677
20803
|
import { ifDefined as ifDefined29 } from "lit/directives/if-defined.js";
|
|
20678
20804
|
|
|
20679
20805
|
// src/calendar/styles.ts
|
|
@@ -21163,7 +21289,7 @@ var CsCalendarInternal = class extends CsBaseElement {
|
|
|
21163
21289
|
};
|
|
21164
21290
|
return html58`
|
|
21165
21291
|
<td
|
|
21166
|
-
class=${
|
|
21292
|
+
class=${classMap48(classes)}
|
|
21167
21293
|
role="gridcell"
|
|
21168
21294
|
tabindex=${this._getTabIndex(day)}
|
|
21169
21295
|
aria-selected=${isSelected ? "true" : "false"}
|
|
@@ -21233,7 +21359,7 @@ customElements.define("cs-calendar", CsCalendar);
|
|
|
21233
21359
|
// src/date-input/internal.ts
|
|
21234
21360
|
import { css as css128, html as html59 } from "lit";
|
|
21235
21361
|
import { property as property58 } from "lit/decorators.js";
|
|
21236
|
-
import { classMap as
|
|
21362
|
+
import { classMap as classMap49 } from "lit/directives/class-map.js";
|
|
21237
21363
|
import { ifDefined as ifDefined30 } from "lit/directives/if-defined.js";
|
|
21238
21364
|
import { consume as consume2 } from "@lit/context";
|
|
21239
21365
|
|
|
@@ -21314,7 +21440,7 @@ var CsDateInputInternal = class extends Base9 {
|
|
|
21314
21440
|
<div class="root">
|
|
21315
21441
|
<div class="input-container">
|
|
21316
21442
|
<input
|
|
21317
|
-
class=${
|
|
21443
|
+
class=${classMap49(inputClasses)}
|
|
21318
21444
|
type="text"
|
|
21319
21445
|
.value=${this.value}
|
|
21320
21446
|
placeholder=${ifDefined30(this.placeholder || void 0)}
|
|
@@ -21674,7 +21800,7 @@ customElements.define("cs-date-picker", CsDatePicker);
|
|
|
21674
21800
|
// src/date-range-picker/internal.ts
|
|
21675
21801
|
import { css as css133, html as html61, nothing as nothing33 } from "lit";
|
|
21676
21802
|
import { property as property60, state as state20, query as query8 } from "lit/decorators.js";
|
|
21677
|
-
import { classMap as
|
|
21803
|
+
import { classMap as classMap50 } from "lit/directives/class-map.js";
|
|
21678
21804
|
import { ifDefined as ifDefined32 } from "lit/directives/if-defined.js";
|
|
21679
21805
|
|
|
21680
21806
|
// src/date-range-picker/styles.ts
|
|
@@ -22239,7 +22365,7 @@ var CsDateRangePickerInternal = class extends Base11 {
|
|
|
22239
22365
|
};
|
|
22240
22366
|
weekCells.push(html61`
|
|
22241
22367
|
<td
|
|
22242
|
-
class=${
|
|
22368
|
+
class=${classMap50(dayClasses)}
|
|
22243
22369
|
role="gridcell"
|
|
22244
22370
|
aria-selected=${isEdge ? "true" : "false"}
|
|
22245
22371
|
aria-disabled=${!enabled ? "true" : "false"}
|
|
@@ -22292,13 +22418,13 @@ var CsDateRangePickerInternal = class extends Base11 {
|
|
|
22292
22418
|
<div class="mode-switch" role="tablist"
|
|
22293
22419
|
aria-label=${this.i18nStrings?.modeSelectionLabel ?? "Date range mode"}>
|
|
22294
22420
|
<button
|
|
22295
|
-
class=${
|
|
22421
|
+
class=${classMap50({ "mode-tab": true, "mode-tab-active": this._effectiveMode === "absolute" })}
|
|
22296
22422
|
role="tab"
|
|
22297
22423
|
aria-selected=${this._effectiveMode === "absolute" ? "true" : "false"}
|
|
22298
22424
|
@click=${() => this._onModeSwitch("absolute")}
|
|
22299
22425
|
>${absLabel}</button>
|
|
22300
22426
|
<button
|
|
22301
|
-
class=${
|
|
22427
|
+
class=${classMap50({ "mode-tab": true, "mode-tab-active": this._effectiveMode === "relative" })}
|
|
22302
22428
|
role="tab"
|
|
22303
22429
|
aria-selected=${this._effectiveMode === "relative" ? "true" : "false"}
|
|
22304
22430
|
@click=${() => this._onModeSwitch("relative")}
|
|
@@ -22344,7 +22470,7 @@ var CsDateRangePickerInternal = class extends Base11 {
|
|
|
22344
22470
|
const isSelected = this._selectedRelativeKey === option.key;
|
|
22345
22471
|
const label = this.i18nStrings?.formatRelativeRange ? this.i18nStrings.formatRelativeRange(option) : `Last ${option.amount} ${option.unit}${option.amount !== 1 ? "s" : ""}`;
|
|
22346
22472
|
return html61`
|
|
22347
|
-
<label class=${
|
|
22473
|
+
<label class=${classMap50({
|
|
22348
22474
|
"relative-option": true,
|
|
22349
22475
|
"relative-option-selected": isSelected
|
|
22350
22476
|
})}>
|
|
@@ -22403,7 +22529,7 @@ var CsDateRangePickerInternal = class extends Base11 {
|
|
|
22403
22529
|
<div class="root">
|
|
22404
22530
|
<div class="label ${this.disabled ? "" : "label-enabled"}">
|
|
22405
22531
|
<button
|
|
22406
|
-
class=${
|
|
22532
|
+
class=${classMap50(triggerClasses)}
|
|
22407
22533
|
type="button"
|
|
22408
22534
|
aria-haspopup="dialog"
|
|
22409
22535
|
aria-expanded=${this._open ? "true" : "false"}
|
|
@@ -22424,7 +22550,7 @@ var CsDateRangePickerInternal = class extends Base11 {
|
|
|
22424
22550
|
</button>
|
|
22425
22551
|
</div>
|
|
22426
22552
|
${this._open ? html61`
|
|
22427
|
-
<div class=${
|
|
22553
|
+
<div class=${classMap50(dropdownClasses)} role="dialog"
|
|
22428
22554
|
aria-label=${ifDefined32(this.ariaLabel || "Date range picker")}
|
|
22429
22555
|
aria-modal="true">
|
|
22430
22556
|
${this._renderModeSwitch()}
|
|
@@ -22644,7 +22770,7 @@ var componentStyles60 = css134`
|
|
|
22644
22770
|
// src/input/internal.ts
|
|
22645
22771
|
import { css as css135, html as html62, nothing as nothing34 } from "lit";
|
|
22646
22772
|
import { property as property61 } from "lit/decorators.js";
|
|
22647
|
-
import { classMap as
|
|
22773
|
+
import { classMap as classMap51 } from "lit/directives/class-map.js";
|
|
22648
22774
|
import { ifDefined as ifDefined33 } from "lit/directives/if-defined.js";
|
|
22649
22775
|
import { consume as consume4 } from "@lit/context";
|
|
22650
22776
|
var Base12 = FormAssociatedMixin(CsBaseElement);
|
|
@@ -22744,13 +22870,20 @@ var CsInputInternal = class extends Base12 {
|
|
|
22744
22870
|
"input-has-clear-button": this._showClearButton,
|
|
22745
22871
|
[`input-type-${this.type}`]: true
|
|
22746
22872
|
};
|
|
22873
|
+
const inputContainerClasses = {
|
|
22874
|
+
"input-container": true,
|
|
22875
|
+
"input-invalid": this._isInvalid,
|
|
22876
|
+
"input-warning": this._isWarning,
|
|
22877
|
+
"input-readonly": this.readOnly,
|
|
22878
|
+
[`input-type-${this.type}`]: true
|
|
22879
|
+
};
|
|
22747
22880
|
const controlId = this._formFieldCtx.controlId || void 0;
|
|
22748
22881
|
const ariaLabelledby = this._formFieldCtx.ariaLabelledby || void 0;
|
|
22749
22882
|
return html62`
|
|
22750
22883
|
<div class="root">
|
|
22751
|
-
<div class
|
|
22884
|
+
<div class=${classMap51(inputContainerClasses)}>
|
|
22752
22885
|
<input
|
|
22753
|
-
class=${
|
|
22886
|
+
class=${classMap51(inputClasses)}
|
|
22754
22887
|
type=${this.type}
|
|
22755
22888
|
.value=${this.value}
|
|
22756
22889
|
placeholder=${ifDefined33(this.placeholder || void 0)}
|
|
@@ -22949,7 +23082,7 @@ customElements.define("cs-attribute-editor", CsAttributeEditor);
|
|
|
22949
23082
|
// src/tag-editor/internal.ts
|
|
22950
23083
|
import { css as css138, html as html64, nothing as nothing36 } from "lit";
|
|
22951
23084
|
import { property as property63 } from "lit/decorators.js";
|
|
22952
|
-
import { classMap as
|
|
23085
|
+
import { classMap as classMap52 } from "lit/directives/class-map.js";
|
|
22953
23086
|
|
|
22954
23087
|
// src/tag-editor/styles.ts
|
|
22955
23088
|
import { css as css137 } from "lit";
|
|
@@ -23111,7 +23244,7 @@ var CsTagEditorInternal = class extends CsBaseElement {
|
|
|
23111
23244
|
const keyLabel = this.i18nStrings?.keyHeader ?? "Key";
|
|
23112
23245
|
const valueLabel = this.i18nStrings?.valueHeader ?? "Value";
|
|
23113
23246
|
return html64`
|
|
23114
|
-
<div class=${
|
|
23247
|
+
<div class=${classMap52(rowClasses)} data-row-index="${index}">
|
|
23115
23248
|
<cs-form-field .label=${keyLabel}>
|
|
23116
23249
|
<cs-input
|
|
23117
23250
|
.value=${tag.key}
|
|
@@ -23208,9 +23341,3172 @@ __decorateClass([
|
|
|
23208
23341
|
var CsTagEditor = class extends CsTagEditorInternal {
|
|
23209
23342
|
};
|
|
23210
23343
|
customElements.define("cs-tag-editor", CsTagEditor);
|
|
23344
|
+
|
|
23345
|
+
// src/wizard/internal.ts
|
|
23346
|
+
import { css as css140, html as html65, nothing as nothing37 } from "lit";
|
|
23347
|
+
import { property as property64 } from "lit/decorators.js";
|
|
23348
|
+
import { classMap as classMap53 } from "lit/directives/class-map.js";
|
|
23349
|
+
|
|
23350
|
+
// src/wizard/styles.ts
|
|
23351
|
+
import { css as css139 } from "lit";
|
|
23352
|
+
var componentStyles62 = css139`
|
|
23353
|
+
.root {
|
|
23354
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
23355
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
23356
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
23357
|
+
font-weight: 400;
|
|
23358
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
23359
|
+
-webkit-font-smoothing: auto;
|
|
23360
|
+
-moz-osx-font-smoothing: auto;
|
|
23361
|
+
}
|
|
23362
|
+
|
|
23363
|
+
.wizard.refresh {
|
|
23364
|
+
column-gap: var(--space-xl-jfy3x4, 24px);
|
|
23365
|
+
display: grid;
|
|
23366
|
+
grid-template-columns: auto minmax(0, 1fr);
|
|
23367
|
+
grid-template-rows: auto 1fr;
|
|
23368
|
+
row-gap: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
23369
|
+
}
|
|
23370
|
+
.wizard.refresh.small-container {
|
|
23371
|
+
grid-template-columns: minmax(0, 1fr) 0;
|
|
23372
|
+
grid-template-rows: auto auto 1fr;
|
|
23373
|
+
row-gap: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
23374
|
+
}
|
|
23375
|
+
|
|
23376
|
+
.wizard:not(.refresh) {
|
|
23377
|
+
display: flex;
|
|
23378
|
+
}
|
|
23379
|
+
.wizard:not(.refresh).small-container {
|
|
23380
|
+
flex-direction: column;
|
|
23381
|
+
gap: var(--space-s-tvghoh, 12px);
|
|
23382
|
+
}
|
|
23383
|
+
|
|
23384
|
+
.navigation.refresh {
|
|
23385
|
+
grid-column: 1;
|
|
23386
|
+
grid-row: 1/span 2;
|
|
23387
|
+
padding-block-start: calc(var(--space-xs-ymlm0b, 8px) + var(--space-scaled-xxs-pfm1nx, 4px));
|
|
23388
|
+
|
|
23389
|
+
|
|
23390
|
+
}
|
|
23391
|
+
.navigation.refresh > ul.refresh {
|
|
23392
|
+
position: relative;
|
|
23393
|
+
margin-block: 0;
|
|
23394
|
+
margin-inline: 0;
|
|
23395
|
+
padding-block-start: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
23396
|
+
padding-block-end: 0;
|
|
23397
|
+
padding-inline: 0;
|
|
23398
|
+
inline-size: 260px;
|
|
23399
|
+
box-sizing: border-box;
|
|
23400
|
+
}
|
|
23401
|
+
.navigation.refresh > ul.refresh > li {
|
|
23402
|
+
display: grid;
|
|
23403
|
+
column-gap: var(--space-xs-ymlm0b, 8px);
|
|
23404
|
+
grid-template-columns: var(--space-l-2ud1p3, 20px) 1fr;
|
|
23405
|
+
grid-template-rows: repeat(2, auto);
|
|
23406
|
+
padding-block: 0;
|
|
23407
|
+
padding-inline: 0;
|
|
23408
|
+
}
|
|
23409
|
+
.navigation.refresh > ul.refresh > li > hr {
|
|
23410
|
+
background-color: var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
23411
|
+
border-block: 0;
|
|
23412
|
+
border-inline: 0;
|
|
23413
|
+
grid-column: 1;
|
|
23414
|
+
block-size: 100%;
|
|
23415
|
+
inline-size: var(--space-xxxs-pajhad, 2px);
|
|
23416
|
+
}
|
|
23417
|
+
.navigation.refresh > ul.refresh > li > .number {
|
|
23418
|
+
color: var(--color-text-small-m1tr70, #656871);
|
|
23419
|
+
font-size: var(--font-size-body-s-smc8cv, 12px);
|
|
23420
|
+
grid-column: 2;
|
|
23421
|
+
grid-row: 1;
|
|
23422
|
+
}
|
|
23423
|
+
.navigation.refresh > ul.refresh > li > a {
|
|
23424
|
+
align-items: start;
|
|
23425
|
+
column-gap: var(--space-xs-ymlm0b, 8px);
|
|
23426
|
+
cursor: pointer;
|
|
23427
|
+
display: grid;
|
|
23428
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
23429
|
+
grid-column: 1/span 2;
|
|
23430
|
+
grid-row: 2;
|
|
23431
|
+
grid-template-columns: var(--space-l-2ud1p3, 20px) 1fr;
|
|
23432
|
+
}
|
|
23433
|
+
.navigation.refresh > ul.refresh > li > a > .circle {
|
|
23434
|
+
border-start-start-radius: 100%;
|
|
23435
|
+
border-start-end-radius: 100%;
|
|
23436
|
+
border-end-start-radius: 100%;
|
|
23437
|
+
border-end-end-radius: 100%;
|
|
23438
|
+
grid-column: 1;
|
|
23439
|
+
block-size: 10px;
|
|
23440
|
+
justify-self: center;
|
|
23441
|
+
margin-block-start: 6px;
|
|
23442
|
+
inline-size: 10px;
|
|
23443
|
+
}
|
|
23444
|
+
.navigation.refresh > ul.refresh > li > a > .title {
|
|
23445
|
+
min-inline-size: 0;
|
|
23446
|
+
word-break: break-word;
|
|
23447
|
+
grid-column: 2;
|
|
23448
|
+
}
|
|
23449
|
+
:host-context([data-awsui-focus-visible=true]) .navigation.refresh > ul.refresh > li > a:focus {
|
|
23450
|
+
outline: thin dotted;
|
|
23451
|
+
outline: var(--border-link-focus-ring-outline-1p0hnu, 0);
|
|
23452
|
+
outline-offset: 2px;
|
|
23453
|
+
outline-color: var(--color-border-item-focused-uk47pl, #006ce0);
|
|
23454
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23455
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23456
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23457
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23458
|
+
box-shadow: 0 0 0 var(--border-link-focus-ring-shadow-spread-39uvxr, 2px) var(--color-border-item-focused-uk47pl, #006ce0);
|
|
23459
|
+
}
|
|
23460
|
+
.navigation.refresh > ul.refresh > li:first-child > hr {
|
|
23461
|
+
grid-row: 2/span 2;
|
|
23462
|
+
}
|
|
23463
|
+
.navigation.refresh > ul.refresh > li:not(:first-child) > .number {
|
|
23464
|
+
margin-block-start: var(--space-m-dsumyt, 16px);
|
|
23465
|
+
}
|
|
23466
|
+
.navigation.refresh > ul.refresh > li:last-child > hr {
|
|
23467
|
+
grid-row: 1;
|
|
23468
|
+
}
|
|
23469
|
+
.navigation.refresh > ul.refresh > li:only-of-type > hr {
|
|
23470
|
+
display: none;
|
|
23471
|
+
}
|
|
23472
|
+
.navigation.refresh > ul.refresh > li:not(:first-child):not(:last-child) > hr {
|
|
23473
|
+
grid-row: 1/span 3;
|
|
23474
|
+
}
|
|
23475
|
+
.navigation.refresh > ul.refresh > li.active > a {
|
|
23476
|
+
cursor: text;
|
|
23477
|
+
}
|
|
23478
|
+
.navigation.refresh > ul.refresh > li.active > a > .circle {
|
|
23479
|
+
background-color: var(--color-background-control-checked-ka7kc2, #006ce0);
|
|
23480
|
+
box-shadow: 0 0 0 3px var(--color-background-container-content-6u8rvp, #ffffff), 0 0 0 5px var(--color-background-control-checked-ka7kc2, #006ce0), 0 0 0 7px var(--color-background-container-content-6u8rvp, #ffffff);
|
|
23481
|
+
}
|
|
23482
|
+
.navigation.refresh > ul.refresh > li.active > a > .title {
|
|
23483
|
+
color: var(--color-background-control-checked-ka7kc2, #006ce0);
|
|
23484
|
+
font-weight: 700;
|
|
23485
|
+
}
|
|
23486
|
+
.navigation.refresh > ul.refresh > li.disabled > a {
|
|
23487
|
+
cursor: text;
|
|
23488
|
+
}
|
|
23489
|
+
.navigation.refresh > ul.refresh > li.disabled > a > .circle {
|
|
23490
|
+
background-color: var(--color-background-container-content-6u8rvp, #ffffff);
|
|
23491
|
+
box-shadow: 0 0 0 2px var(--color-text-interactive-disabled-1bqmrl, #b4b4bb), 0 0 0 4px var(--color-background-container-content-6u8rvp, #ffffff);
|
|
23492
|
+
}
|
|
23493
|
+
.navigation.refresh > ul.refresh > li.disabled > a > .title {
|
|
23494
|
+
color: var(--color-text-status-inactive-gy7337, #656871);
|
|
23495
|
+
}
|
|
23496
|
+
.navigation.refresh > ul.refresh > li.enabled > a > .circle {
|
|
23497
|
+
background-color: var(--color-text-interactive-default-ugh9wp, #424650);
|
|
23498
|
+
box-shadow: 0 0 0 2px var(--color-text-interactive-default-ugh9wp, #424650), 0 0 0 4px var(--color-background-container-content-6u8rvp, #ffffff);
|
|
23499
|
+
}
|
|
23500
|
+
.navigation.refresh > ul.refresh > li.enabled > a > .title {
|
|
23501
|
+
color: var(--color-text-interactive-default-ugh9wp, #424650);
|
|
23502
|
+
}
|
|
23503
|
+
.navigation.refresh > ul.refresh > li.enabled > a:hover > .circle {
|
|
23504
|
+
background-color: var(--color-background-control-checked-ka7kc2, #006ce0);
|
|
23505
|
+
box-shadow: 0 0 0 2px var(--color-background-control-checked-ka7kc2, #006ce0), 0 0 0 4px var(--color-background-container-content-6u8rvp, #ffffff);
|
|
23506
|
+
}
|
|
23507
|
+
.navigation.refresh > ul.refresh > li.enabled > a:hover > .title {
|
|
23508
|
+
color: var(--color-background-control-checked-ka7kc2, #006ce0);
|
|
23509
|
+
}
|
|
23510
|
+
|
|
23511
|
+
.navigation:not(.refresh) {
|
|
23512
|
+
color: var(--color-text-disabled-rox5hg, #b4b4bb);
|
|
23513
|
+
display: inline-block;
|
|
23514
|
+
margin-inline-end: calc(2 * var(--space-xxxl-aut1u7, 40px));
|
|
23515
|
+
min-inline-size: 200px;
|
|
23516
|
+
padding-block-start: var(--space-xxs-hwfkai, 4px);
|
|
23517
|
+
inline-size: 200px;
|
|
23518
|
+
|
|
23519
|
+
|
|
23520
|
+
}
|
|
23521
|
+
.navigation:not(.refresh) > ul:not(.refresh) {
|
|
23522
|
+
list-style: none;
|
|
23523
|
+
padding-block: 0;
|
|
23524
|
+
padding-inline: 0;
|
|
23525
|
+
margin-block: 0;
|
|
23526
|
+
margin-inline: 0;
|
|
23527
|
+
}
|
|
23528
|
+
.navigation:not(.refresh) > ul:not(.refresh) > li {
|
|
23529
|
+
min-inline-size: 0;
|
|
23530
|
+
word-break: break-word;
|
|
23531
|
+
padding-block: 0 var(--space-scaled-m-m892r9, 16px);
|
|
23532
|
+
}
|
|
23533
|
+
.navigation:not(.refresh) > ul:not(.refresh) > li:not(:first-child) {
|
|
23534
|
+
margin-block-start: var(--space-scaled-m-m892r9, 16px);
|
|
23535
|
+
}
|
|
23536
|
+
.navigation:not(.refresh) > ul:not(.refresh) > li:not(:last-child) {
|
|
23537
|
+
border-block-end: var(--border-divider-list-width-tdfx1x, 1px) solid var(--color-border-layout-ayg8vb, #c6c6cd);
|
|
23538
|
+
}
|
|
23539
|
+
|
|
23540
|
+
.form:not(.refresh) {
|
|
23541
|
+
min-inline-size: 0;
|
|
23542
|
+
word-break: break-word;
|
|
23543
|
+
inline-size: 100%;
|
|
23544
|
+
}
|
|
23545
|
+
.form:not(.refresh) > .form-header {
|
|
23546
|
+
position: relative;
|
|
23547
|
+
margin-block-end: var(--space-scaled-m-m892r9, 16px);
|
|
23548
|
+
}
|
|
23549
|
+
|
|
23550
|
+
.form.refresh {
|
|
23551
|
+
min-inline-size: 0;
|
|
23552
|
+
word-break: break-word;
|
|
23553
|
+
display: contents;
|
|
23554
|
+
}
|
|
23555
|
+
.form.refresh > .form-header {
|
|
23556
|
+
grid-column: 2;
|
|
23557
|
+
grid-row: 1;
|
|
23558
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
23559
|
+
}
|
|
23560
|
+
.form.refresh > .form-header > .form-header-content {
|
|
23561
|
+
padding-block-start: calc(var(--space-xl-jfy3x4, 24px) + var(--space-scaled-xxxs-oo06c7, 2px));
|
|
23562
|
+
padding-block-end: var(--space-scaled-s-8ozaad, 12px);
|
|
23563
|
+
}
|
|
23564
|
+
.form.refresh > .form-component {
|
|
23565
|
+
grid-column: 2;
|
|
23566
|
+
grid-row: 2;
|
|
23567
|
+
}
|
|
23568
|
+
.form.refresh.small-container > .form-header {
|
|
23569
|
+
grid-column: 1/span 2;
|
|
23570
|
+
grid-row: 2;
|
|
23571
|
+
}
|
|
23572
|
+
.form.refresh.small-container > .form-header > .form-header-content {
|
|
23573
|
+
padding-block-start: 0;
|
|
23574
|
+
}
|
|
23575
|
+
.form.refresh.small-container > .form-component {
|
|
23576
|
+
grid-column: 1/span 2;
|
|
23577
|
+
grid-row: 3;
|
|
23578
|
+
}
|
|
23579
|
+
|
|
23580
|
+
.navigation.hidden {
|
|
23581
|
+
display: none;
|
|
23582
|
+
}
|
|
23583
|
+
|
|
23584
|
+
.collapsed-steps {
|
|
23585
|
+
grid-column: 1/span 2;
|
|
23586
|
+
grid-row: 1;
|
|
23587
|
+
}
|
|
23588
|
+
|
|
23589
|
+
/* Override fixed sidebar width for expandable navigation */
|
|
23590
|
+
.navigation.refresh.collapsed-steps-navigation {
|
|
23591
|
+
grid-column: unset;
|
|
23592
|
+
grid-row: unset;
|
|
23593
|
+
padding-block-start: 0;
|
|
23594
|
+
}
|
|
23595
|
+
.navigation.refresh.collapsed-steps-navigation > ul.refresh {
|
|
23596
|
+
inline-size: 100%;
|
|
23597
|
+
}
|
|
23598
|
+
|
|
23599
|
+
.form-header-component-wrapper {
|
|
23600
|
+
outline: none;
|
|
23601
|
+
}
|
|
23602
|
+
:host-context([data-awsui-focus-visible=true]) .form-header-component-wrapper:focus {
|
|
23603
|
+
outline: thin dotted;
|
|
23604
|
+
outline: var(--border-link-focus-ring-outline-1p0hnu, 0);
|
|
23605
|
+
outline-offset: 2px;
|
|
23606
|
+
outline-color: var(--color-border-item-focused-uk47pl, #006ce0);
|
|
23607
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23608
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23609
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23610
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23611
|
+
box-shadow: 0 0 0 var(--border-link-focus-ring-shadow-spread-39uvxr, 2px) var(--color-border-item-focused-uk47pl, #006ce0);
|
|
23612
|
+
}
|
|
23613
|
+
|
|
23614
|
+
.navigation-link-active {
|
|
23615
|
+
font-weight: 700;
|
|
23616
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
23617
|
+
}
|
|
23618
|
+
|
|
23619
|
+
.navigation-link-disabled {
|
|
23620
|
+
color: var(--color-text-status-inactive-gy7337, #656871);
|
|
23621
|
+
}
|
|
23622
|
+
|
|
23623
|
+
.action-buttons {
|
|
23624
|
+
display: flex;
|
|
23625
|
+
justify-content: flex-end;
|
|
23626
|
+
}
|
|
23627
|
+
`;
|
|
23628
|
+
|
|
23629
|
+
// src/wizard/internal.ts
|
|
23630
|
+
var hostStyles64 = css140`:host { display: block; }`;
|
|
23631
|
+
var CsWizardInternal = class extends CsBaseElement {
|
|
23632
|
+
constructor() {
|
|
23633
|
+
super(...arguments);
|
|
23634
|
+
this.steps = [];
|
|
23635
|
+
this.activeStepIndex = 0;
|
|
23636
|
+
this.allowSkipTo = false;
|
|
23637
|
+
this.submitButtonText = "Submit";
|
|
23638
|
+
this.isLoadingNextStep = false;
|
|
23639
|
+
this.i18nStrings = {};
|
|
23640
|
+
}
|
|
23641
|
+
static {
|
|
23642
|
+
this.styles = [sharedStyles, componentStyles62, hostStyles64];
|
|
23643
|
+
}
|
|
23644
|
+
get _cancelText() {
|
|
23645
|
+
return this.i18nStrings?.cancelButton ?? "Cancel";
|
|
23646
|
+
}
|
|
23647
|
+
get _previousText() {
|
|
23648
|
+
return this.i18nStrings?.previousButton ?? "Previous";
|
|
23649
|
+
}
|
|
23650
|
+
get _nextText() {
|
|
23651
|
+
return this.i18nStrings?.nextButton ?? "Next";
|
|
23652
|
+
}
|
|
23653
|
+
get _submitText() {
|
|
23654
|
+
return this.submitButtonText ?? this.i18nStrings?.submitButton ?? "Submit";
|
|
23655
|
+
}
|
|
23656
|
+
get _optionalText() {
|
|
23657
|
+
return this.i18nStrings?.optional ?? "- optional";
|
|
23658
|
+
}
|
|
23659
|
+
get _clampedIndex() {
|
|
23660
|
+
const max2 = Math.max(0, this.steps.length - 1);
|
|
23661
|
+
return Math.min(Math.max(0, this.activeStepIndex), max2);
|
|
23662
|
+
}
|
|
23663
|
+
get _isLastStep() {
|
|
23664
|
+
return this._clampedIndex === this.steps.length - 1;
|
|
23665
|
+
}
|
|
23666
|
+
_onCancel() {
|
|
23667
|
+
fireNonCancelableEvent(this, "cancel", {});
|
|
23668
|
+
}
|
|
23669
|
+
_onPrevious() {
|
|
23670
|
+
if (this._clampedIndex > 0) {
|
|
23671
|
+
fireNonCancelableEvent(this, "navigate", {
|
|
23672
|
+
requestedStepIndex: this._clampedIndex - 1,
|
|
23673
|
+
reason: "previous"
|
|
23674
|
+
});
|
|
23675
|
+
}
|
|
23676
|
+
}
|
|
23677
|
+
_onNext() {
|
|
23678
|
+
if (this._isLastStep) {
|
|
23679
|
+
fireNonCancelableEvent(this, "submit", {});
|
|
23680
|
+
} else {
|
|
23681
|
+
fireNonCancelableEvent(this, "navigate", {
|
|
23682
|
+
requestedStepIndex: this._clampedIndex + 1,
|
|
23683
|
+
reason: "next"
|
|
23684
|
+
});
|
|
23685
|
+
}
|
|
23686
|
+
}
|
|
23687
|
+
_onStepClick(index) {
|
|
23688
|
+
if (index < this._clampedIndex) {
|
|
23689
|
+
fireNonCancelableEvent(this, "navigate", {
|
|
23690
|
+
requestedStepIndex: index,
|
|
23691
|
+
reason: "step"
|
|
23692
|
+
});
|
|
23693
|
+
}
|
|
23694
|
+
}
|
|
23695
|
+
_stepNumberLabel(n) {
|
|
23696
|
+
return this.i18nStrings?.stepNumberLabel?.(n) ?? `Step ${n}`;
|
|
23697
|
+
}
|
|
23698
|
+
_renderNavigation() {
|
|
23699
|
+
const activeIdx = this._clampedIndex;
|
|
23700
|
+
const navLabel = this.i18nStrings?.navigationAriaLabel ?? "Steps";
|
|
23701
|
+
return html65`
|
|
23702
|
+
<nav class="navigation refresh" aria-label=${navLabel}>
|
|
23703
|
+
<ul class="refresh" role="list">
|
|
23704
|
+
${this.steps.map((step, i) => {
|
|
23705
|
+
const isActive = i === activeIdx;
|
|
23706
|
+
const isEnabled = i < activeIdx;
|
|
23707
|
+
const isDisabled = i > activeIdx;
|
|
23708
|
+
const classes = {
|
|
23709
|
+
"active": isActive,
|
|
23710
|
+
"enabled": isEnabled,
|
|
23711
|
+
"disabled": isDisabled
|
|
23712
|
+
};
|
|
23713
|
+
const stepNum = i + 1;
|
|
23714
|
+
const optionalLabel = step.isOptional ? ` ${this._optionalText}` : "";
|
|
23715
|
+
return html65`
|
|
23716
|
+
<li class=${classMap53(classes)}>
|
|
23717
|
+
<hr aria-hidden="true" />
|
|
23718
|
+
<span class="number">${this._stepNumberLabel(stepNum)}</span>
|
|
23719
|
+
<a
|
|
23720
|
+
class="navigation-link"
|
|
23721
|
+
role=${isEnabled ? "button" : "text"}
|
|
23722
|
+
tabindex=${isEnabled ? "0" : "-1"}
|
|
23723
|
+
aria-current=${isActive ? "step" : nothing37}
|
|
23724
|
+
aria-disabled=${isDisabled ? "true" : nothing37}
|
|
23725
|
+
@click=${isEnabled ? () => this._onStepClick(i) : nothing37}
|
|
23726
|
+
@keydown=${isEnabled ? (e) => {
|
|
23727
|
+
if (e.key === "Enter" || e.key === " ") {
|
|
23728
|
+
e.preventDefault();
|
|
23729
|
+
this._onStepClick(i);
|
|
23730
|
+
}
|
|
23731
|
+
} : nothing37}
|
|
23732
|
+
>
|
|
23733
|
+
<span class="circle"></span>
|
|
23734
|
+
<span class="title">${step.title}${optionalLabel}</span>
|
|
23735
|
+
</a>
|
|
23736
|
+
</li>
|
|
23737
|
+
`;
|
|
23738
|
+
})}
|
|
23739
|
+
</ul>
|
|
23740
|
+
</nav>
|
|
23741
|
+
`;
|
|
23742
|
+
}
|
|
23743
|
+
_renderFormHeader() {
|
|
23744
|
+
const step = this.steps[this._clampedIndex];
|
|
23745
|
+
if (!step) return html65``;
|
|
23746
|
+
const optionalLabel = step.isOptional ? ` ${this._optionalText}` : "";
|
|
23747
|
+
return html65`
|
|
23748
|
+
<div class="form-header">
|
|
23749
|
+
<div class="form-header-content">
|
|
23750
|
+
<h2 class="form-header-component-wrapper" tabindex="-1">
|
|
23751
|
+
${this._stepNumberLabel(this._clampedIndex + 1)}
|
|
23752
|
+
<span>${step.title}${optionalLabel}</span>
|
|
23753
|
+
</h2>
|
|
23754
|
+
${step.description ? html65`<p>${step.description}</p>` : nothing37}
|
|
23755
|
+
</div>
|
|
23756
|
+
</div>
|
|
23757
|
+
`;
|
|
23758
|
+
}
|
|
23759
|
+
_renderFormContent() {
|
|
23760
|
+
const step = this.steps[this._clampedIndex];
|
|
23761
|
+
if (!step) return html65``;
|
|
23762
|
+
return html65`
|
|
23763
|
+
<div class="form-component">
|
|
23764
|
+
${step.errorText ? html65`
|
|
23765
|
+
<cs-alert type="error" aria-label=${this.i18nStrings?.errorIconAriaLabel ?? "Error"}>
|
|
23766
|
+
${step.errorText}
|
|
23767
|
+
</cs-alert>
|
|
23768
|
+
` : nothing37}
|
|
23769
|
+
<div class="step-content">${step.content}</div>
|
|
23770
|
+
</div>
|
|
23771
|
+
`;
|
|
23772
|
+
}
|
|
23773
|
+
_renderActionButtons() {
|
|
23774
|
+
const isFirst = this._clampedIndex === 0;
|
|
23775
|
+
return html65`
|
|
23776
|
+
<div class="action-buttons">
|
|
23777
|
+
<div class="action-buttons-left">
|
|
23778
|
+
<cs-button
|
|
23779
|
+
variant="link"
|
|
23780
|
+
@click=${() => this._onCancel()}
|
|
23781
|
+
>${this._cancelText}</cs-button>
|
|
23782
|
+
</div>
|
|
23783
|
+
<div class="action-buttons-right">
|
|
23784
|
+
${!isFirst ? html65`
|
|
23785
|
+
<cs-button
|
|
23786
|
+
variant="normal"
|
|
23787
|
+
@click=${() => this._onPrevious()}
|
|
23788
|
+
>${this._previousText}</cs-button>
|
|
23789
|
+
` : nothing37}
|
|
23790
|
+
<cs-button
|
|
23791
|
+
variant="primary"
|
|
23792
|
+
?loading=${this.isLoadingNextStep}
|
|
23793
|
+
@click=${() => this._onNext()}
|
|
23794
|
+
>${this._isLastStep ? this._submitText : this._nextText}</cs-button>
|
|
23795
|
+
</div>
|
|
23796
|
+
</div>
|
|
23797
|
+
`;
|
|
23798
|
+
}
|
|
23799
|
+
render() {
|
|
23800
|
+
if (this.steps.length === 0) {
|
|
23801
|
+
return html65`<div class="root"></div>`;
|
|
23802
|
+
}
|
|
23803
|
+
return html65`
|
|
23804
|
+
<div class="root">
|
|
23805
|
+
<div class="wizard refresh" role="group">
|
|
23806
|
+
${this._renderNavigation()}
|
|
23807
|
+
<div class="form refresh">
|
|
23808
|
+
${this._renderFormHeader()}
|
|
23809
|
+
${this._renderFormContent()}
|
|
23810
|
+
</div>
|
|
23811
|
+
</div>
|
|
23812
|
+
${this._renderActionButtons()}
|
|
23813
|
+
</div>
|
|
23814
|
+
`;
|
|
23815
|
+
}
|
|
23816
|
+
};
|
|
23817
|
+
__decorateClass([
|
|
23818
|
+
property64({ attribute: false })
|
|
23819
|
+
], CsWizardInternal.prototype, "steps", 2);
|
|
23820
|
+
__decorateClass([
|
|
23821
|
+
property64({ type: Number })
|
|
23822
|
+
], CsWizardInternal.prototype, "activeStepIndex", 2);
|
|
23823
|
+
__decorateClass([
|
|
23824
|
+
property64({ type: Boolean })
|
|
23825
|
+
], CsWizardInternal.prototype, "allowSkipTo", 2);
|
|
23826
|
+
__decorateClass([
|
|
23827
|
+
property64({ type: String })
|
|
23828
|
+
], CsWizardInternal.prototype, "submitButtonText", 2);
|
|
23829
|
+
__decorateClass([
|
|
23830
|
+
property64({ type: Boolean })
|
|
23831
|
+
], CsWizardInternal.prototype, "isLoadingNextStep", 2);
|
|
23832
|
+
__decorateClass([
|
|
23833
|
+
property64({ attribute: false })
|
|
23834
|
+
], CsWizardInternal.prototype, "i18nStrings", 2);
|
|
23835
|
+
|
|
23836
|
+
// src/wizard/index.ts
|
|
23837
|
+
var CsWizard = class extends CsWizardInternal {
|
|
23838
|
+
};
|
|
23839
|
+
customElements.define("cs-wizard", CsWizard);
|
|
23840
|
+
|
|
23841
|
+
// src/code-editor/internal.ts
|
|
23842
|
+
import { css as css142, html as html66 } from "lit";
|
|
23843
|
+
import { property as property65 } from "lit/decorators.js";
|
|
23844
|
+
import { classMap as classMap54 } from "lit/directives/class-map.js";
|
|
23845
|
+
|
|
23846
|
+
// src/code-editor/styles.ts
|
|
23847
|
+
import { css as css141 } from "lit";
|
|
23848
|
+
var componentStyles63 = css141`
|
|
23849
|
+
.pane {
|
|
23850
|
+
display: flex;
|
|
23851
|
+
position: relative;
|
|
23852
|
+
flex-direction: row;
|
|
23853
|
+
flex: 1;
|
|
23854
|
+
border-block-start: var(--border-item-width-miijiw, 2px) solid var(--color-border-code-editor-default-2bfcfq, #dedee3);
|
|
23855
|
+
border-end-start-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23856
|
+
border-end-end-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23857
|
+
background: var(--color-background-code-editor-status-bar-yjtxod, #f3f3f7);
|
|
23858
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
23859
|
+
}
|
|
23860
|
+
.pane__close-container {
|
|
23861
|
+
position: absolute;
|
|
23862
|
+
inset-block-start: 0;
|
|
23863
|
+
inset-inline-end: calc(var(--space-s-tvghoh, 12px) / 2);
|
|
23864
|
+
}
|
|
23865
|
+
.pane__list {
|
|
23866
|
+
flex: 1;
|
|
23867
|
+
overflow: auto;
|
|
23868
|
+
max-block-size: 100%;
|
|
23869
|
+
box-sizing: border-box;
|
|
23870
|
+
margin-inline-end: calc(var(--line-height-body-m-2mh3ke, 20px) + 2 * var(--space-xs-ymlm0b, 8px));
|
|
23871
|
+
}
|
|
23872
|
+
.pane__table {
|
|
23873
|
+
inline-size: 100%;
|
|
23874
|
+
border-spacing: 0;
|
|
23875
|
+
margin-block: var(--space-s-tvghoh, 12px);
|
|
23876
|
+
margin-inline: 0;
|
|
23877
|
+
}
|
|
23878
|
+
.pane__item > .pane__cell {
|
|
23879
|
+
border-block-start: var(--border-item-width-miijiw, 2px) solid var(--color-transparent-i61gs1, transparent);
|
|
23880
|
+
border-block-end: var(--border-item-width-miijiw, 2px) solid var(--color-transparent-i61gs1, transparent);
|
|
23881
|
+
}
|
|
23882
|
+
.pane__item > .pane__cell:first-child {
|
|
23883
|
+
border-inline-start: var(--border-item-width-miijiw, 2px) solid var(--color-transparent-i61gs1, transparent);
|
|
23884
|
+
border-start-start-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23885
|
+
border-end-start-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23886
|
+
}
|
|
23887
|
+
.pane__item > .pane__cell:last-child {
|
|
23888
|
+
border-inline-end: var(--border-item-width-miijiw, 2px) solid var(--color-transparent-i61gs1, transparent);
|
|
23889
|
+
border-start-end-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23890
|
+
border-end-end-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23891
|
+
}
|
|
23892
|
+
.pane__item--highlighted, .pane__item:hover, .pane__item:focus {
|
|
23893
|
+
cursor: pointer;
|
|
23894
|
+
outline: none;
|
|
23895
|
+
}
|
|
23896
|
+
.pane__item--highlighted > .pane__cell, .pane__item:hover > .pane__cell, .pane__item:focus > .pane__cell {
|
|
23897
|
+
background-color: var(--color-background-code-editor-pane-item-hover-z6k9mr, #ebebf0);
|
|
23898
|
+
}
|
|
23899
|
+
.pane__item--highlighted > .pane__cell, .pane__item:hover > .pane__cell, .pane__item:focus > .pane__cell {
|
|
23900
|
+
border-block-start: var(--border-item-width-miijiw, 2px) solid var(--color-border-code-editor-pane-item-hover-wvblek, #8c8c94);
|
|
23901
|
+
border-block-end: var(--border-item-width-miijiw, 2px) solid var(--color-border-code-editor-pane-item-hover-wvblek, #8c8c94);
|
|
23902
|
+
}
|
|
23903
|
+
.pane__item--highlighted > .pane__cell:first-child, .pane__item:hover > .pane__cell:first-child, .pane__item:focus > .pane__cell:first-child {
|
|
23904
|
+
border-inline-start: var(--border-item-width-miijiw, 2px) solid var(--color-border-code-editor-pane-item-hover-wvblek, #8c8c94);
|
|
23905
|
+
border-start-start-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23906
|
+
border-end-start-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23907
|
+
}
|
|
23908
|
+
.pane__item--highlighted > .pane__cell:last-child, .pane__item:hover > .pane__cell:last-child, .pane__item:focus > .pane__cell:last-child {
|
|
23909
|
+
border-inline-end: var(--border-item-width-miijiw, 2px) solid var(--color-border-code-editor-pane-item-hover-wvblek, #8c8c94);
|
|
23910
|
+
border-start-end-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23911
|
+
border-end-end-radius: var(--border-radius-item-iwaia5, 8px);
|
|
23912
|
+
}
|
|
23913
|
+
.pane__location, .pane__description {
|
|
23914
|
+
padding-block: var(--space-xxs-hwfkai, 4px);
|
|
23915
|
+
padding-inline: var(--space-s-tvghoh, 12px);
|
|
23916
|
+
}
|
|
23917
|
+
.pane__location {
|
|
23918
|
+
vertical-align: baseline;
|
|
23919
|
+
white-space: nowrap;
|
|
23920
|
+
padding-inline-start: calc(var(--space-l-2ud1p3, 20px) + var(--space-s-tvghoh, 12px));
|
|
23921
|
+
}
|
|
23922
|
+
.pane__description {
|
|
23923
|
+
padding-inline-end: 0;
|
|
23924
|
+
min-inline-size: 0;
|
|
23925
|
+
word-break: break-word;
|
|
23926
|
+
}
|
|
23927
|
+
|
|
23928
|
+
.focus-lock {
|
|
23929
|
+
block-size: 100%;
|
|
23930
|
+
}
|
|
23931
|
+
|
|
23932
|
+
.code-editor {
|
|
23933
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
23934
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
23935
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
23936
|
+
font-weight: 400;
|
|
23937
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
23938
|
+
-webkit-font-smoothing: auto;
|
|
23939
|
+
-moz-osx-font-smoothing: auto;
|
|
23940
|
+
display: block;
|
|
23941
|
+
border-block: var(--border-width-field-2xc78x, 1px) solid var(--color-border-code-editor-default-2bfcfq, #dedee3);
|
|
23942
|
+
border-inline: var(--border-width-field-2xc78x, 1px) solid var(--color-border-code-editor-default-2bfcfq, #dedee3);
|
|
23943
|
+
border-start-start-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23944
|
+
border-start-end-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23945
|
+
border-end-start-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23946
|
+
border-end-end-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23947
|
+
inline-size: 100%;
|
|
23948
|
+
}
|
|
23949
|
+
|
|
23950
|
+
.editor {
|
|
23951
|
+
position: absolute;
|
|
23952
|
+
inset: 0;
|
|
23953
|
+
}
|
|
23954
|
+
.editor:focus {
|
|
23955
|
+
position: relative;
|
|
23956
|
+
}
|
|
23957
|
+
.editor:focus {
|
|
23958
|
+
outline: 2px dotted transparent;
|
|
23959
|
+
outline-offset: calc(3px - 1px);
|
|
23960
|
+
}
|
|
23961
|
+
.editor:focus::before {
|
|
23962
|
+
content: " ";
|
|
23963
|
+
display: block;
|
|
23964
|
+
position: absolute;
|
|
23965
|
+
inset-inline-start: calc(-1 * 3px);
|
|
23966
|
+
inset-block-start: calc(-1 * 3px);
|
|
23967
|
+
inline-size: calc(100% + 3px + 3px);
|
|
23968
|
+
block-size: calc(100% + 3px + 3px);
|
|
23969
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23970
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23971
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23972
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
23973
|
+
box-shadow: 0 0 0 2px var(--color-border-item-focused-uk47pl, #006ce0);
|
|
23974
|
+
}
|
|
23975
|
+
.editor:focus {
|
|
23976
|
+
position: absolute;
|
|
23977
|
+
overflow: visible;
|
|
23978
|
+
}
|
|
23979
|
+
|
|
23980
|
+
.editor-refresh {
|
|
23981
|
+
border-start-start-radius: calc(var(--border-radius-code-editor-5palck, 8px) - var(--border-item-width-miijiw, 2px));
|
|
23982
|
+
border-start-end-radius: calc(var(--border-radius-code-editor-5palck, 8px) - var(--border-item-width-miijiw, 2px));
|
|
23983
|
+
}
|
|
23984
|
+
|
|
23985
|
+
.status-bar {
|
|
23986
|
+
container-type: inline-size;
|
|
23987
|
+
display: flex;
|
|
23988
|
+
vertical-align: middle;
|
|
23989
|
+
border-block-start: var(--border-width-field-2xc78x, 1px) solid var(--color-border-code-editor-default-2bfcfq, #dedee3);
|
|
23990
|
+
background-color: var(--color-background-code-editor-status-bar-yjtxod, #f3f3f7);
|
|
23991
|
+
min-inline-size: 0;
|
|
23992
|
+
word-break: break-word;
|
|
23993
|
+
}
|
|
23994
|
+
.status-bar-with-hidden-pane {
|
|
23995
|
+
border-end-start-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23996
|
+
border-end-end-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
23997
|
+
}
|
|
23998
|
+
.status-bar__left {
|
|
23999
|
+
flex: 1;
|
|
24000
|
+
display: flex;
|
|
24001
|
+
flex-wrap: wrap;
|
|
24002
|
+
padding-inline-start: var(--space-l-2ud1p3, 20px);
|
|
24003
|
+
border-inline-end: var(--border-width-field-2xc78x, 1px) solid var(--color-border-code-editor-default-2bfcfq, #dedee3);
|
|
24004
|
+
}
|
|
24005
|
+
.status-bar__right {
|
|
24006
|
+
display: flex;
|
|
24007
|
+
align-items: center;
|
|
24008
|
+
}
|
|
24009
|
+
.status-bar__language-mode, .status-bar__cursor-position {
|
|
24010
|
+
display: inline-block;
|
|
24011
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
24012
|
+
padding-block: var(--space-scaled-xs-xwoogq, 8px);
|
|
24013
|
+
padding-inline: var(--space-s-tvghoh, 12px);
|
|
24014
|
+
}
|
|
24015
|
+
.status-bar__cog-button {
|
|
24016
|
+
padding-block: calc(var(--space-scaled-xxs-pfm1nx, 4px) - 1px);
|
|
24017
|
+
padding-inline: calc(var(--space-xs-ymlm0b, 8px) - 2px);
|
|
24018
|
+
}
|
|
24019
|
+
|
|
24020
|
+
.tab-list {
|
|
24021
|
+
align-items: center;
|
|
24022
|
+
display: inline-flex;
|
|
24023
|
+
}
|
|
24024
|
+
|
|
24025
|
+
.tab-button {
|
|
24026
|
+
position: relative;
|
|
24027
|
+
display: inline-flex;
|
|
24028
|
+
gap: var(--space-xxs-hwfkai, 4px);
|
|
24029
|
+
padding-block: var(--space-scaled-xs-xwoogq, 8px);
|
|
24030
|
+
padding-inline: var(--space-s-tvghoh, 12px);
|
|
24031
|
+
line-height: inherit;
|
|
24032
|
+
color: var(--color-text-status-error-ksqavh, #db0000);
|
|
24033
|
+
background: none;
|
|
24034
|
+
border-block: none;
|
|
24035
|
+
border-inline: none;
|
|
24036
|
+
font-weight: bold;
|
|
24037
|
+
outline: none;
|
|
24038
|
+
cursor: pointer;
|
|
24039
|
+
z-index: 1;
|
|
24040
|
+
}
|
|
24041
|
+
.tab-button:hover {
|
|
24042
|
+
color: var(--color-text-code-editor-tab-button-error-avwh01, #ffffff);
|
|
24043
|
+
background: var(--color-text-status-error-ksqavh, #db0000);
|
|
24044
|
+
}
|
|
24045
|
+
.tab-button::after {
|
|
24046
|
+
content: "";
|
|
24047
|
+
position: absolute;
|
|
24048
|
+
inset-inline: 0;
|
|
24049
|
+
inset-block-end: 0;
|
|
24050
|
+
block-size: var(--border-active-width-axzm24, 4px);
|
|
24051
|
+
border-start-start-radius: var(--border-radius-tabs-focus-ring-o4qku1, 20px);
|
|
24052
|
+
border-start-end-radius: var(--border-radius-tabs-focus-ring-o4qku1, 20px);
|
|
24053
|
+
border-end-start-radius: var(--border-radius-tabs-focus-ring-o4qku1, 20px);
|
|
24054
|
+
border-end-end-radius: var(--border-radius-tabs-focus-ring-o4qku1, 20px);
|
|
24055
|
+
background: var(--color-text-status-error-ksqavh, #db0000);
|
|
24056
|
+
opacity: 0;
|
|
24057
|
+
}
|
|
24058
|
+
.tab-button--refresh {
|
|
24059
|
+
padding-block-end: calc(var(--space-scaled-xs-xwoogq, 8px) + var(--border-active-width-axzm24, 4px) - 2px);
|
|
24060
|
+
}
|
|
24061
|
+
.tab-button--warnings {
|
|
24062
|
+
color: var(--color-text-status-warning-6meo06, #855900);
|
|
24063
|
+
}
|
|
24064
|
+
.tab-button--warnings:hover {
|
|
24065
|
+
background: var(--color-text-status-warning-6meo06, #855900);
|
|
24066
|
+
}
|
|
24067
|
+
.tab-button--warnings::after {
|
|
24068
|
+
background: var(--color-text-status-warning-6meo06, #855900);
|
|
24069
|
+
}
|
|
24070
|
+
.tab-button--active::after {
|
|
24071
|
+
opacity: 1;
|
|
24072
|
+
}
|
|
24073
|
+
.tab-button--refresh::after {
|
|
24074
|
+
transition: opacity var(--motion-duration-refresh-only-medium-5rbn3k, 165ms) var(--motion-easing-refresh-only-c-cxy2sk, cubic-bezier(0.84, 0, 0.16, 1));
|
|
24075
|
+
}
|
|
24076
|
+
@media (prefers-reduced-motion: reduce) {
|
|
24077
|
+
.tab-button--refresh::after {
|
|
24078
|
+
animation: none;
|
|
24079
|
+
transition: none;
|
|
24080
|
+
}
|
|
24081
|
+
}
|
|
24082
|
+
.awsui-motion-disabled .tab-button--refresh::after, .awsui-mode-entering .tab-button--refresh::after {
|
|
24083
|
+
animation: none;
|
|
24084
|
+
transition: none;
|
|
24085
|
+
}
|
|
24086
|
+
.tab-button--disabled {
|
|
24087
|
+
font-weight: normal;
|
|
24088
|
+
color: var(--color-text-code-editor-status-bar-disabled-xxmtlc, #8c8c94);
|
|
24089
|
+
cursor: default;
|
|
24090
|
+
}
|
|
24091
|
+
.tab-button--disabled:hover {
|
|
24092
|
+
color: var(--color-text-code-editor-status-bar-disabled-xxmtlc, #8c8c94);
|
|
24093
|
+
background: transparent;
|
|
24094
|
+
}
|
|
24095
|
+
.tab-button--disabled::after {
|
|
24096
|
+
display: none;
|
|
24097
|
+
}
|
|
24098
|
+
:host-context([data-awsui-focus-visible=true]) .tab-button:focus {
|
|
24099
|
+
position: relative;
|
|
24100
|
+
}
|
|
24101
|
+
:host-context([data-awsui-focus-visible=true]) .tab-button:focus {
|
|
24102
|
+
outline: 2px dotted transparent;
|
|
24103
|
+
outline-offset: calc(var(--space-code-editor-status-focus-outline-gutter-o87hra, -7px) - 1px);
|
|
24104
|
+
}
|
|
24105
|
+
:host-context([data-awsui-focus-visible=true]) .tab-button:focus::before {
|
|
24106
|
+
content: " ";
|
|
24107
|
+
display: block;
|
|
24108
|
+
position: absolute;
|
|
24109
|
+
inset-inline-start: calc(-1 * var(--space-code-editor-status-focus-outline-gutter-o87hra, -7px));
|
|
24110
|
+
inset-block-start: calc(-1 * var(--space-code-editor-status-focus-outline-gutter-o87hra, -7px));
|
|
24111
|
+
inline-size: calc(100% + var(--space-code-editor-status-focus-outline-gutter-o87hra, -7px) + var(--space-code-editor-status-focus-outline-gutter-o87hra, -7px));
|
|
24112
|
+
block-size: calc(100% + var(--space-code-editor-status-focus-outline-gutter-o87hra, -7px) + var(--space-code-editor-status-focus-outline-gutter-o87hra, -7px));
|
|
24113
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24114
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24115
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24116
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24117
|
+
box-shadow: 0 0 0 2px var(--color-border-item-focused-uk47pl, #006ce0);
|
|
24118
|
+
}
|
|
24119
|
+
.tab-button--divider {
|
|
24120
|
+
display: inline-block;
|
|
24121
|
+
block-size: var(--line-height-body-m-2mh3ke, 20px);
|
|
24122
|
+
inline-size: var(--border-code-editor-status-divider-width-4we6jf, 1px);
|
|
24123
|
+
background: var(--color-border-tabs-divider-f5t9va, #c6c6cd);
|
|
24124
|
+
vertical-align: middle;
|
|
24125
|
+
}
|
|
24126
|
+
@supports (contain: inline-size) {
|
|
24127
|
+
@container not (max-width: 500px) {
|
|
24128
|
+
.tab-button > .count {
|
|
24129
|
+
display: none;
|
|
24130
|
+
}
|
|
24131
|
+
.tab-button > .text {
|
|
24132
|
+
display: inline;
|
|
24133
|
+
}
|
|
24134
|
+
}
|
|
24135
|
+
@container (max-width: 500px) {
|
|
24136
|
+
.tab-button > .count {
|
|
24137
|
+
display: inline;
|
|
24138
|
+
}
|
|
24139
|
+
.tab-button > .text {
|
|
24140
|
+
display: none;
|
|
24141
|
+
}
|
|
24142
|
+
}
|
|
24143
|
+
}
|
|
24144
|
+
@supports not (contain: inline-size) {
|
|
24145
|
+
.tab-button > .count {
|
|
24146
|
+
display: none;
|
|
24147
|
+
}
|
|
24148
|
+
.tab-button > .text {
|
|
24149
|
+
display: inline;
|
|
24150
|
+
}
|
|
24151
|
+
}
|
|
24152
|
+
|
|
24153
|
+
.loading-screen,
|
|
24154
|
+
.error-screen {
|
|
24155
|
+
display: flex;
|
|
24156
|
+
align-items: center;
|
|
24157
|
+
justify-content: center;
|
|
24158
|
+
block-size: 480px;
|
|
24159
|
+
color: var(--color-text-body-secondary-yna5sb, #424650);
|
|
24160
|
+
background: var(--color-background-code-editor-loading-6nwpin, #f9f9fa);
|
|
24161
|
+
border-start-start-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
24162
|
+
border-start-end-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
24163
|
+
border-end-start-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
24164
|
+
border-end-end-radius: var(--border-radius-code-editor-5palck, 8px);
|
|
24165
|
+
}
|
|
24166
|
+
|
|
24167
|
+
.error-screen {
|
|
24168
|
+
color: var(--color-text-status-error-ksqavh, #db0000);
|
|
24169
|
+
}
|
|
24170
|
+
`;
|
|
24171
|
+
|
|
24172
|
+
// src/code-editor/internal.ts
|
|
24173
|
+
var hostStyles65 = css142`
|
|
24174
|
+
:host { display: block; }
|
|
24175
|
+
.editor-wrapper {
|
|
24176
|
+
position: relative;
|
|
24177
|
+
overflow: hidden;
|
|
24178
|
+
}
|
|
24179
|
+
.editor-textarea {
|
|
24180
|
+
box-sizing: border-box;
|
|
24181
|
+
width: 100%;
|
|
24182
|
+
height: 100%;
|
|
24183
|
+
resize: none;
|
|
24184
|
+
border: none;
|
|
24185
|
+
outline: none;
|
|
24186
|
+
padding: 0;
|
|
24187
|
+
padding-inline-start: var(--space-xl-jfy3x4, 24px);
|
|
24188
|
+
font-family: "Monaco", "Menlo", "Ubuntu Mono", "Consolas", "Source Code Pro", "source-code-pro", monospace;
|
|
24189
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
24190
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
24191
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
24192
|
+
background: transparent;
|
|
24193
|
+
tab-size: 4;
|
|
24194
|
+
}
|
|
24195
|
+
.editor-textarea:read-only {
|
|
24196
|
+
cursor: default;
|
|
24197
|
+
}
|
|
24198
|
+
.line-numbers {
|
|
24199
|
+
position: absolute;
|
|
24200
|
+
inset-block-start: 0;
|
|
24201
|
+
inset-inline-start: 0;
|
|
24202
|
+
padding-block: 0;
|
|
24203
|
+
padding-inline-end: var(--space-xs-ymlm0b, 8px);
|
|
24204
|
+
text-align: end;
|
|
24205
|
+
user-select: none;
|
|
24206
|
+
pointer-events: none;
|
|
24207
|
+
font-family: "Monaco", "Menlo", "Ubuntu Mono", "Consolas", "Source Code Pro", "source-code-pro", monospace;
|
|
24208
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
24209
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
24210
|
+
color: var(--color-text-small-m1tr70, #656871);
|
|
24211
|
+
min-inline-size: 40px;
|
|
24212
|
+
background: var(--color-background-code-editor-status-bar-yjtxod, #f3f3f7);
|
|
24213
|
+
border-inline-end: 1px solid var(--color-border-code-editor-default-2bfcfq, #dedee3);
|
|
24214
|
+
}
|
|
24215
|
+
.line-number {
|
|
24216
|
+
display: block;
|
|
24217
|
+
padding-inline-end: var(--space-xs-ymlm0b, 8px);
|
|
24218
|
+
padding-inline-start: var(--space-xs-ymlm0b, 8px);
|
|
24219
|
+
}
|
|
24220
|
+
`;
|
|
24221
|
+
var CsCodeEditorInternal = class extends CsBaseElement {
|
|
24222
|
+
constructor() {
|
|
24223
|
+
super(...arguments);
|
|
24224
|
+
this.value = "";
|
|
24225
|
+
this.language = "javascript";
|
|
24226
|
+
this.editorContentHeight = 480;
|
|
24227
|
+
this.loading = false;
|
|
24228
|
+
this.readOnly = false;
|
|
24229
|
+
this.ariaLabel = null;
|
|
24230
|
+
this._cursorRow = 1;
|
|
24231
|
+
this._cursorCol = 1;
|
|
24232
|
+
}
|
|
24233
|
+
static {
|
|
24234
|
+
this.styles = [sharedStyles, componentStyles63, hostStyles65];
|
|
24235
|
+
}
|
|
24236
|
+
get _lineCount() {
|
|
24237
|
+
if (!this.value) return 1;
|
|
24238
|
+
return this.value.split("\n").length;
|
|
24239
|
+
}
|
|
24240
|
+
get _displayLanguage() {
|
|
24241
|
+
return this.languageLabel ?? this.language;
|
|
24242
|
+
}
|
|
24243
|
+
_onInput(e) {
|
|
24244
|
+
const textarea = e.target;
|
|
24245
|
+
const newValue = textarea.value;
|
|
24246
|
+
fireNonCancelableEvent(this, "change", {
|
|
24247
|
+
value: newValue
|
|
24248
|
+
});
|
|
24249
|
+
}
|
|
24250
|
+
_onKeyUp(e) {
|
|
24251
|
+
const textarea = e.target;
|
|
24252
|
+
this._updateCursorPosition(textarea);
|
|
24253
|
+
}
|
|
24254
|
+
_onClick(e) {
|
|
24255
|
+
const textarea = e.target;
|
|
24256
|
+
this._updateCursorPosition(textarea);
|
|
24257
|
+
}
|
|
24258
|
+
_updateCursorPosition(textarea) {
|
|
24259
|
+
const pos = textarea.selectionStart;
|
|
24260
|
+
const textBefore = textarea.value.substring(0, pos);
|
|
24261
|
+
const lines = textBefore.split("\n");
|
|
24262
|
+
this._cursorRow = lines.length;
|
|
24263
|
+
this._cursorCol = (lines[lines.length - 1]?.length ?? 0) + 1;
|
|
24264
|
+
this.requestUpdate();
|
|
24265
|
+
}
|
|
24266
|
+
_cursorPositionLabel(row, col) {
|
|
24267
|
+
return this.i18nStrings?.cursorPosition?.(row, col) ?? `Ln ${row}, Col ${col}`;
|
|
24268
|
+
}
|
|
24269
|
+
_renderLoading() {
|
|
24270
|
+
const loadingText = this.i18nStrings?.loadingState ?? "Loading code editor";
|
|
24271
|
+
return html66`
|
|
24272
|
+
<div class="loading-screen" style="height: ${this.editorContentHeight}px">
|
|
24273
|
+
<cs-spinner size="large"></cs-spinner>
|
|
24274
|
+
<span style="margin-inline-start: 8px">${loadingText}</span>
|
|
24275
|
+
</div>
|
|
24276
|
+
`;
|
|
24277
|
+
}
|
|
24278
|
+
_renderLineNumbers() {
|
|
24279
|
+
const count = this._lineCount;
|
|
24280
|
+
const lines = [];
|
|
24281
|
+
for (let i = 1; i <= count; i++) {
|
|
24282
|
+
lines.push(i);
|
|
24283
|
+
}
|
|
24284
|
+
return html66`
|
|
24285
|
+
<div class="line-numbers" aria-hidden="true">
|
|
24286
|
+
${lines.map((n) => html66`<span class="line-number">${n}</span>`)}
|
|
24287
|
+
</div>
|
|
24288
|
+
`;
|
|
24289
|
+
}
|
|
24290
|
+
_renderEditor() {
|
|
24291
|
+
return html66`
|
|
24292
|
+
<div
|
|
24293
|
+
class="editor-wrapper"
|
|
24294
|
+
style="height: ${this.editorContentHeight}px"
|
|
24295
|
+
>
|
|
24296
|
+
${this._renderLineNumbers()}
|
|
24297
|
+
<textarea
|
|
24298
|
+
class="editor-textarea"
|
|
24299
|
+
.value=${this.value}
|
|
24300
|
+
?readonly=${this.readOnly}
|
|
24301
|
+
aria-label=${this.ariaLabel ?? "Code editor"}
|
|
24302
|
+
spellcheck="false"
|
|
24303
|
+
autocorrect="off"
|
|
24304
|
+
autocapitalize="off"
|
|
24305
|
+
@input=${this._onInput}
|
|
24306
|
+
@keyup=${this._onKeyUp}
|
|
24307
|
+
@click=${this._onClick}
|
|
24308
|
+
></textarea>
|
|
24309
|
+
</div>
|
|
24310
|
+
`;
|
|
24311
|
+
}
|
|
24312
|
+
_renderStatusBar() {
|
|
24313
|
+
const statusClasses = {
|
|
24314
|
+
"status-bar": true,
|
|
24315
|
+
"status-bar-with-hidden-pane": true
|
|
24316
|
+
};
|
|
24317
|
+
return html66`
|
|
24318
|
+
<div class=${classMap54(statusClasses)} role="group" aria-label=${this.i18nStrings?.statusBarGroupAriaLabel ?? "Status bar"}>
|
|
24319
|
+
<div class="status-bar__left">
|
|
24320
|
+
<span class="status-bar__language-mode">${this._displayLanguage}</span>
|
|
24321
|
+
<span class="status-bar__cursor-position">${this._cursorPositionLabel(this._cursorRow, this._cursorCol)}</span>
|
|
24322
|
+
</div>
|
|
24323
|
+
<div class="status-bar__right">
|
|
24324
|
+
<div class="status-bar__cog-button">
|
|
24325
|
+
<cs-button
|
|
24326
|
+
variant="icon"
|
|
24327
|
+
icon-name="settings"
|
|
24328
|
+
aria-label=${this.i18nStrings?.preferencesButtonAriaLabel ?? "Preferences"}
|
|
24329
|
+
></cs-button>
|
|
24330
|
+
</div>
|
|
24331
|
+
</div>
|
|
24332
|
+
</div>
|
|
24333
|
+
`;
|
|
24334
|
+
}
|
|
24335
|
+
render() {
|
|
24336
|
+
return html66`
|
|
24337
|
+
<div class="code-editor" role="group" aria-label=${this.i18nStrings?.editorGroupAriaLabel ?? "Code editor"}>
|
|
24338
|
+
${this.loading ? this._renderLoading() : html66`
|
|
24339
|
+
${this._renderEditor()}
|
|
24340
|
+
${this._renderStatusBar()}
|
|
24341
|
+
`}
|
|
24342
|
+
</div>
|
|
24343
|
+
`;
|
|
24344
|
+
}
|
|
24345
|
+
};
|
|
24346
|
+
__decorateClass([
|
|
24347
|
+
property65({ type: String })
|
|
24348
|
+
], CsCodeEditorInternal.prototype, "value", 2);
|
|
24349
|
+
__decorateClass([
|
|
24350
|
+
property65({ type: String })
|
|
24351
|
+
], CsCodeEditorInternal.prototype, "language", 2);
|
|
24352
|
+
__decorateClass([
|
|
24353
|
+
property65({ type: String })
|
|
24354
|
+
], CsCodeEditorInternal.prototype, "languageLabel", 2);
|
|
24355
|
+
__decorateClass([
|
|
24356
|
+
property65({ type: Number })
|
|
24357
|
+
], CsCodeEditorInternal.prototype, "editorContentHeight", 2);
|
|
24358
|
+
__decorateClass([
|
|
24359
|
+
property65({ type: Boolean })
|
|
24360
|
+
], CsCodeEditorInternal.prototype, "loading", 2);
|
|
24361
|
+
__decorateClass([
|
|
24362
|
+
property65({ type: Boolean })
|
|
24363
|
+
], CsCodeEditorInternal.prototype, "readOnly", 2);
|
|
24364
|
+
__decorateClass([
|
|
24365
|
+
property65({ attribute: false })
|
|
24366
|
+
], CsCodeEditorInternal.prototype, "themes", 2);
|
|
24367
|
+
__decorateClass([
|
|
24368
|
+
property65({ attribute: false })
|
|
24369
|
+
], CsCodeEditorInternal.prototype, "preferences", 2);
|
|
24370
|
+
__decorateClass([
|
|
24371
|
+
property65({ attribute: false })
|
|
24372
|
+
], CsCodeEditorInternal.prototype, "i18nStrings", 2);
|
|
24373
|
+
__decorateClass([
|
|
24374
|
+
property65({ type: String })
|
|
24375
|
+
], CsCodeEditorInternal.prototype, "ariaLabel", 2);
|
|
24376
|
+
|
|
24377
|
+
// src/code-editor/index.ts
|
|
24378
|
+
var CsCodeEditor = class extends CsCodeEditorInternal {
|
|
24379
|
+
};
|
|
24380
|
+
customElements.define("cs-code-editor", CsCodeEditor);
|
|
24381
|
+
|
|
24382
|
+
// src/top-navigation/internal.ts
|
|
24383
|
+
import { css as css144, html as html67, nothing as nothing38 } from "lit";
|
|
24384
|
+
import { property as property66 } from "lit/decorators.js";
|
|
24385
|
+
import { classMap as classMap55 } from "lit/directives/class-map.js";
|
|
24386
|
+
import { ifDefined as ifDefined34 } from "lit/directives/if-defined.js";
|
|
24387
|
+
|
|
24388
|
+
// src/top-navigation/styles.ts
|
|
24389
|
+
import { css as css143 } from "lit";
|
|
24390
|
+
var componentStyles64 = css143`
|
|
24391
|
+
.top-navigation {
|
|
24392
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
24393
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
24394
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
24395
|
+
font-weight: 400;
|
|
24396
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
24397
|
+
-webkit-font-smoothing: auto;
|
|
24398
|
+
-moz-osx-font-smoothing: auto;
|
|
24399
|
+
background: var(--color-background-container-content-6u8rvp, #ffffff);
|
|
24400
|
+
border-block-end: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
24401
|
+
}
|
|
24402
|
+
.top-navigation > .padding-box {
|
|
24403
|
+
display: flex;
|
|
24404
|
+
flex-direction: row;
|
|
24405
|
+
flex-wrap: nowrap;
|
|
24406
|
+
justify-content: space-between;
|
|
24407
|
+
align-items: center;
|
|
24408
|
+
box-sizing: border-box;
|
|
24409
|
+
block-size: calc(var(--space-xxxl-aut1u7, 40px) + var(--space-scaled-m-m892r9, 16px));
|
|
24410
|
+
padding-inline-start: var(--space-xxl-32srm4, 32px);
|
|
24411
|
+
}
|
|
24412
|
+
.top-navigation.medium > .padding-box, .top-navigation.narrow > .padding-box {
|
|
24413
|
+
padding-inline-start: var(--space-l-2ud1p3, 20px);
|
|
24414
|
+
}
|
|
24415
|
+
.top-navigation.medium > .padding-box {
|
|
24416
|
+
block-size: calc(var(--space-xxxl-aut1u7, 40px) + var(--space-scaled-xs-xwoogq, 8px));
|
|
24417
|
+
padding-inline-end: 0;
|
|
24418
|
+
}
|
|
24419
|
+
.top-navigation.narrow > .padding-box {
|
|
24420
|
+
block-size: var(--space-xxxl-aut1u7, 40px);
|
|
24421
|
+
}
|
|
24422
|
+
|
|
24423
|
+
.virtual {
|
|
24424
|
+
inline-size: 9000px;
|
|
24425
|
+
}
|
|
24426
|
+
|
|
24427
|
+
.hidden {
|
|
24428
|
+
position: absolute !important;
|
|
24429
|
+
inset-block-start: -9999px !important;
|
|
24430
|
+
inset-inline-start: -9999px !important;
|
|
24431
|
+
visibility: hidden;
|
|
24432
|
+
}
|
|
24433
|
+
|
|
24434
|
+
.hidden *:not(#awsui_\9 _k5dlb_vnjbq_1) {
|
|
24435
|
+
visibility: hidden;
|
|
24436
|
+
}
|
|
24437
|
+
|
|
24438
|
+
.identity {
|
|
24439
|
+
min-inline-size: 0;
|
|
24440
|
+
}
|
|
24441
|
+
.identity > .identity-link {
|
|
24442
|
+
display: flex;
|
|
24443
|
+
align-items: center;
|
|
24444
|
+
text-decoration: none;
|
|
24445
|
+
color: var(--color-text-top-navigation-title-en0v40, #0f141a);
|
|
24446
|
+
}
|
|
24447
|
+
.identity > .identity-link:hover {
|
|
24448
|
+
color: var(--color-text-accent-n1kmht, #006ce0);
|
|
24449
|
+
}
|
|
24450
|
+
:host-context([data-awsui-focus-visible=true]) .identity > .identity-link:focus {
|
|
24451
|
+
outline: thin dotted;
|
|
24452
|
+
outline: var(--border-link-focus-ring-outline-1p0hnu, 0);
|
|
24453
|
+
outline-offset: 2px;
|
|
24454
|
+
outline-color: var(--color-border-item-focused-uk47pl, #006ce0);
|
|
24455
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24456
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24457
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24458
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24459
|
+
box-shadow: 0 0 0 var(--border-link-focus-ring-shadow-spread-39uvxr, 2px) var(--color-border-item-focused-uk47pl, #006ce0);
|
|
24460
|
+
}
|
|
24461
|
+
.identity.no-logo {
|
|
24462
|
+
min-inline-size: 100px;
|
|
24463
|
+
}
|
|
24464
|
+
|
|
24465
|
+
.logo {
|
|
24466
|
+
display: block;
|
|
24467
|
+
max-block-size: var(--space-xxl-32srm4, 32px);
|
|
24468
|
+
margin-inline-end: var(--space-s-tvghoh, 12px);
|
|
24469
|
+
inline-size: auto;
|
|
24470
|
+
flex-shrink: 0;
|
|
24471
|
+
min-inline-size: 10px;
|
|
24472
|
+
}
|
|
24473
|
+
.logo.narrow {
|
|
24474
|
+
max-block-size: var(--space-xl-jfy3x4, 24px);
|
|
24475
|
+
}
|
|
24476
|
+
|
|
24477
|
+
.title {
|
|
24478
|
+
font-family: var(--font-family-heading-ugphat, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
24479
|
+
font-size: var(--font-size-heading-m-170yiy, 18px);
|
|
24480
|
+
line-height: var(--line-height-heading-m-uoaqdh, 22px);
|
|
24481
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
24482
|
+
font-weight: var(--font-weight-heading-m-zf82dr, 700);
|
|
24483
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
24484
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
24485
|
+
white-space: nowrap;
|
|
24486
|
+
overflow: hidden;
|
|
24487
|
+
text-overflow: ellipsis;
|
|
24488
|
+
}
|
|
24489
|
+
.no-logo > .identity-link > .title {
|
|
24490
|
+
font-weight: 700;
|
|
24491
|
+
}
|
|
24492
|
+
|
|
24493
|
+
.inputs {
|
|
24494
|
+
display: flex;
|
|
24495
|
+
flex: 1;
|
|
24496
|
+
padding-block: 0;
|
|
24497
|
+
padding-inline: var(--space-m-dsumyt, 16px);
|
|
24498
|
+
justify-content: center;
|
|
24499
|
+
}
|
|
24500
|
+
|
|
24501
|
+
.search {
|
|
24502
|
+
inline-size: 100%;
|
|
24503
|
+
max-inline-size: 340px;
|
|
24504
|
+
}
|
|
24505
|
+
.search-expanded {
|
|
24506
|
+
max-inline-size: none;
|
|
24507
|
+
}
|
|
24508
|
+
|
|
24509
|
+
.utilities {
|
|
24510
|
+
display: flex;
|
|
24511
|
+
flex-shrink: 0;
|
|
24512
|
+
flex-direction: row;
|
|
24513
|
+
align-items: stretch;
|
|
24514
|
+
block-size: 100%;
|
|
24515
|
+
}
|
|
24516
|
+
.medium > .padding-box > .utilities, .narrow > .padding-box > .utilities {
|
|
24517
|
+
padding-inline-start: 0;
|
|
24518
|
+
}
|
|
24519
|
+
|
|
24520
|
+
.utility-wrapper {
|
|
24521
|
+
display: flex;
|
|
24522
|
+
position: relative;
|
|
24523
|
+
flex-shrink: 0;
|
|
24524
|
+
align-items: center;
|
|
24525
|
+
padding-block: 0;
|
|
24526
|
+
padding-inline: var(--space-m-dsumyt, 16px);
|
|
24527
|
+
}
|
|
24528
|
+
.utility-wrapper::after {
|
|
24529
|
+
display: block;
|
|
24530
|
+
position: absolute;
|
|
24531
|
+
content: "";
|
|
24532
|
+
inline-size: 1px;
|
|
24533
|
+
inset-inline-end: 0;
|
|
24534
|
+
inset-block: var(--space-s-tvghoh, 12px);
|
|
24535
|
+
background: var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
24536
|
+
}
|
|
24537
|
+
.utility-wrapper:last-of-type::after {
|
|
24538
|
+
display: none;
|
|
24539
|
+
}
|
|
24540
|
+
|
|
24541
|
+
.utility-type-button-link {
|
|
24542
|
+
padding-block: 0;
|
|
24543
|
+
padding-inline: var(--space-l-2ud1p3, 20px);
|
|
24544
|
+
}
|
|
24545
|
+
|
|
24546
|
+
.utility-type-menu-dropdown {
|
|
24547
|
+
padding-block: 0;
|
|
24548
|
+
padding-inline: var(--space-s-tvghoh, 12px);
|
|
24549
|
+
align-items: stretch;
|
|
24550
|
+
}
|
|
24551
|
+
.utility-type-menu-dropdown:not(.narrow):last-of-type, .utility-type-menu-dropdown:not(.medium):last-of-type {
|
|
24552
|
+
padding-inline-end: 0;
|
|
24553
|
+
}
|
|
24554
|
+
|
|
24555
|
+
.utility-type-button-primary-button {
|
|
24556
|
+
inset-inline-start: -1px;
|
|
24557
|
+
border-inline-start: 1px solid var(--color-background-container-content-6u8rvp, #ffffff);
|
|
24558
|
+
}
|
|
24559
|
+
.utility-type-button-primary-button::after {
|
|
24560
|
+
display: none;
|
|
24561
|
+
}
|
|
24562
|
+
|
|
24563
|
+
.utility-link-icon {
|
|
24564
|
+
margin-inline-start: var(--space-xxs-hwfkai, 4px);
|
|
24565
|
+
}
|
|
24566
|
+
|
|
24567
|
+
.utility-button-external-icon {
|
|
24568
|
+
display: inline-block;
|
|
24569
|
+
}
|
|
24570
|
+
|
|
24571
|
+
.offset-right-none {
|
|
24572
|
+
margin-inline-end: 0;
|
|
24573
|
+
}
|
|
24574
|
+
|
|
24575
|
+
.offset-right-l {
|
|
24576
|
+
margin-inline-end: var(--space-xxs-hwfkai, 4px);
|
|
24577
|
+
}
|
|
24578
|
+
|
|
24579
|
+
.offset-right-xxl {
|
|
24580
|
+
margin-inline-end: var(--space-m-dsumyt, 16px);
|
|
24581
|
+
}
|
|
24582
|
+
|
|
24583
|
+
/* Overflow Menu */
|
|
24584
|
+
.overflow-menu-drawer {
|
|
24585
|
+
position: fixed;
|
|
24586
|
+
block-size: 100%;
|
|
24587
|
+
inline-size: 100%;
|
|
24588
|
+
z-index: 1001;
|
|
24589
|
+
}
|
|
24590
|
+
|
|
24591
|
+
.overflow-menu {
|
|
24592
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
24593
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
24594
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
24595
|
+
font-weight: 400;
|
|
24596
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
24597
|
+
-webkit-font-smoothing: auto;
|
|
24598
|
+
-moz-osx-font-smoothing: auto;
|
|
24599
|
+
background: var(--color-background-container-content-6u8rvp, #ffffff);
|
|
24600
|
+
block-size: 100%;
|
|
24601
|
+
}
|
|
24602
|
+
|
|
24603
|
+
.overflow-menu-header {
|
|
24604
|
+
display: flex;
|
|
24605
|
+
align-items: center;
|
|
24606
|
+
min-block-size: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
24607
|
+
padding-block: var(--space-scaled-m-m892r9, 16px);
|
|
24608
|
+
padding-inline: var(--space-scaled-m-m892r9, 16px);
|
|
24609
|
+
border-block-end: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
24610
|
+
}
|
|
24611
|
+
.overflow-menu-header-text {
|
|
24612
|
+
color: var(--color-text-heading-default-izpp46, #0f141a);
|
|
24613
|
+
flex: 1;
|
|
24614
|
+
margin-block: 0;
|
|
24615
|
+
margin-inline: 0;
|
|
24616
|
+
text-align: center;
|
|
24617
|
+
}
|
|
24618
|
+
.overflow-menu-header-text--title {
|
|
24619
|
+
|
|
24620
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
24621
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
24622
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
24623
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
24624
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
24625
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
24626
|
+
}
|
|
24627
|
+
.overflow-menu-header-text--secondary {
|
|
24628
|
+
font-size: var(--font-header-h2-description-size-g2wws3, 14px);
|
|
24629
|
+
line-height: var(--font-header-h2-description-line-height-ts2s6o, 20px);
|
|
24630
|
+
font-weight: 400;
|
|
24631
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
24632
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
24633
|
+
}
|
|
24634
|
+
|
|
24635
|
+
.overflow-menu-control {
|
|
24636
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
24637
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
24638
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
24639
|
+
font-weight: 400;
|
|
24640
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
24641
|
+
-webkit-font-smoothing: auto;
|
|
24642
|
+
-moz-osx-font-smoothing: auto;
|
|
24643
|
+
display: flex;
|
|
24644
|
+
inline-size: 100%;
|
|
24645
|
+
padding-block: 0;
|
|
24646
|
+
padding-inline: 0;
|
|
24647
|
+
background: none;
|
|
24648
|
+
border-block: none;
|
|
24649
|
+
border-inline: none;
|
|
24650
|
+
}
|
|
24651
|
+
.overflow-menu-list-item-utility > .overflow-menu-control {
|
|
24652
|
+
padding-block: var(--space-scaled-m-m892r9, 16px);
|
|
24653
|
+
padding-inline: var(--space-scaled-m-m892r9, 16px);
|
|
24654
|
+
}
|
|
24655
|
+
.overflow-menu-control:hover {
|
|
24656
|
+
color: var(--color-text-accent-n1kmht, #006ce0);
|
|
24657
|
+
cursor: pointer;
|
|
24658
|
+
}
|
|
24659
|
+
.overflow-menu-control-link {
|
|
24660
|
+
text-decoration: none;
|
|
24661
|
+
}
|
|
24662
|
+
.overflow-menu-control-expandable-menu-trigger {
|
|
24663
|
+
color: var(--color-text-dropdown-group-label-2tmyik, #424650);
|
|
24664
|
+
font-weight: bold;
|
|
24665
|
+
}
|
|
24666
|
+
.overflow-menu-control-expandable-menu-trigger:hover {
|
|
24667
|
+
color: var(--color-text-accent-n1kmht, #006ce0);
|
|
24668
|
+
}
|
|
24669
|
+
:host-context([data-awsui-focus-visible=true]) .overflow-menu-control:focus {
|
|
24670
|
+
position: relative;
|
|
24671
|
+
}
|
|
24672
|
+
:host-context([data-awsui-focus-visible=true]) .overflow-menu-control:focus {
|
|
24673
|
+
outline: 2px dotted transparent;
|
|
24674
|
+
outline-offset: calc(var(--space-button-focus-outline-gutter-jj138g, 4px) - 1px);
|
|
24675
|
+
}
|
|
24676
|
+
:host-context([data-awsui-focus-visible=true]) .overflow-menu-control:focus::before {
|
|
24677
|
+
content: " ";
|
|
24678
|
+
display: block;
|
|
24679
|
+
position: absolute;
|
|
24680
|
+
inset-inline-start: calc(-1 * var(--space-button-focus-outline-gutter-jj138g, 4px));
|
|
24681
|
+
inset-block-start: calc(-1 * var(--space-button-focus-outline-gutter-jj138g, 4px));
|
|
24682
|
+
inline-size: calc(100% + var(--space-button-focus-outline-gutter-jj138g, 4px) + var(--space-button-focus-outline-gutter-jj138g, 4px));
|
|
24683
|
+
block-size: calc(100% + var(--space-button-focus-outline-gutter-jj138g, 4px) + var(--space-button-focus-outline-gutter-jj138g, 4px));
|
|
24684
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24685
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24686
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24687
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
24688
|
+
box-shadow: 0 0 0 2px var(--color-border-item-focused-uk47pl, #006ce0);
|
|
24689
|
+
}
|
|
24690
|
+
|
|
24691
|
+
.overflow-menu-list {
|
|
24692
|
+
list-style: none;
|
|
24693
|
+
margin-block: 0;
|
|
24694
|
+
margin-inline: 0;
|
|
24695
|
+
padding-block: 0;
|
|
24696
|
+
padding-inline: 0;
|
|
24697
|
+
}
|
|
24698
|
+
.overflow-menu-list-submenu {
|
|
24699
|
+
margin-block: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
24700
|
+
margin-inline: 0;
|
|
24701
|
+
}
|
|
24702
|
+
|
|
24703
|
+
.overflow-menu-list-item {
|
|
24704
|
+
box-sizing: border-box;
|
|
24705
|
+
letter-spacing: var(--font-button-letter-spacing-ufowe3, 0.005em);
|
|
24706
|
+
}
|
|
24707
|
+
.overflow-menu-list-item-icon {
|
|
24708
|
+
margin-inline-end: var(--space-xxs-hwfkai, 4px);
|
|
24709
|
+
}
|
|
24710
|
+
.overflow-menu-list-item-text {
|
|
24711
|
+
flex: 1;
|
|
24712
|
+
}
|
|
24713
|
+
.overflow-menu-list-item-utility {
|
|
24714
|
+
font-weight: var(--font-weight-button-0eg20c, 700);
|
|
24715
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
24716
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
24717
|
+
border-block-end: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
24718
|
+
}
|
|
24719
|
+
.overflow-menu-list-item-submenu {
|
|
24720
|
+
border-block-start: var(--border-divider-section-width-uwo8my, 1px) solid transparent;
|
|
24721
|
+
border-block-end: var(--border-divider-section-width-uwo8my, 1px) solid transparent;
|
|
24722
|
+
padding-block: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
24723
|
+
padding-inline: var(--space-scaled-l-sej05l, 20px);
|
|
24724
|
+
}
|
|
24725
|
+
.overflow-menu-list-item-dropdown-menu {
|
|
24726
|
+
padding-block: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
24727
|
+
padding-inline: var(--space-scaled-s-8ozaad, 12px);
|
|
24728
|
+
}
|
|
24729
|
+
.overflow-menu-list-item-expandable {
|
|
24730
|
+
border-block-start-color: var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
24731
|
+
border-block-end-color: var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
24732
|
+
}
|
|
24733
|
+
|
|
24734
|
+
.icon {
|
|
24735
|
+
transform: rotate(0deg);
|
|
24736
|
+
transition: transform var(--motion-duration-rotate-180-cxi9g7, 135ms) var(--motion-easing-rotate-180-7a58rc, cubic-bezier(0.165, 0.84, 0.44, 1));
|
|
24737
|
+
}
|
|
24738
|
+
@media (prefers-reduced-motion: reduce) {
|
|
24739
|
+
.icon {
|
|
24740
|
+
animation: none;
|
|
24741
|
+
transition: none;
|
|
24742
|
+
}
|
|
24743
|
+
}
|
|
24744
|
+
.awsui-motion-disabled .icon, .awsui-mode-entering .icon {
|
|
24745
|
+
animation: none;
|
|
24746
|
+
transition: none;
|
|
24747
|
+
}
|
|
24748
|
+
.icon-open {
|
|
24749
|
+
transform: rotate(-180deg);
|
|
24750
|
+
}
|
|
24751
|
+
`;
|
|
24752
|
+
|
|
24753
|
+
// src/top-navigation/internal.ts
|
|
24754
|
+
var hostStyles66 = css144`:host { display: block; }`;
|
|
24755
|
+
var CsTopNavigationInternal = class extends CsBaseElement {
|
|
24756
|
+
constructor() {
|
|
24757
|
+
super(...arguments);
|
|
24758
|
+
this.utilities = [];
|
|
24759
|
+
this.i18nStrings = {};
|
|
24760
|
+
}
|
|
24761
|
+
static {
|
|
24762
|
+
this.styles = [sharedStyles, componentStyles64, hostStyles66];
|
|
24763
|
+
}
|
|
24764
|
+
_onIdentityClick(e) {
|
|
24765
|
+
const isModified = e.button !== 0 || e.ctrlKey || e.metaKey || e.shiftKey || e.altKey;
|
|
24766
|
+
if (isModified) return;
|
|
24767
|
+
e.preventDefault();
|
|
24768
|
+
fireNonCancelableEvent(this, "identityClick", {
|
|
24769
|
+
href: this.identity?.href
|
|
24770
|
+
});
|
|
24771
|
+
}
|
|
24772
|
+
_onUtilityButtonClick(utility, e) {
|
|
24773
|
+
const isModified = e.button !== 0 || e.ctrlKey || e.metaKey || e.shiftKey || e.altKey;
|
|
24774
|
+
if (utility.href && !isModified) {
|
|
24775
|
+
e.preventDefault();
|
|
24776
|
+
}
|
|
24777
|
+
fireNonCancelableEvent(this, "utilityClick", {
|
|
24778
|
+
type: utility.type,
|
|
24779
|
+
text: utility.text,
|
|
24780
|
+
href: utility.href
|
|
24781
|
+
});
|
|
24782
|
+
}
|
|
24783
|
+
_renderIdentity() {
|
|
24784
|
+
if (!this.identity) return nothing38;
|
|
24785
|
+
const hasLogo = !!this.identity.logo;
|
|
24786
|
+
const identityClasses = {
|
|
24787
|
+
"identity": true,
|
|
24788
|
+
"no-logo": !hasLogo
|
|
24789
|
+
};
|
|
24790
|
+
return html67`
|
|
24791
|
+
<div class=${classMap55(identityClasses)}>
|
|
24792
|
+
<a
|
|
24793
|
+
class="identity-link"
|
|
24794
|
+
href=${ifDefined34(this.identity.href)}
|
|
24795
|
+
@click=${(e) => this._onIdentityClick(e)}
|
|
24796
|
+
>
|
|
24797
|
+
${hasLogo ? html67`<img class="logo" src=${this.identity.logo.src} alt=${ifDefined34(this.identity.logo.alt)} />` : nothing38}
|
|
24798
|
+
${this.identity.title ? html67`<span class="title">${this.identity.title}</span>` : nothing38}
|
|
24799
|
+
</a>
|
|
24800
|
+
</div>
|
|
24801
|
+
`;
|
|
24802
|
+
}
|
|
24803
|
+
_renderButtonUtility(utility) {
|
|
24804
|
+
const isPrimary = utility.variant === "primary-button";
|
|
24805
|
+
const wrapperClasses = {
|
|
24806
|
+
"utility-wrapper": true,
|
|
24807
|
+
"utility-type-button-link": !isPrimary,
|
|
24808
|
+
"utility-type-button-primary-button": isPrimary
|
|
24809
|
+
};
|
|
24810
|
+
if (utility.href) {
|
|
24811
|
+
return html67`
|
|
24812
|
+
<div class=${classMap55(wrapperClasses)}>
|
|
24813
|
+
<a
|
|
24814
|
+
class="overflow-menu-control overflow-menu-control-link"
|
|
24815
|
+
href=${utility.href}
|
|
24816
|
+
target=${ifDefined34(utility.target)}
|
|
24817
|
+
rel=${ifDefined34(utility.rel || (utility.target === "_blank" ? "noopener noreferrer" : void 0))}
|
|
24818
|
+
aria-label=${ifDefined34(utility.ariaLabel)}
|
|
24819
|
+
@click=${(e) => this._onUtilityButtonClick(utility, e)}
|
|
24820
|
+
>
|
|
24821
|
+
${utility.iconName ? html67`<span class="utility-link-icon"><cs-icon name=${utility.iconName}></cs-icon></span>` : nothing38}
|
|
24822
|
+
${utility.text ? html67`<span>${utility.text}</span>` : nothing38}
|
|
24823
|
+
${utility.external ? html67`<span class="utility-button-external-icon"><cs-icon name="external" size="inherit"></cs-icon></span>` : nothing38}
|
|
24824
|
+
</a>
|
|
24825
|
+
</div>
|
|
24826
|
+
`;
|
|
24827
|
+
}
|
|
24828
|
+
return html67`
|
|
24829
|
+
<div class=${classMap55(wrapperClasses)}>
|
|
24830
|
+
<button
|
|
24831
|
+
type="button"
|
|
24832
|
+
class="overflow-menu-control"
|
|
24833
|
+
aria-label=${ifDefined34(utility.ariaLabel)}
|
|
24834
|
+
@click=${(e) => this._onUtilityButtonClick(utility, e)}
|
|
24835
|
+
>
|
|
24836
|
+
${utility.iconName ? html67`<span class="utility-link-icon"><cs-icon name=${utility.iconName}></cs-icon></span>` : nothing38}
|
|
24837
|
+
${utility.text ? html67`<span>${utility.text}</span>` : nothing38}
|
|
24838
|
+
</button>
|
|
24839
|
+
</div>
|
|
24840
|
+
`;
|
|
24841
|
+
}
|
|
24842
|
+
_renderMenuDropdownUtility(utility) {
|
|
24843
|
+
const wrapperClasses = {
|
|
24844
|
+
"utility-wrapper": true,
|
|
24845
|
+
"utility-type-menu-dropdown": true
|
|
24846
|
+
};
|
|
24847
|
+
return html67`
|
|
24848
|
+
<div class=${classMap55(wrapperClasses)}>
|
|
24849
|
+
<cs-button-dropdown
|
|
24850
|
+
.items=${utility.items}
|
|
24851
|
+
variant="normal"
|
|
24852
|
+
aria-label=${ifDefined34(utility.ariaLabel)}
|
|
24853
|
+
>
|
|
24854
|
+
${utility.iconName ? html67`<cs-icon name=${utility.iconName}></cs-icon>` : nothing38}
|
|
24855
|
+
${utility.text ?? ""}
|
|
24856
|
+
</cs-button-dropdown>
|
|
24857
|
+
</div>
|
|
24858
|
+
`;
|
|
24859
|
+
}
|
|
24860
|
+
_renderUtility(utility) {
|
|
24861
|
+
if (utility.type === "menu-dropdown") {
|
|
24862
|
+
return this._renderMenuDropdownUtility(utility);
|
|
24863
|
+
}
|
|
24864
|
+
return this._renderButtonUtility(utility);
|
|
24865
|
+
}
|
|
24866
|
+
render() {
|
|
24867
|
+
return html67`
|
|
24868
|
+
<nav class="top-navigation" aria-label=${ifDefined34(this.ariaLabel || "Site")}>
|
|
24869
|
+
<div class="padding-box">
|
|
24870
|
+
${this._renderIdentity()}
|
|
24871
|
+
<div class="inputs">
|
|
24872
|
+
<div class="search">
|
|
24873
|
+
<slot name="search"></slot>
|
|
24874
|
+
</div>
|
|
24875
|
+
</div>
|
|
24876
|
+
<div class="utilities">
|
|
24877
|
+
${this.utilities.map((u) => this._renderUtility(u))}
|
|
24878
|
+
</div>
|
|
24879
|
+
</div>
|
|
24880
|
+
</nav>
|
|
24881
|
+
`;
|
|
24882
|
+
}
|
|
24883
|
+
};
|
|
24884
|
+
__decorateClass([
|
|
24885
|
+
property66({ type: Object })
|
|
24886
|
+
], CsTopNavigationInternal.prototype, "identity", 2);
|
|
24887
|
+
__decorateClass([
|
|
24888
|
+
property66({ type: Array })
|
|
24889
|
+
], CsTopNavigationInternal.prototype, "utilities", 2);
|
|
24890
|
+
__decorateClass([
|
|
24891
|
+
property66({ type: Object })
|
|
24892
|
+
], CsTopNavigationInternal.prototype, "i18nStrings", 2);
|
|
24893
|
+
|
|
24894
|
+
// src/top-navigation/index.ts
|
|
24895
|
+
var CsTopNavigation = class extends CsTopNavigationInternal {
|
|
24896
|
+
};
|
|
24897
|
+
customElements.define("cs-top-navigation", CsTopNavigation);
|
|
24898
|
+
|
|
24899
|
+
// src/side-navigation/internal.ts
|
|
24900
|
+
import { css as css146, html as html68, nothing as nothing39 } from "lit";
|
|
24901
|
+
import { property as property67, state as state21 } from "lit/decorators.js";
|
|
24902
|
+
import { classMap as classMap56 } from "lit/directives/class-map.js";
|
|
24903
|
+
import { ifDefined as ifDefined35 } from "lit/directives/if-defined.js";
|
|
24904
|
+
|
|
24905
|
+
// src/side-navigation/styles.ts
|
|
24906
|
+
import { css as css145 } from "lit";
|
|
24907
|
+
var componentStyles65 = css145`
|
|
24908
|
+
.root {
|
|
24909
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
24910
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
24911
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
24912
|
+
font-weight: 400;
|
|
24913
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
24914
|
+
-webkit-font-smoothing: auto;
|
|
24915
|
+
-moz-osx-font-smoothing: auto;
|
|
24916
|
+
min-inline-size: 0;
|
|
24917
|
+
word-break: break-word;
|
|
24918
|
+
}
|
|
24919
|
+
|
|
24920
|
+
.header {
|
|
24921
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
24922
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
24923
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
24924
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
24925
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
24926
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
24927
|
+
margin-block: 0;
|
|
24928
|
+
margin-inline: 0;
|
|
24929
|
+
padding-block: var(--space-panel-header-vertical-ckfgmy, 20px);
|
|
24930
|
+
padding-inline-start: var(--space-panel-nav-left-wn0n7h, 28px);
|
|
24931
|
+
padding-inline-end: calc(var(--space-scaled-xxl-6wgq96, 32px) + var(--space-xl-jfy3x4, 24px));
|
|
24932
|
+
}
|
|
24933
|
+
|
|
24934
|
+
.header-link {
|
|
24935
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
24936
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
24937
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
24938
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
24939
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
24940
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
24941
|
+
color: var(--color-text-heading-default-izpp46, #0f141a);
|
|
24942
|
+
min-block-size: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
24943
|
+
display: flex;
|
|
24944
|
+
}
|
|
24945
|
+
.header-link--has-logo > .header-link-text {
|
|
24946
|
+
font-weight: 400;
|
|
24947
|
+
align-self: center;
|
|
24948
|
+
}
|
|
24949
|
+
|
|
24950
|
+
.header-logo {
|
|
24951
|
+
margin-inline-end: var(--space-s-tvghoh, 12px);
|
|
24952
|
+
margin-block-start: var(--space-xxxs-pajhad, 2px);
|
|
24953
|
+
max-inline-size: calc(1.25 * var(--size-icon-big-7pq9l3, 32px));
|
|
24954
|
+
align-self: flex-start;
|
|
24955
|
+
}
|
|
24956
|
+
.header-logo--stretched {
|
|
24957
|
+
max-inline-size: 100%;
|
|
24958
|
+
margin-inline-end: 0;
|
|
24959
|
+
}
|
|
24960
|
+
|
|
24961
|
+
.items-control {
|
|
24962
|
+
padding-inline: var(--space-l-2ud1p3, 20px);
|
|
24963
|
+
}
|
|
24964
|
+
|
|
24965
|
+
.list-container {
|
|
24966
|
+
margin-block-end: var(--space-panel-content-bottom-24c6lu, 40px);
|
|
24967
|
+
}
|
|
24968
|
+
|
|
24969
|
+
.items-control,
|
|
24970
|
+
.list-container {
|
|
24971
|
+
margin-block-start: var(--space-panel-content-top-qvd1dr, 20px);
|
|
24972
|
+
}
|
|
24973
|
+
.with-toolbar > .divider-header + .items-control,
|
|
24974
|
+
.with-toolbar > .divider-header + .list-container {
|
|
24975
|
+
margin-block-start: 0;
|
|
24976
|
+
}
|
|
24977
|
+
|
|
24978
|
+
.list {
|
|
24979
|
+
margin-block: 0;
|
|
24980
|
+
margin-inline: 0;
|
|
24981
|
+
padding-block: 0;
|
|
24982
|
+
padding-inline-end: 0;
|
|
24983
|
+
padding-inline-start: var(--space-l-2ud1p3, 20px);
|
|
24984
|
+
}
|
|
24985
|
+
|
|
24986
|
+
.list-variant-root {
|
|
24987
|
+
margin-block: 0;
|
|
24988
|
+
margin-inline: 0;
|
|
24989
|
+
padding-block: 0;
|
|
24990
|
+
padding-inline-start: var(--space-panel-nav-left-wn0n7h, 28px);
|
|
24991
|
+
padding-inline-end: var(--space-panel-side-right-8wwirc, 24px);
|
|
24992
|
+
}
|
|
24993
|
+
.list-variant-root--first {
|
|
24994
|
+
margin-block-start: 0;
|
|
24995
|
+
}
|
|
24996
|
+
|
|
24997
|
+
.list-variant-expandable-link-group {
|
|
24998
|
+
padding-inline-start: var(--space-xxxl-aut1u7, 40px);
|
|
24999
|
+
}
|
|
25000
|
+
|
|
25001
|
+
.list-item {
|
|
25002
|
+
margin-block: var(--space-scaled-xs-xwoogq, 8px);
|
|
25003
|
+
margin-inline: 0;
|
|
25004
|
+
padding-block: 0;
|
|
25005
|
+
padding-inline: 0;
|
|
25006
|
+
list-style: none;
|
|
25007
|
+
}
|
|
25008
|
+
.list-variant-root--first > .list-item:first-child {
|
|
25009
|
+
margin-block-start: 0px;
|
|
25010
|
+
}
|
|
25011
|
+
|
|
25012
|
+
.section,
|
|
25013
|
+
.expandable-link-group {
|
|
25014
|
+
margin-inline-start: calc(-1 * var(--space-l-2ud1p3, 20px));
|
|
25015
|
+
}
|
|
25016
|
+
.section--no-ident,
|
|
25017
|
+
.expandable-link-group--no-ident {
|
|
25018
|
+
margin-inline-start: 0;
|
|
25019
|
+
}
|
|
25020
|
+
|
|
25021
|
+
.section {
|
|
25022
|
+
margin-block: calc(var(--space-scaled-2x-l-u5ida5, 20px) - var(--border-divider-section-width-uwo8my, 1px));
|
|
25023
|
+
|
|
25024
|
+
}
|
|
25025
|
+
.section.refresh {
|
|
25026
|
+
margin-block: calc(var(--space-scaled-2x-m-4euqsk, 16px) - var(--border-divider-section-width-uwo8my, 1px));
|
|
25027
|
+
}
|
|
25028
|
+
.list-variant-root--first > .list-item:first-child > .section {
|
|
25029
|
+
margin-block-start: 0px;
|
|
25030
|
+
}
|
|
25031
|
+
.section > div {
|
|
25032
|
+
padding-block: 0;
|
|
25033
|
+
padding-inline: 0;
|
|
25034
|
+
}
|
|
25035
|
+
|
|
25036
|
+
.list-variant-section-group {
|
|
25037
|
+
margin-block: 0;
|
|
25038
|
+
margin-inline: 0;
|
|
25039
|
+
padding-block: 0;
|
|
25040
|
+
padding-inline: 0;
|
|
25041
|
+
}
|
|
25042
|
+
|
|
25043
|
+
.section-group {
|
|
25044
|
+
font-family: var(--font-family-heading-ugphat, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25045
|
+
font-size: var(--font-size-heading-m-170yiy, 18px);
|
|
25046
|
+
line-height: var(--line-height-heading-m-uoaqdh, 22px);
|
|
25047
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
25048
|
+
font-weight: var(--font-weight-heading-m-zf82dr, 700);
|
|
25049
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25050
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25051
|
+
margin-block: 0;
|
|
25052
|
+
margin-inline: 0;
|
|
25053
|
+
}
|
|
25054
|
+
|
|
25055
|
+
.link {
|
|
25056
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
25057
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
25058
|
+
color: var(--color-text-body-secondary-yna5sb, #424650);
|
|
25059
|
+
font-weight: 400;
|
|
25060
|
+
-webkit-font-smoothing: auto;
|
|
25061
|
+
-moz-osx-font-smoothing: auto;
|
|
25062
|
+
}
|
|
25063
|
+
|
|
25064
|
+
.link-active {
|
|
25065
|
+
font-weight: var(--font-wayfinding-link-active-weight-ny4hup, 700);
|
|
25066
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25067
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25068
|
+
color: var(--color-text-accent-n1kmht, #006ce0);
|
|
25069
|
+
}
|
|
25070
|
+
|
|
25071
|
+
.header-link,
|
|
25072
|
+
.link {
|
|
25073
|
+
text-decoration: none;
|
|
25074
|
+
}
|
|
25075
|
+
.header-link:hover,
|
|
25076
|
+
.link:hover {
|
|
25077
|
+
color: var(--color-text-accent-n1kmht, #006ce0);
|
|
25078
|
+
}
|
|
25079
|
+
.header-link:focus,
|
|
25080
|
+
.link:focus {
|
|
25081
|
+
outline: none;
|
|
25082
|
+
}
|
|
25083
|
+
.header-link:hover, .header-link:focus, .link:hover, .link:focus {
|
|
25084
|
+
text-decoration: none;
|
|
25085
|
+
}
|
|
25086
|
+
:host-context([data-awsui-focus-visible=true]) .header-link:focus,
|
|
25087
|
+
:host-context([data-awsui-focus-visible=true]) .link:focus {
|
|
25088
|
+
outline: thin dotted;
|
|
25089
|
+
outline: var(--border-link-focus-ring-outline-1p0hnu, 0);
|
|
25090
|
+
outline-offset: 2px;
|
|
25091
|
+
outline-color: var(--color-border-item-focused-uk47pl, #006ce0);
|
|
25092
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25093
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25094
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25095
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25096
|
+
box-shadow: 0 0 0 var(--border-link-focus-ring-shadow-spread-39uvxr, 2px) var(--color-border-item-focused-uk47pl, #006ce0);
|
|
25097
|
+
}
|
|
25098
|
+
|
|
25099
|
+
.info {
|
|
25100
|
+
margin-inline-start: var(--space-xs-ymlm0b, 8px);
|
|
25101
|
+
}
|
|
25102
|
+
|
|
25103
|
+
.external-icon {
|
|
25104
|
+
margin-inline-start: var(--space-xxs-hwfkai, 4px);
|
|
25105
|
+
}
|
|
25106
|
+
|
|
25107
|
+
.divider {
|
|
25108
|
+
border-block: none;
|
|
25109
|
+
border-inline: none;
|
|
25110
|
+
}
|
|
25111
|
+
|
|
25112
|
+
.divider-default {
|
|
25113
|
+
margin-block: var(--space-scaled-2x-xl-he48nr, 24px);
|
|
25114
|
+
margin-inline: calc(-1 * var(--space-panel-divider-margin-horizontal-yw31p0, 8px));
|
|
25115
|
+
border-block-start: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
25116
|
+
}
|
|
25117
|
+
|
|
25118
|
+
.divider-header {
|
|
25119
|
+
margin-block: 0;
|
|
25120
|
+
border-block-start: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-panel-header-ygztvl, #c6c6cd);
|
|
25121
|
+
}
|
|
25122
|
+
.with-toolbar > .divider-header {
|
|
25123
|
+
border-color: transparent;
|
|
25124
|
+
}
|
|
25125
|
+
`;
|
|
25126
|
+
|
|
25127
|
+
// src/side-navigation/internal.ts
|
|
25128
|
+
var hostStyles67 = css146`:host { display: block; }`;
|
|
25129
|
+
var CsSideNavigationInternal = class extends CsBaseElement {
|
|
25130
|
+
constructor() {
|
|
25131
|
+
super(...arguments);
|
|
25132
|
+
this.items = [];
|
|
25133
|
+
this.activeHref = "";
|
|
25134
|
+
this._expandedSections = /* @__PURE__ */ new Set();
|
|
25135
|
+
}
|
|
25136
|
+
static {
|
|
25137
|
+
this.styles = [sharedStyles, componentStyles65, hostStyles67];
|
|
25138
|
+
}
|
|
25139
|
+
connectedCallback() {
|
|
25140
|
+
super.connectedCallback();
|
|
25141
|
+
this._initExpandedState();
|
|
25142
|
+
}
|
|
25143
|
+
willUpdate(changed) {
|
|
25144
|
+
super.willUpdate(changed);
|
|
25145
|
+
if (changed.has("items") || changed.has("activeHref")) {
|
|
25146
|
+
this._initExpandedState();
|
|
25147
|
+
}
|
|
25148
|
+
}
|
|
25149
|
+
_initExpandedState() {
|
|
25150
|
+
const expanded = /* @__PURE__ */ new Set();
|
|
25151
|
+
this._collectExpandedItems(this.items, expanded);
|
|
25152
|
+
this._expandedSections = expanded;
|
|
25153
|
+
}
|
|
25154
|
+
_collectExpandedItems(items, expanded) {
|
|
25155
|
+
let containsActive = false;
|
|
25156
|
+
for (const item of items) {
|
|
25157
|
+
if (item.type === "section") {
|
|
25158
|
+
const childActive = this._collectExpandedItems(item.items, expanded);
|
|
25159
|
+
if (childActive || item.defaultExpanded !== false) {
|
|
25160
|
+
expanded.add(this._sectionKey(item));
|
|
25161
|
+
}
|
|
25162
|
+
if (childActive) containsActive = true;
|
|
25163
|
+
} else if (item.type === "expandable-link-group") {
|
|
25164
|
+
const childActive = this._collectExpandedItems(item.items, expanded);
|
|
25165
|
+
const selfActive = item.href === this.activeHref;
|
|
25166
|
+
if (childActive || selfActive || item.defaultExpanded) {
|
|
25167
|
+
expanded.add(this._sectionKey(item));
|
|
25168
|
+
}
|
|
25169
|
+
if (childActive || selfActive) containsActive = true;
|
|
25170
|
+
} else if (item.type === "link" || item.type === "link-group") {
|
|
25171
|
+
if (item.href === this.activeHref) containsActive = true;
|
|
25172
|
+
if (item.type === "link-group") {
|
|
25173
|
+
const childActive = this._collectExpandedItems(item.items, expanded);
|
|
25174
|
+
if (childActive) containsActive = true;
|
|
25175
|
+
}
|
|
25176
|
+
} else if (item.type === "section-group") {
|
|
25177
|
+
const childActive = this._collectExpandedItems(item.items, expanded);
|
|
25178
|
+
if (childActive) containsActive = true;
|
|
25179
|
+
}
|
|
25180
|
+
}
|
|
25181
|
+
return containsActive;
|
|
25182
|
+
}
|
|
25183
|
+
_sectionKey(item) {
|
|
25184
|
+
return `${item.type}:${item.text}`;
|
|
25185
|
+
}
|
|
25186
|
+
_isSectionExpanded(item) {
|
|
25187
|
+
return this._expandedSections.has(this._sectionKey(item));
|
|
25188
|
+
}
|
|
25189
|
+
_toggleSection(item) {
|
|
25190
|
+
const key = this._sectionKey(item);
|
|
25191
|
+
const newExpanded = new Set(this._expandedSections);
|
|
25192
|
+
const wasExpanded = newExpanded.has(key);
|
|
25193
|
+
if (wasExpanded) {
|
|
25194
|
+
newExpanded.delete(key);
|
|
25195
|
+
} else {
|
|
25196
|
+
newExpanded.add(key);
|
|
25197
|
+
}
|
|
25198
|
+
this._expandedSections = newExpanded;
|
|
25199
|
+
fireNonCancelableEvent(this, "change", {
|
|
25200
|
+
item,
|
|
25201
|
+
expanded: !wasExpanded,
|
|
25202
|
+
expandableParents: []
|
|
25203
|
+
});
|
|
25204
|
+
}
|
|
25205
|
+
_onLinkClick(item, e) {
|
|
25206
|
+
const isModified = e.button !== 0 || e.ctrlKey || e.metaKey || e.shiftKey || e.altKey;
|
|
25207
|
+
if (isModified) return;
|
|
25208
|
+
e.preventDefault();
|
|
25209
|
+
fireNonCancelableEvent(this, "follow", {
|
|
25210
|
+
href: item.href,
|
|
25211
|
+
text: item.text,
|
|
25212
|
+
type: item.type
|
|
25213
|
+
});
|
|
25214
|
+
}
|
|
25215
|
+
_renderHeader() {
|
|
25216
|
+
if (!this.header) return nothing39;
|
|
25217
|
+
const hasLogo = !!this.header.logo;
|
|
25218
|
+
const headerLinkClasses = {
|
|
25219
|
+
"header-link": true,
|
|
25220
|
+
"header-link--has-logo": hasLogo
|
|
25221
|
+
};
|
|
25222
|
+
return html68`
|
|
25223
|
+
<div class="header">
|
|
25224
|
+
<a
|
|
25225
|
+
class=${classMap56(headerLinkClasses)}
|
|
25226
|
+
href=${this.header.href}
|
|
25227
|
+
@click=${(e) => this._onLinkClick(
|
|
25228
|
+
{ text: this.header.text, href: this.header.href, type: "section-header" },
|
|
25229
|
+
e
|
|
25230
|
+
)}
|
|
25231
|
+
>
|
|
25232
|
+
${hasLogo ? html68`<img class="header-logo" src=${this.header.logo.src} alt=${ifDefined35(this.header.logo.alt)} />` : nothing39}
|
|
25233
|
+
${this.header.text ? html68`<span class="header-link-text">${this.header.text}</span>` : nothing39}
|
|
25234
|
+
</a>
|
|
25235
|
+
</div>
|
|
25236
|
+
<hr class="divider divider-header" />
|
|
25237
|
+
`;
|
|
25238
|
+
}
|
|
25239
|
+
_renderLink(item) {
|
|
25240
|
+
const isActive = item.href === this.activeHref;
|
|
25241
|
+
const linkClasses = {
|
|
25242
|
+
"link": true,
|
|
25243
|
+
"link-active": isActive
|
|
25244
|
+
};
|
|
25245
|
+
return html68`
|
|
25246
|
+
<li class="list-item">
|
|
25247
|
+
<a
|
|
25248
|
+
class=${classMap56(linkClasses)}
|
|
25249
|
+
href=${item.href}
|
|
25250
|
+
aria-current=${isActive ? "page" : nothing39}
|
|
25251
|
+
target=${item.external ? "_blank" : nothing39}
|
|
25252
|
+
rel=${item.external ? "noopener" : nothing39}
|
|
25253
|
+
@click=${(e) => this._onLinkClick(item, e)}
|
|
25254
|
+
>
|
|
25255
|
+
${item.text}
|
|
25256
|
+
${item.external ? html68`<span class="external-icon"><cs-icon name="external" size="inherit"></cs-icon></span>` : nothing39}
|
|
25257
|
+
</a>
|
|
25258
|
+
</li>
|
|
25259
|
+
`;
|
|
25260
|
+
}
|
|
25261
|
+
_renderDivider() {
|
|
25262
|
+
return html68`<li class="list-item"><hr class="divider divider-default" /></li>`;
|
|
25263
|
+
}
|
|
25264
|
+
_renderSection(item) {
|
|
25265
|
+
const expanded = this._isSectionExpanded(item);
|
|
25266
|
+
return html68`
|
|
25267
|
+
<li class="list-item">
|
|
25268
|
+
<div class="section">
|
|
25269
|
+
<div>
|
|
25270
|
+
<button
|
|
25271
|
+
type="button"
|
|
25272
|
+
class="overflow-menu-control overflow-menu-control-expandable-menu-trigger"
|
|
25273
|
+
aria-expanded=${expanded}
|
|
25274
|
+
@click=${() => this._toggleSection(item)}
|
|
25275
|
+
>
|
|
25276
|
+
<span class="overflow-menu-list-item-text">${item.text}</span>
|
|
25277
|
+
<span class=${classMap56({ "icon": true, "icon-open": expanded })}>
|
|
25278
|
+
<cs-icon name="caret-down-filled"></cs-icon>
|
|
25279
|
+
</span>
|
|
25280
|
+
</button>
|
|
25281
|
+
</div>
|
|
25282
|
+
${expanded ? html68`<ul class="list">${item.items.map((child) => this._renderItem(child))}</ul>` : nothing39}
|
|
25283
|
+
</div>
|
|
25284
|
+
</li>
|
|
25285
|
+
`;
|
|
25286
|
+
}
|
|
25287
|
+
_renderExpandableLinkGroup(item) {
|
|
25288
|
+
const expanded = this._isSectionExpanded(item);
|
|
25289
|
+
const isActive = item.href === this.activeHref;
|
|
25290
|
+
const linkClasses = {
|
|
25291
|
+
"link": true,
|
|
25292
|
+
"link-active": isActive
|
|
25293
|
+
};
|
|
25294
|
+
return html68`
|
|
25295
|
+
<li class="list-item">
|
|
25296
|
+
<div class="expandable-link-group">
|
|
25297
|
+
<div style="display:flex;align-items:center;">
|
|
25298
|
+
<button
|
|
25299
|
+
type="button"
|
|
25300
|
+
class="overflow-menu-control"
|
|
25301
|
+
style="flex-shrink:0;padding:0;inline-size:auto;"
|
|
25302
|
+
aria-expanded=${expanded}
|
|
25303
|
+
aria-label=${`Toggle ${item.text}`}
|
|
25304
|
+
@click=${() => this._toggleSection(item)}
|
|
25305
|
+
>
|
|
25306
|
+
<span class=${classMap56({ "icon": true, "icon-open": expanded })}>
|
|
25307
|
+
<cs-icon name="caret-down-filled"></cs-icon>
|
|
25308
|
+
</span>
|
|
25309
|
+
</button>
|
|
25310
|
+
<a
|
|
25311
|
+
class=${classMap56(linkClasses)}
|
|
25312
|
+
href=${item.href}
|
|
25313
|
+
aria-current=${isActive ? "page" : nothing39}
|
|
25314
|
+
@click=${(e) => this._onLinkClick(item, e)}
|
|
25315
|
+
>
|
|
25316
|
+
${item.text}
|
|
25317
|
+
</a>
|
|
25318
|
+
</div>
|
|
25319
|
+
${expanded ? html68`<ul class="list list-variant-expandable-link-group">${item.items.map((child) => this._renderItem(child))}</ul>` : nothing39}
|
|
25320
|
+
</div>
|
|
25321
|
+
</li>
|
|
25322
|
+
`;
|
|
25323
|
+
}
|
|
25324
|
+
_renderLinkGroup(item) {
|
|
25325
|
+
const isActive = item.href === this.activeHref;
|
|
25326
|
+
const linkClasses = {
|
|
25327
|
+
"link": true,
|
|
25328
|
+
"link-active": isActive
|
|
25329
|
+
};
|
|
25330
|
+
return html68`
|
|
25331
|
+
<li class="list-item">
|
|
25332
|
+
<a
|
|
25333
|
+
class=${classMap56(linkClasses)}
|
|
25334
|
+
href=${item.href}
|
|
25335
|
+
aria-current=${isActive ? "page" : nothing39}
|
|
25336
|
+
@click=${(e) => this._onLinkClick(item, e)}
|
|
25337
|
+
>
|
|
25338
|
+
${item.text}
|
|
25339
|
+
</a>
|
|
25340
|
+
${item.items.length ? html68`<ul class="list">${item.items.map((child) => this._renderItem(child))}</ul>` : nothing39}
|
|
25341
|
+
</li>
|
|
25342
|
+
`;
|
|
25343
|
+
}
|
|
25344
|
+
_renderSectionGroup(item) {
|
|
25345
|
+
return html68`
|
|
25346
|
+
<li class="list-item">
|
|
25347
|
+
<div class="section-group">${item.title}</div>
|
|
25348
|
+
<ul class="list list-variant-section-group">
|
|
25349
|
+
${item.items.map((child) => this._renderItem(child))}
|
|
25350
|
+
</ul>
|
|
25351
|
+
</li>
|
|
25352
|
+
`;
|
|
25353
|
+
}
|
|
25354
|
+
_renderItem(item) {
|
|
25355
|
+
switch (item.type) {
|
|
25356
|
+
case "link":
|
|
25357
|
+
return this._renderLink(item);
|
|
25358
|
+
case "divider":
|
|
25359
|
+
return this._renderDivider();
|
|
25360
|
+
case "section":
|
|
25361
|
+
return this._renderSection(item);
|
|
25362
|
+
case "expandable-link-group":
|
|
25363
|
+
return this._renderExpandableLinkGroup(item);
|
|
25364
|
+
case "link-group":
|
|
25365
|
+
return this._renderLinkGroup(item);
|
|
25366
|
+
case "section-group":
|
|
25367
|
+
return this._renderSectionGroup(item);
|
|
25368
|
+
default:
|
|
25369
|
+
return html68``;
|
|
25370
|
+
}
|
|
25371
|
+
}
|
|
25372
|
+
render() {
|
|
25373
|
+
return html68`
|
|
25374
|
+
<nav class="root" aria-label=${ifDefined35(this.ariaLabel || "Side navigation")}>
|
|
25375
|
+
${this._renderHeader()}
|
|
25376
|
+
<slot name="itemsControl"></slot>
|
|
25377
|
+
<div class="list-container">
|
|
25378
|
+
<ul class="list list-variant-root list-variant-root--first">
|
|
25379
|
+
${this.items.map((item) => this._renderItem(item))}
|
|
25380
|
+
</ul>
|
|
25381
|
+
</div>
|
|
25382
|
+
</nav>
|
|
25383
|
+
`;
|
|
25384
|
+
}
|
|
25385
|
+
};
|
|
25386
|
+
__decorateClass([
|
|
25387
|
+
property67({ type: Object })
|
|
25388
|
+
], CsSideNavigationInternal.prototype, "header", 2);
|
|
25389
|
+
__decorateClass([
|
|
25390
|
+
property67({ type: Array })
|
|
25391
|
+
], CsSideNavigationInternal.prototype, "items", 2);
|
|
25392
|
+
__decorateClass([
|
|
25393
|
+
property67({ type: String })
|
|
25394
|
+
], CsSideNavigationInternal.prototype, "activeHref", 2);
|
|
25395
|
+
__decorateClass([
|
|
25396
|
+
state21()
|
|
25397
|
+
], CsSideNavigationInternal.prototype, "_expandedSections", 2);
|
|
25398
|
+
|
|
25399
|
+
// src/side-navigation/index.ts
|
|
25400
|
+
var CsSideNavigation = class extends CsSideNavigationInternal {
|
|
25401
|
+
};
|
|
25402
|
+
customElements.define("cs-side-navigation", CsSideNavigation);
|
|
25403
|
+
|
|
25404
|
+
// src/help-panel/internal.ts
|
|
25405
|
+
import { css as css148, html as html69 } from "lit";
|
|
25406
|
+
import { property as property68 } from "lit/decorators.js";
|
|
25407
|
+
|
|
25408
|
+
// src/help-panel/styles.ts
|
|
25409
|
+
import { css as css147 } from "lit";
|
|
25410
|
+
var componentStyles66 = css147`
|
|
25411
|
+
.help-panel {
|
|
25412
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
25413
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
25414
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
25415
|
+
font-weight: 400;
|
|
25416
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25417
|
+
-webkit-font-smoothing: auto;
|
|
25418
|
+
-moz-osx-font-smoothing: auto;
|
|
25419
|
+
word-wrap: break-word;
|
|
25420
|
+
padding-block-start: var(--space-panel-header-vertical-ckfgmy, 20px);
|
|
25421
|
+
padding-block-end: 0;
|
|
25422
|
+
|
|
25423
|
+
|
|
25424
|
+
}
|
|
25425
|
+
.help-panel hr {
|
|
25426
|
+
border-block: none;
|
|
25427
|
+
border-inline: none;
|
|
25428
|
+
border-block-start: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
25429
|
+
margin-block: var(--space-scaled-xl-dunxp5, 24px);
|
|
25430
|
+
margin-inline: calc(-1 * var(--space-panel-divider-margin-horizontal-yw31p0, 8px));
|
|
25431
|
+
}
|
|
25432
|
+
.help-panel ol,
|
|
25433
|
+
.help-panel ul {
|
|
25434
|
+
padding-inline-start: var(--space-l-2ud1p3, 20px);
|
|
25435
|
+
list-style-position: outside;
|
|
25436
|
+
margin-block: var(--space-s-tvghoh, 12px);
|
|
25437
|
+
margin-inline: 0;
|
|
25438
|
+
}
|
|
25439
|
+
.help-panel li {
|
|
25440
|
+
margin-block: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
25441
|
+
margin-inline: 0;
|
|
25442
|
+
}
|
|
25443
|
+
.help-panel a,
|
|
25444
|
+
.help-panel h2,
|
|
25445
|
+
.help-panel h3,
|
|
25446
|
+
.help-panel h4,
|
|
25447
|
+
.help-panel h5,
|
|
25448
|
+
.help-panel pre,
|
|
25449
|
+
.help-panel code {
|
|
25450
|
+
margin-block: var(--space-xs-ymlm0b, 8px);
|
|
25451
|
+
margin-inline: 0;
|
|
25452
|
+
padding-block: 0;
|
|
25453
|
+
}
|
|
25454
|
+
.help-panel code {
|
|
25455
|
+
font-size: var(--font-size-body-s-smc8cv, 12px);
|
|
25456
|
+
line-height: var(--line-height-body-s-nu5hx1, 16px);
|
|
25457
|
+
letter-spacing: var(--letter-spacing-body-s-gq78ok, 0.005em);
|
|
25458
|
+
font-family: var(--font-family-monospace-q47m7k, Monaco, Menlo, Consolas, "Courier Prime", Courier, "Courier New", monospace);
|
|
25459
|
+
background-color: var(--color-background-layout-main-5ilwcb, #ffffff);
|
|
25460
|
+
padding-block: 0;
|
|
25461
|
+
padding-inline: var(--space-xxs-hwfkai, 4px);
|
|
25462
|
+
word-wrap: break-word;
|
|
25463
|
+
white-space: pre-wrap;
|
|
25464
|
+
}
|
|
25465
|
+
.help-panel pre {
|
|
25466
|
+
font-size: var(--font-size-body-s-smc8cv, 12px);
|
|
25467
|
+
line-height: var(--line-height-body-s-nu5hx1, 16px);
|
|
25468
|
+
letter-spacing: var(--letter-spacing-body-s-gq78ok, 0.005em);
|
|
25469
|
+
font-family: var(--font-family-monospace-q47m7k, Monaco, Menlo, Consolas, "Courier Prime", Courier, "Courier New", monospace);
|
|
25470
|
+
background-color: var(--color-background-layout-main-5ilwcb, #ffffff);
|
|
25471
|
+
padding-block: 0;
|
|
25472
|
+
padding-inline: var(--space-xxs-hwfkai, 4px);
|
|
25473
|
+
word-wrap: break-word;
|
|
25474
|
+
white-space: pre-wrap;
|
|
25475
|
+
padding-block: var(--space-xxs-hwfkai, 4px);
|
|
25476
|
+
padding-inline: var(--space-xxs-hwfkai, 4px);
|
|
25477
|
+
}
|
|
25478
|
+
.help-panel dl {
|
|
25479
|
+
margin-block: var(--space-s-tvghoh, 12px);
|
|
25480
|
+
margin-inline: 0;
|
|
25481
|
+
|
|
25482
|
+
}
|
|
25483
|
+
.help-panel dl * {
|
|
25484
|
+
margin-block: 0;
|
|
25485
|
+
}
|
|
25486
|
+
.help-panel dt {
|
|
25487
|
+
margin-block-start: var(--space-xs-ymlm0b, 8px);
|
|
25488
|
+
font-weight: 700;
|
|
25489
|
+
}
|
|
25490
|
+
.help-panel dd {
|
|
25491
|
+
margin-block-start: 0;
|
|
25492
|
+
margin-block-end: var(--space-xs-ymlm0b, 8px);
|
|
25493
|
+
margin-inline: 0;
|
|
25494
|
+
}
|
|
25495
|
+
.help-panel h2,
|
|
25496
|
+
.help-panel h3,
|
|
25497
|
+
.help-panel h4,
|
|
25498
|
+
.help-panel h5,
|
|
25499
|
+
.help-panel h6 {
|
|
25500
|
+
margin-block-start: var(--space-xl-jfy3x4, 24px);
|
|
25501
|
+
color: var(--color-text-heading-default-izpp46, #0f141a);
|
|
25502
|
+
}
|
|
25503
|
+
.help-panel > :last-child {
|
|
25504
|
+
margin-block-end: var(--space-panel-content-bottom-24c6lu, 40px);
|
|
25505
|
+
}
|
|
25506
|
+
.help-panel p {
|
|
25507
|
+
color: inherit;
|
|
25508
|
+
text-decoration: none;
|
|
25509
|
+
margin-block: var(--space-s-tvghoh, 12px);
|
|
25510
|
+
margin-inline: 0;
|
|
25511
|
+
}
|
|
25512
|
+
.help-panel h1 {
|
|
25513
|
+
font-family: var(--font-family-heading-ugphat, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25514
|
+
font-size: var(--font-size-heading-xl-wvkbur, 24px);
|
|
25515
|
+
line-height: var(--line-height-heading-xl-hko6p0, 30px);
|
|
25516
|
+
letter-spacing: var(--letter-spacing-heading-xl-ckkb6u, -0.02em);
|
|
25517
|
+
font-weight: var(--font-weight-heading-xl-u3m4we, 700);
|
|
25518
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25519
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25520
|
+
}
|
|
25521
|
+
.help-panel h2 {
|
|
25522
|
+
font-family: var(--font-family-heading-ugphat, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25523
|
+
font-size: var(--font-size-heading-l-vnacx6, 20px);
|
|
25524
|
+
line-height: var(--line-height-heading-l-mg5bx6, 24px);
|
|
25525
|
+
letter-spacing: var(--letter-spacing-heading-l-5v6ibv, -0.015em);
|
|
25526
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
25527
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25528
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25529
|
+
}
|
|
25530
|
+
.help-panel h3 {
|
|
25531
|
+
font-family: var(--font-family-heading-ugphat, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25532
|
+
font-size: var(--font-size-heading-m-170yiy, 18px);
|
|
25533
|
+
line-height: var(--line-height-heading-m-uoaqdh, 22px);
|
|
25534
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
25535
|
+
font-weight: var(--font-weight-heading-m-zf82dr, 700);
|
|
25536
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25537
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25538
|
+
}
|
|
25539
|
+
.help-panel h4 {
|
|
25540
|
+
font-family: var(--font-family-heading-ugphat, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25541
|
+
font-size: var(--font-size-heading-s-zp08en, 16px);
|
|
25542
|
+
line-height: var(--line-height-heading-s-hmi4vc, 20px);
|
|
25543
|
+
letter-spacing: var(--letter-spacing-heading-s-4st9ep, -0.005em);
|
|
25544
|
+
font-weight: var(--font-weight-heading-s-lcx0ai, 700);
|
|
25545
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25546
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25547
|
+
}
|
|
25548
|
+
.help-panel h5 {
|
|
25549
|
+
font-family: var(--font-family-heading-ugphat, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25550
|
+
font-size: var(--font-size-heading-xs-j8yzxv, 14px);
|
|
25551
|
+
line-height: var(--line-height-heading-xs-q9j004, 18px);
|
|
25552
|
+
letter-spacing: var(--letter-spacing-heading-xs-fgog7a, normal);
|
|
25553
|
+
font-weight: var(--font-weight-heading-xs-wqqpne, 700);
|
|
25554
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25555
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25556
|
+
}
|
|
25557
|
+
.help-panel b,
|
|
25558
|
+
.help-panel strong {
|
|
25559
|
+
font-weight: 700;
|
|
25560
|
+
}
|
|
25561
|
+
|
|
25562
|
+
.loading {
|
|
25563
|
+
padding-inline-start: var(--space-panel-side-left-u1m3s9, 28px);
|
|
25564
|
+
padding-inline-end: var(--space-panel-side-right-8wwirc, 24px);
|
|
25565
|
+
}
|
|
25566
|
+
|
|
25567
|
+
.header {
|
|
25568
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
25569
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
25570
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
25571
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
25572
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25573
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25574
|
+
color: var(--color-text-heading-default-izpp46, #0f141a);
|
|
25575
|
+
padding-block-end: var(--space-panel-header-vertical-ckfgmy, 20px);
|
|
25576
|
+
padding-inline: var(--space-panel-side-left-u1m3s9, 28px) calc(var(--space-xl-jfy3x4, 24px) + var(--space-scaled-xxl-6wgq96, 32px));
|
|
25577
|
+
border-block: none;
|
|
25578
|
+
border-inline: none;
|
|
25579
|
+
border-block-end: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-panel-header-ygztvl, #c6c6cd);
|
|
25580
|
+
margin-block-start: 0;
|
|
25581
|
+
margin-block-end: var(--space-panel-content-top-qvd1dr, 20px);
|
|
25582
|
+
|
|
25583
|
+
|
|
25584
|
+
}
|
|
25585
|
+
.with-toolbar > .header {
|
|
25586
|
+
border-color: transparent;
|
|
25587
|
+
margin-block-end: 0px;
|
|
25588
|
+
}
|
|
25589
|
+
.header h2,
|
|
25590
|
+
.header h3,
|
|
25591
|
+
.header h4,
|
|
25592
|
+
.header h5,
|
|
25593
|
+
.header h6 {
|
|
25594
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
25595
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
25596
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
25597
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
25598
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25599
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25600
|
+
padding-block: 0;
|
|
25601
|
+
margin-block: 0;
|
|
25602
|
+
}
|
|
25603
|
+
|
|
25604
|
+
.content {
|
|
25605
|
+
color: var(--color-text-body-secondary-yna5sb, #424650);
|
|
25606
|
+
padding-inline-start: var(--space-panel-side-left-u1m3s9, 28px);
|
|
25607
|
+
padding-inline-end: var(--space-panel-side-right-8wwirc, 24px);
|
|
25608
|
+
|
|
25609
|
+
|
|
25610
|
+
}
|
|
25611
|
+
.content h2:first-child,
|
|
25612
|
+
.content h3:first-child,
|
|
25613
|
+
.content h4:first-child,
|
|
25614
|
+
.content h5:first-child,
|
|
25615
|
+
.content h6:first-child,
|
|
25616
|
+
.content p:first-child {
|
|
25617
|
+
margin-block-start: 0;
|
|
25618
|
+
}
|
|
25619
|
+
.content a {
|
|
25620
|
+
text-underline-offset: 0.25em;
|
|
25621
|
+
text-decoration-thickness: 1px;
|
|
25622
|
+
color: var(--awsui-style-color-default-6b9ypa, var(--color-text-link-default-hude44, #006ce0));
|
|
25623
|
+
font-weight: inherit;
|
|
25624
|
+
letter-spacing: normal;
|
|
25625
|
+
text-decoration-line: underline;
|
|
25626
|
+
text-decoration-color: currentColor;
|
|
25627
|
+
transition-property: color, -webkit-text-decoration;
|
|
25628
|
+
transition-property: color, text-decoration;
|
|
25629
|
+
transition-property: color, text-decoration, -webkit-text-decoration;
|
|
25630
|
+
transition-duration: var(--motion-duration-refresh-only-medium-5rbn3k, 165ms);
|
|
25631
|
+
}
|
|
25632
|
+
@media (prefers-reduced-motion: reduce) {
|
|
25633
|
+
.content a {
|
|
25634
|
+
animation: none;
|
|
25635
|
+
transition: none;
|
|
25636
|
+
}
|
|
25637
|
+
}
|
|
25638
|
+
.awsui-motion-disabled .content a, .awsui-mode-entering .content a {
|
|
25639
|
+
animation: none;
|
|
25640
|
+
transition: none;
|
|
25641
|
+
}
|
|
25642
|
+
.content a:hover {
|
|
25643
|
+
cursor: pointer;
|
|
25644
|
+
color: var(--awsui-style-color-hover-6b9ypa, var(--color-text-link-hover-2hfec2, #002b66));
|
|
25645
|
+
}
|
|
25646
|
+
.content a:focus {
|
|
25647
|
+
outline: none;
|
|
25648
|
+
}
|
|
25649
|
+
.content a:active {
|
|
25650
|
+
color: var(--awsui-style-color-active-6b9ypa, var(--color-text-link-hover-2hfec2, #002b66));
|
|
25651
|
+
}
|
|
25652
|
+
.content a:active, .content a:focus, .content a:hover {
|
|
25653
|
+
text-decoration-line: underline;
|
|
25654
|
+
text-decoration-color: currentColor;
|
|
25655
|
+
}
|
|
25656
|
+
|
|
25657
|
+
.footer {
|
|
25658
|
+
color: var(--color-text-body-secondary-yna5sb, #424650);
|
|
25659
|
+
padding-block: 0;
|
|
25660
|
+
padding-inline-start: var(--space-panel-side-left-u1m3s9, 28px);
|
|
25661
|
+
padding-inline-end: var(--space-panel-side-right-8wwirc, 24px);
|
|
25662
|
+
|
|
25663
|
+
|
|
25664
|
+
}
|
|
25665
|
+
.footer ul {
|
|
25666
|
+
list-style: none;
|
|
25667
|
+
padding-inline-start: 0;
|
|
25668
|
+
}
|
|
25669
|
+
.footer a {
|
|
25670
|
+
text-underline-offset: 0.25em;
|
|
25671
|
+
text-decoration-thickness: 1px;
|
|
25672
|
+
color: var(--awsui-style-color-default-6b9ypa, var(--color-text-link-default-hude44, #006ce0));
|
|
25673
|
+
font-weight: inherit;
|
|
25674
|
+
letter-spacing: normal;
|
|
25675
|
+
text-decoration-line: none;
|
|
25676
|
+
text-decoration-color: transparent;
|
|
25677
|
+
transition-property: color, -webkit-text-decoration;
|
|
25678
|
+
transition-property: color, text-decoration;
|
|
25679
|
+
transition-property: color, text-decoration, -webkit-text-decoration;
|
|
25680
|
+
transition-duration: var(--motion-duration-refresh-only-medium-5rbn3k, 165ms);
|
|
25681
|
+
}
|
|
25682
|
+
@media (prefers-reduced-motion: reduce) {
|
|
25683
|
+
.footer a {
|
|
25684
|
+
animation: none;
|
|
25685
|
+
transition: none;
|
|
25686
|
+
}
|
|
25687
|
+
}
|
|
25688
|
+
.awsui-motion-disabled .footer a, .awsui-mode-entering .footer a {
|
|
25689
|
+
animation: none;
|
|
25690
|
+
transition: none;
|
|
25691
|
+
}
|
|
25692
|
+
.footer a:hover {
|
|
25693
|
+
cursor: pointer;
|
|
25694
|
+
color: var(--awsui-style-color-hover-6b9ypa, var(--color-text-link-hover-2hfec2, #002b66));
|
|
25695
|
+
}
|
|
25696
|
+
.footer a:focus {
|
|
25697
|
+
outline: none;
|
|
25698
|
+
}
|
|
25699
|
+
.footer a:active {
|
|
25700
|
+
color: var(--awsui-style-color-active-6b9ypa, var(--color-text-link-hover-2hfec2, #002b66));
|
|
25701
|
+
}
|
|
25702
|
+
.footer a:active, .footer a:focus, .footer a:hover {
|
|
25703
|
+
text-decoration-line: underline;
|
|
25704
|
+
text-decoration-color: currentColor;
|
|
25705
|
+
}
|
|
25706
|
+
.content a:focus,
|
|
25707
|
+
.footer a:focus {
|
|
25708
|
+
outline: thin dotted;
|
|
25709
|
+
outline: var(--border-link-focus-ring-outline-1p0hnu, 0);
|
|
25710
|
+
outline-offset: 2px;
|
|
25711
|
+
outline-color: var(--color-border-item-focused-uk47pl, #006ce0);
|
|
25712
|
+
border-start-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25713
|
+
border-start-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25714
|
+
border-end-start-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25715
|
+
border-end-end-radius: var(--border-radius-control-default-focus-ring-1uabki, 4px);
|
|
25716
|
+
box-shadow: 0 0 0 var(--border-link-focus-ring-shadow-spread-39uvxr, 2px) var(--color-border-item-focused-uk47pl, #006ce0);
|
|
25717
|
+
}
|
|
25718
|
+
`;
|
|
25719
|
+
|
|
25720
|
+
// src/help-panel/internal.ts
|
|
25721
|
+
var hostStyles68 = css148`:host { display: block; }`;
|
|
25722
|
+
var CsHelpPanelInternal = class extends CsBaseElement {
|
|
25723
|
+
constructor() {
|
|
25724
|
+
super(...arguments);
|
|
25725
|
+
this.loading = false;
|
|
25726
|
+
this.loadingText = "Loading content";
|
|
25727
|
+
}
|
|
25728
|
+
static {
|
|
25729
|
+
this.styles = [sharedStyles, componentStyles66, hostStyles68];
|
|
25730
|
+
}
|
|
25731
|
+
render() {
|
|
25732
|
+
if (this.loading) {
|
|
25733
|
+
return html69`
|
|
25734
|
+
<div class="help-panel">
|
|
25735
|
+
<div class="loading">
|
|
25736
|
+
<cs-spinner size="normal"></cs-spinner>
|
|
25737
|
+
<span>${this.loadingText}</span>
|
|
25738
|
+
</div>
|
|
25739
|
+
</div>
|
|
25740
|
+
`;
|
|
25741
|
+
}
|
|
25742
|
+
return html69`
|
|
25743
|
+
<div class="help-panel">
|
|
25744
|
+
<div class="header">
|
|
25745
|
+
<slot name="header"></slot>
|
|
25746
|
+
</div>
|
|
25747
|
+
<div class="content">
|
|
25748
|
+
<slot></slot>
|
|
25749
|
+
</div>
|
|
25750
|
+
<div class="footer">
|
|
25751
|
+
<slot name="footer"></slot>
|
|
25752
|
+
</div>
|
|
25753
|
+
</div>
|
|
25754
|
+
`;
|
|
25755
|
+
}
|
|
25756
|
+
};
|
|
25757
|
+
__decorateClass([
|
|
25758
|
+
property68({ type: Boolean, reflect: true })
|
|
25759
|
+
], CsHelpPanelInternal.prototype, "loading", 2);
|
|
25760
|
+
__decorateClass([
|
|
25761
|
+
property68({ type: String })
|
|
25762
|
+
], CsHelpPanelInternal.prototype, "loadingText", 2);
|
|
25763
|
+
|
|
25764
|
+
// src/help-panel/index.ts
|
|
25765
|
+
var CsHelpPanel = class extends CsHelpPanelInternal {
|
|
25766
|
+
};
|
|
25767
|
+
customElements.define("cs-help-panel", CsHelpPanel);
|
|
25768
|
+
|
|
25769
|
+
// src/drawer/internal.ts
|
|
25770
|
+
import { css as css150, html as html70 } from "lit";
|
|
25771
|
+
import { property as property69 } from "lit/decorators.js";
|
|
25772
|
+
import { classMap as classMap57 } from "lit/directives/class-map.js";
|
|
25773
|
+
|
|
25774
|
+
// src/drawer/styles.ts
|
|
25775
|
+
import { css as css149 } from "lit";
|
|
25776
|
+
var componentStyles67 = css149`
|
|
25777
|
+
.drawer {
|
|
25778
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
25779
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
25780
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
25781
|
+
font-weight: 400;
|
|
25782
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25783
|
+
-webkit-font-smoothing: auto;
|
|
25784
|
+
-moz-osx-font-smoothing: auto;
|
|
25785
|
+
word-wrap: break-word;
|
|
25786
|
+
}
|
|
25787
|
+
.drawer.with-footer {
|
|
25788
|
+
display: flex;
|
|
25789
|
+
flex-direction: column;
|
|
25790
|
+
min-block-size: 100%;
|
|
25791
|
+
}
|
|
25792
|
+
.drawer.with-footer > .content {
|
|
25793
|
+
flex: 1;
|
|
25794
|
+
}
|
|
25795
|
+
|
|
25796
|
+
.header {
|
|
25797
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
25798
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
25799
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
25800
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
25801
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25802
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25803
|
+
display: flex;
|
|
25804
|
+
justify-content: space-between;
|
|
25805
|
+
color: var(--color-text-heading-default-izpp46, #0f141a);
|
|
25806
|
+
padding-block: var(--space-panel-header-vertical-ckfgmy, 20px);
|
|
25807
|
+
padding-inline: var(--space-panel-side-left-u1m3s9, 28px) calc(var(--space-l-2ud1p3, 20px) + var(--space-scaled-xxl-6wgq96, 32px));
|
|
25808
|
+
border-block-end: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-panel-header-ygztvl, #c6c6cd);
|
|
25809
|
+
|
|
25810
|
+
|
|
25811
|
+
}
|
|
25812
|
+
@media (min-width: 689px) {
|
|
25813
|
+
.header.with-additional-action {
|
|
25814
|
+
/*
|
|
25815
|
+
this padding is needed when the drawer renders inside a runtime drawer and the runtime drawer has an additional action
|
|
25816
|
+
on the right (or left in rtl). in this case this padding ensures that the drawer's content does not overlap with runtime actions
|
|
25817
|
+
*/
|
|
25818
|
+
padding-inline: var(--space-panel-side-left-u1m3s9, 28px) calc(var(--space-xxxl-aut1u7, 40px) + var(--space-scaled-xxl-6wgq96, 32px));
|
|
25819
|
+
}
|
|
25820
|
+
}
|
|
25821
|
+
.header.with-runtime-context {
|
|
25822
|
+
padding-block: 14px;
|
|
25823
|
+
}
|
|
25824
|
+
.with-toolbar > .header {
|
|
25825
|
+
border-color: transparent;
|
|
25826
|
+
margin-block-end: 0px;
|
|
25827
|
+
}
|
|
25828
|
+
.header h2,
|
|
25829
|
+
.header h3,
|
|
25830
|
+
.header h4,
|
|
25831
|
+
.header h5,
|
|
25832
|
+
.header h6 {
|
|
25833
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
25834
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
25835
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
25836
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
25837
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
25838
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
25839
|
+
padding-block: 0;
|
|
25840
|
+
margin-block: 0;
|
|
25841
|
+
}
|
|
25842
|
+
|
|
25843
|
+
.header-actions {
|
|
25844
|
+
display: inline-flex;
|
|
25845
|
+
align-items: flex-start;
|
|
25846
|
+
z-index: 1;
|
|
25847
|
+
}
|
|
25848
|
+
|
|
25849
|
+
.content-with-paddings:not(:empty) {
|
|
25850
|
+
padding-block-start: var(--space-panel-content-top-qvd1dr, 20px);
|
|
25851
|
+
padding-inline-start: var(--space-panel-side-left-u1m3s9, 28px);
|
|
25852
|
+
padding-inline-end: var(--space-panel-side-right-8wwirc, 24px);
|
|
25853
|
+
padding-block-end: var(--space-panel-content-bottom-24c6lu, 40px);
|
|
25854
|
+
}
|
|
25855
|
+
|
|
25856
|
+
.footer {
|
|
25857
|
+
background-color: var(--color-background-container-content-6u8rvp, #ffffff);
|
|
25858
|
+
border-block-start: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-panel-header-ygztvl, #c6c6cd);
|
|
25859
|
+
padding-block: var(--space-panel-content-top-qvd1dr, 20px);
|
|
25860
|
+
padding-inline: var(--space-panel-side-left-u1m3s9, 28px) var(--space-panel-side-right-8wwirc, 24px);
|
|
25861
|
+
}
|
|
25862
|
+
.footer.is-sticky {
|
|
25863
|
+
position: sticky;
|
|
25864
|
+
inset-block-end: 0;
|
|
25865
|
+
inset-inline-start: 0;
|
|
25866
|
+
inset-inline-end: 0;
|
|
25867
|
+
z-index: 810;
|
|
25868
|
+
}
|
|
25869
|
+
`;
|
|
25870
|
+
|
|
25871
|
+
// src/drawer/internal.ts
|
|
25872
|
+
var hostStyles69 = css150`:host { display: block; }`;
|
|
25873
|
+
var CsDrawerInternal = class extends CsBaseElement {
|
|
25874
|
+
constructor() {
|
|
25875
|
+
super(...arguments);
|
|
25876
|
+
this.loading = false;
|
|
25877
|
+
this.disableContentPaddings = false;
|
|
25878
|
+
this._hasHeader = false;
|
|
25879
|
+
this._hasFooter = false;
|
|
25880
|
+
this._hasHeaderActions = false;
|
|
25881
|
+
this._onHeaderSlotChange = (e) => {
|
|
25882
|
+
const slot = e.target;
|
|
25883
|
+
this._hasHeader = slot.assignedNodes({ flatten: true }).length > 0;
|
|
25884
|
+
this.requestUpdate();
|
|
25885
|
+
};
|
|
25886
|
+
this._onFooterSlotChange = (e) => {
|
|
25887
|
+
const slot = e.target;
|
|
25888
|
+
this._hasFooter = slot.assignedNodes({ flatten: true }).length > 0;
|
|
25889
|
+
this.requestUpdate();
|
|
25890
|
+
};
|
|
25891
|
+
this._onHeaderActionsSlotChange = (e) => {
|
|
25892
|
+
const slot = e.target;
|
|
25893
|
+
this._hasHeaderActions = slot.assignedNodes({ flatten: true }).length > 0;
|
|
25894
|
+
this.requestUpdate();
|
|
25895
|
+
};
|
|
25896
|
+
}
|
|
25897
|
+
static {
|
|
25898
|
+
this.styles = [sharedStyles, componentStyles67, hostStyles69];
|
|
25899
|
+
}
|
|
25900
|
+
render() {
|
|
25901
|
+
const drawerClasses = {
|
|
25902
|
+
"drawer": true,
|
|
25903
|
+
"with-footer": this._hasFooter
|
|
25904
|
+
};
|
|
25905
|
+
const headerClasses = {
|
|
25906
|
+
"header": true
|
|
25907
|
+
};
|
|
25908
|
+
const contentClasses = {
|
|
25909
|
+
"content": true,
|
|
25910
|
+
"content-with-paddings": !this.disableContentPaddings
|
|
25911
|
+
};
|
|
25912
|
+
const footerClasses = {
|
|
25913
|
+
"footer": true
|
|
25914
|
+
};
|
|
25915
|
+
return html70`
|
|
25916
|
+
<div class=${classMap57(drawerClasses)} role="region">
|
|
25917
|
+
${this._hasHeader || this.loading ? html70`
|
|
25918
|
+
<div class=${classMap57(headerClasses)}>
|
|
25919
|
+
<slot name="header" @slotchange=${this._onHeaderSlotChange}></slot>
|
|
25920
|
+
${this._hasHeaderActions ? html70`<div class="header-actions"><slot name="headerActions" @slotchange=${this._onHeaderActionsSlotChange}></slot></div>` : html70`<slot name="headerActions" @slotchange=${this._onHeaderActionsSlotChange} style="display:none"></slot>`}
|
|
25921
|
+
</div>
|
|
25922
|
+
` : html70`
|
|
25923
|
+
<slot name="header" @slotchange=${this._onHeaderSlotChange} style="display:none"></slot>
|
|
25924
|
+
<slot name="headerActions" @slotchange=${this._onHeaderActionsSlotChange} style="display:none"></slot>
|
|
25925
|
+
`}
|
|
25926
|
+
<div class=${classMap57(contentClasses)}>
|
|
25927
|
+
${this.loading ? html70`<cs-spinner size="large"></cs-spinner>` : html70`<slot></slot>`}
|
|
25928
|
+
</div>
|
|
25929
|
+
${this._hasFooter ? html70`<div class=${classMap57(footerClasses)}><slot name="footer" @slotchange=${this._onFooterSlotChange}></slot></div>` : html70`<slot name="footer" @slotchange=${this._onFooterSlotChange} style="display:none"></slot>`}
|
|
25930
|
+
</div>
|
|
25931
|
+
`;
|
|
25932
|
+
}
|
|
25933
|
+
};
|
|
25934
|
+
__decorateClass([
|
|
25935
|
+
property69({ type: Boolean, reflect: true })
|
|
25936
|
+
], CsDrawerInternal.prototype, "loading", 2);
|
|
25937
|
+
__decorateClass([
|
|
25938
|
+
property69({ type: Boolean, reflect: true })
|
|
25939
|
+
], CsDrawerInternal.prototype, "disableContentPaddings", 2);
|
|
25940
|
+
|
|
25941
|
+
// src/drawer/index.ts
|
|
25942
|
+
var CsDrawer = class extends CsDrawerInternal {
|
|
25943
|
+
};
|
|
25944
|
+
customElements.define("cs-drawer", CsDrawer);
|
|
25945
|
+
|
|
25946
|
+
// src/split-panel/internal.ts
|
|
25947
|
+
import { css as css152, html as html71, nothing as nothing40 } from "lit";
|
|
25948
|
+
import { property as property70, state as state22 } from "lit/decorators.js";
|
|
25949
|
+
import { classMap as classMap58 } from "lit/directives/class-map.js";
|
|
25950
|
+
|
|
25951
|
+
// src/split-panel/styles.ts
|
|
25952
|
+
import { css as css151 } from "lit";
|
|
25953
|
+
var componentStyles68 = css151`
|
|
25954
|
+
.drawer {
|
|
25955
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
25956
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
25957
|
+
color: var(--color-text-body-default-vvtq8u, #0f141a);
|
|
25958
|
+
font-weight: 400;
|
|
25959
|
+
font-family: var(--font-family-base-gmnpzl, "Open Sans", "Helvetica Neue", Roboto, Arial, sans-serif);
|
|
25960
|
+
-webkit-font-smoothing: auto;
|
|
25961
|
+
-moz-osx-font-smoothing: auto;
|
|
25962
|
+
flex-shrink: 0;
|
|
25963
|
+
position: relative;
|
|
25964
|
+
min-inline-size: 0;
|
|
25965
|
+
word-break: break-word;
|
|
25966
|
+
background-color: var(--color-background-layout-panel-content-xto15e, #ffffff);
|
|
25967
|
+
z-index: 840;
|
|
25968
|
+
}
|
|
25969
|
+
.drawer-closed:not(.refresh) {
|
|
25970
|
+
min-inline-size: 40px;
|
|
25971
|
+
}
|
|
25972
|
+
|
|
25973
|
+
.drawer-content-side {
|
|
25974
|
+
display: flex;
|
|
25975
|
+
align-items: center;
|
|
25976
|
+
block-size: 100%;
|
|
25977
|
+
overflow: auto;
|
|
25978
|
+
}
|
|
25979
|
+
.drawer-content-side > [aria-hidden=true], .drawer-closed.refresh > .drawer-content-side {
|
|
25980
|
+
display: none;
|
|
25981
|
+
}
|
|
25982
|
+
.drawer-closed:not(.refresh) > .drawer-content-side {
|
|
25983
|
+
inline-size: 40px;
|
|
25984
|
+
}
|
|
25985
|
+
.drawer-closed:not(.refresh) > .drawer-content-side:hover {
|
|
25986
|
+
background: var(--color-background-layout-panel-hover-tguulw, #ebebf0);
|
|
25987
|
+
}
|
|
25988
|
+
|
|
25989
|
+
:not(.drawer-closed) > .drawer-content-bottom {
|
|
25990
|
+
overflow-y: auto;
|
|
25991
|
+
position: absolute;
|
|
25992
|
+
inset: 0;
|
|
25993
|
+
clip-path: border-box;
|
|
25994
|
+
}
|
|
25995
|
+
|
|
25996
|
+
.position-bottom {
|
|
25997
|
+
position: fixed;
|
|
25998
|
+
overflow-y: auto;
|
|
25999
|
+
/*
|
|
26000
|
+
Removed the position fixed with the AppLayout refactor because the
|
|
26001
|
+
SplitPanel is no longer in fixed position in the DOM.
|
|
26002
|
+
*/
|
|
26003
|
+
}
|
|
26004
|
+
.position-bottom:not(.hidden) {
|
|
26005
|
+
border-block-start: var(--border-panel-top-width-10990j, 1px) solid var(--color-border-divider-panel-bottom-bruvuz, #c6c6cd);
|
|
26006
|
+
}
|
|
26007
|
+
.position-bottom:not(.refresh) {
|
|
26008
|
+
box-shadow: var(--shadow-split-bottom-vlyulf, 0px -36px 36px -36px rgba(0, 7, 22, 0.1));
|
|
26009
|
+
border-inline-start: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-panel-bottom-bruvuz, #c6c6cd);
|
|
26010
|
+
border-inline-end: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-panel-bottom-bruvuz, #c6c6cd);
|
|
26011
|
+
}
|
|
26012
|
+
.position-bottom.drawer-closed {
|
|
26013
|
+
overflow: hidden;
|
|
26014
|
+
}
|
|
26015
|
+
.position-bottom.drawer-closed.drawer-clickable:hover {
|
|
26016
|
+
cursor: pointer;
|
|
26017
|
+
background: var(--color-background-layout-panel-hover-tguulw, #ebebf0);
|
|
26018
|
+
}
|
|
26019
|
+
.position-bottom > .drawer-content-bottom > [aria-hidden=true] {
|
|
26020
|
+
display: none;
|
|
26021
|
+
}
|
|
26022
|
+
.position-bottom.refresh {
|
|
26023
|
+
position: relative;
|
|
26024
|
+
}
|
|
26025
|
+
|
|
26026
|
+
.position-side {
|
|
26027
|
+
border-block-start: none;
|
|
26028
|
+
box-shadow: var(--shadow-split-side-nyajix, -1px 0px 1px 0px #e9ebed, -36px 6px 36px -36px rgba(0, 7, 22, 0.1));
|
|
26029
|
+
block-size: 100%;
|
|
26030
|
+
}
|
|
26031
|
+
.position-side.with-toolbar {
|
|
26032
|
+
box-shadow: none;
|
|
26033
|
+
}
|
|
26034
|
+
|
|
26035
|
+
.slider-wrapper-bottom {
|
|
26036
|
+
position: absolute;
|
|
26037
|
+
inset-block-start: 0;
|
|
26038
|
+
inset-inline-start: 0;
|
|
26039
|
+
inline-size: 100%;
|
|
26040
|
+
block-size: 18px;
|
|
26041
|
+
display: flex;
|
|
26042
|
+
justify-content: center;
|
|
26043
|
+
z-index: 2;
|
|
26044
|
+
}
|
|
26045
|
+
|
|
26046
|
+
.slider-wrapper-side {
|
|
26047
|
+
position: absolute;
|
|
26048
|
+
inset-inline-start: 0;
|
|
26049
|
+
inset-block-start: 0;
|
|
26050
|
+
block-size: 100%;
|
|
26051
|
+
inline-size: 18px;
|
|
26052
|
+
display: flex;
|
|
26053
|
+
align-items: center;
|
|
26054
|
+
z-index: 1;
|
|
26055
|
+
}
|
|
26056
|
+
.slider-wrapper-side.with-toolbar {
|
|
26057
|
+
position: unset;
|
|
26058
|
+
}
|
|
26059
|
+
|
|
26060
|
+
.open-button-side {
|
|
26061
|
+
flex: 0 0 auto;
|
|
26062
|
+
align-self: flex-start;
|
|
26063
|
+
box-sizing: border-box;
|
|
26064
|
+
margin-block-start: var(--space-xxs-hwfkai, 4px);
|
|
26065
|
+
margin-block-end: 0;
|
|
26066
|
+
margin-inline: auto;
|
|
26067
|
+
}
|
|
26068
|
+
|
|
26069
|
+
.pane-header-wrapper-bottom {
|
|
26070
|
+
position: sticky;
|
|
26071
|
+
inset-block-start: 0;
|
|
26072
|
+
display: flex;
|
|
26073
|
+
align-items: center;
|
|
26074
|
+
flex-direction: column;
|
|
26075
|
+
z-index: 1;
|
|
26076
|
+
padding-block: 0;
|
|
26077
|
+
padding-inline: var(--space-layout-content-horizontal-buc0zz, 24px);
|
|
26078
|
+
}
|
|
26079
|
+
.drawer-mobile > .drawer-content-bottom > .pane-header-wrapper-bottom {
|
|
26080
|
+
padding-block: 0;
|
|
26081
|
+
padding-inline: var(--space-l-2ud1p3, 20px);
|
|
26082
|
+
}
|
|
26083
|
+
.drawer-disable-content-paddings > .drawer-content-bottom > .pane-header-wrapper-bottom {
|
|
26084
|
+
padding-block: 0;
|
|
26085
|
+
padding-inline: var(--space-l-2ud1p3, 20px);
|
|
26086
|
+
}
|
|
26087
|
+
:not(.drawer-closed) > .drawer-content-bottom > .pane-header-wrapper-bottom {
|
|
26088
|
+
background-color: var(--color-background-layout-panel-content-xto15e, #ffffff);
|
|
26089
|
+
border-block-end: var(--border-panel-header-width-t1iq1m, 1px) solid var(--color-border-panel-header-ygztvl, #c6c6cd);
|
|
26090
|
+
}
|
|
26091
|
+
.with-toolbar:not(.drawer-closed) > .drawer-content-bottom > .pane-header-wrapper-bottom {
|
|
26092
|
+
border-color: transparent;
|
|
26093
|
+
}
|
|
26094
|
+
|
|
26095
|
+
.content-bottom {
|
|
26096
|
+
padding-block: 0;
|
|
26097
|
+
padding-inline: var(--space-layout-content-horizontal-buc0zz, 24px);
|
|
26098
|
+
margin-block-start: var(--space-panel-split-top-3u4vky, 20px);
|
|
26099
|
+
position: relative;
|
|
26100
|
+
z-index: 0;
|
|
26101
|
+
}
|
|
26102
|
+
.with-toolbar > .drawer-content-bottom > .content-bottom {
|
|
26103
|
+
margin-block-start: 0px;
|
|
26104
|
+
}
|
|
26105
|
+
.drawer-mobile > .drawer-content-bottom > .content-bottom {
|
|
26106
|
+
padding-block: 0;
|
|
26107
|
+
padding-inline: var(--space-l-2ud1p3, 20px);
|
|
26108
|
+
}
|
|
26109
|
+
.drawer-disable-content-paddings > .drawer-content-bottom > .content-bottom {
|
|
26110
|
+
padding-block: 0;
|
|
26111
|
+
padding-inline: 0;
|
|
26112
|
+
}
|
|
26113
|
+
|
|
26114
|
+
.pane-bottom-center-align {
|
|
26115
|
+
display: flex;
|
|
26116
|
+
justify-content: center;
|
|
26117
|
+
}
|
|
26118
|
+
|
|
26119
|
+
.pane-bottom-content-nav-padding {
|
|
26120
|
+
padding-inline-start: calc(var(--space-layout-toggle-diameter-j2qffw, 36px) + 2 * var(--space-layout-toggle-padding-chwlhz, 12px));
|
|
26121
|
+
}
|
|
26122
|
+
|
|
26123
|
+
.pane-bottom-content-tools-padding {
|
|
26124
|
+
padding-inline-end: calc(var(--space-layout-toggle-diameter-j2qffw, 36px) + 2 * var(--space-layout-toggle-padding-chwlhz, 12px));
|
|
26125
|
+
}
|
|
26126
|
+
|
|
26127
|
+
.content-bottom-max-width {
|
|
26128
|
+
flex-grow: 1;
|
|
26129
|
+
max-inline-size: 100%;
|
|
26130
|
+
}
|
|
26131
|
+
|
|
26132
|
+
.content-side {
|
|
26133
|
+
flex: auto;
|
|
26134
|
+
align-self: flex-start;
|
|
26135
|
+
box-sizing: border-box;
|
|
26136
|
+
overflow-y: auto;
|
|
26137
|
+
inset-block-start: 0;
|
|
26138
|
+
inset-inline: 0;
|
|
26139
|
+
block-size: 100%;
|
|
26140
|
+
}
|
|
26141
|
+
.content-side.with-toolbar {
|
|
26142
|
+
position: absolute;
|
|
26143
|
+
}
|
|
26144
|
+
.content-side > .pane-header-wrapper-side {
|
|
26145
|
+
padding-block: 0;
|
|
26146
|
+
padding-inline-end: var(--space-m-dsumyt, 16px);
|
|
26147
|
+
padding-inline-start: var(--space-panel-side-left-u1m3s9, 28px);
|
|
26148
|
+
border-block-end: var(--border-panel-header-width-t1iq1m, 1px) solid var(--color-border-panel-header-ygztvl, #c6c6cd);
|
|
26149
|
+
}
|
|
26150
|
+
.content-side.with-toolbar > .pane-header-wrapper-side {
|
|
26151
|
+
border-color: transparent;
|
|
26152
|
+
}
|
|
26153
|
+
.content-side > .pane-content-wrapper-side {
|
|
26154
|
+
padding-block: 0;
|
|
26155
|
+
padding-inline-start: var(--space-panel-side-left-u1m3s9, 28px);
|
|
26156
|
+
padding-inline-end: var(--space-panel-side-right-8wwirc, 24px);
|
|
26157
|
+
margin-block-start: var(--space-panel-split-top-3u4vky, 20px);
|
|
26158
|
+
margin-block-end: var(--space-panel-split-bottom-ir16d7, 20px);
|
|
26159
|
+
}
|
|
26160
|
+
.content-side.with-toolbar > .pane-content-wrapper-side {
|
|
26161
|
+
margin-block-start: 0px;
|
|
26162
|
+
}
|
|
26163
|
+
|
|
26164
|
+
.header {
|
|
26165
|
+
inline-size: 100%;
|
|
26166
|
+
margin-block: var(--size-vertical-panel-icon-offset-z959cw, 15px);
|
|
26167
|
+
margin-inline: 0;
|
|
26168
|
+
}
|
|
26169
|
+
.header.with-toolbar {
|
|
26170
|
+
margin-block: 14px;
|
|
26171
|
+
}
|
|
26172
|
+
.header-main-row, .header-main-content {
|
|
26173
|
+
display: flex;
|
|
26174
|
+
}
|
|
26175
|
+
.header-main-row {
|
|
26176
|
+
align-items: flex-start;
|
|
26177
|
+
}
|
|
26178
|
+
.header-main-content {
|
|
26179
|
+
flex: auto;
|
|
26180
|
+
flex-direction: row;
|
|
26181
|
+
column-gap: var(--space-scaled-xs-xwoogq, 8px);
|
|
26182
|
+
row-gap: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
26183
|
+
justify-content: space-between;
|
|
26184
|
+
align-items: flex-start;
|
|
26185
|
+
}
|
|
26186
|
+
.header-tag-and-info {
|
|
26187
|
+
flex-grow: 1;
|
|
26188
|
+
margin-block-start: calc(var(--space-scaled-xxs-pfm1nx, 4px) + 1px);
|
|
26189
|
+
line-height: var(--line-height-body-s-nu5hx1, 16px);
|
|
26190
|
+
}
|
|
26191
|
+
.header-tag-and-info.with-description {
|
|
26192
|
+
margin-block-end: var(--space-scaled-xxxs-oo06c7, 2px);
|
|
26193
|
+
}
|
|
26194
|
+
.header-tag.with-info, .header-text {
|
|
26195
|
+
display: inline;
|
|
26196
|
+
}
|
|
26197
|
+
.header-tag {
|
|
26198
|
+
margin-block: 0;
|
|
26199
|
+
}
|
|
26200
|
+
.header-before-slot, .header-text {
|
|
26201
|
+
font-size: var(--font-panel-header-size-33h9j8, 18px);
|
|
26202
|
+
letter-spacing: var(--letter-spacing-heading-m-29ewnk, -0.01em);
|
|
26203
|
+
line-height: var(--font-panel-header-line-height-8xb2qj, 22px);
|
|
26204
|
+
font-weight: var(--font-weight-heading-l-0t6dwc, 700);
|
|
26205
|
+
-webkit-font-smoothing: var(--font-smoothing-webkit-oemolo, antialiased);
|
|
26206
|
+
-moz-osx-font-smoothing: var(--font-smoothing-moz-osx-hbm0aq, grayscale);
|
|
26207
|
+
}
|
|
26208
|
+
.header-before-slot {
|
|
26209
|
+
margin-block-start: calc(-1 * calc(var(--space-scaled-xxs-pfm1nx, 4px) + 1px));
|
|
26210
|
+
}
|
|
26211
|
+
.header-tag.with-info > .header-before-slot, .header-before-slot.with-header-text {
|
|
26212
|
+
display: inline-block;
|
|
26213
|
+
}
|
|
26214
|
+
.header-before-slot.with-header-text, .header-tag.with-info {
|
|
26215
|
+
margin-inline-end: var(--space-scaled-xs-xwoogq, 8px);
|
|
26216
|
+
}
|
|
26217
|
+
.header-actions-slot {
|
|
26218
|
+
display: flex;
|
|
26219
|
+
flex-shrink: 0;
|
|
26220
|
+
align-items: center;
|
|
26221
|
+
min-block-size: calc(var(--font-panel-header-line-height-8xb2qj, 22px) + 2 * calc(var(--space-scaled-xxs-pfm1nx, 4px) + 1px));
|
|
26222
|
+
}
|
|
26223
|
+
.header-description {
|
|
26224
|
+
color: var(--color-text-heading-secondary-iwtvf6, #424650);
|
|
26225
|
+
font-size: var(--font-size-body-m-a7nh2n, 14px);
|
|
26226
|
+
line-height: var(--line-height-body-m-2mh3ke, 20px);
|
|
26227
|
+
margin-block: 0;
|
|
26228
|
+
}
|
|
26229
|
+
|
|
26230
|
+
.header-buttons {
|
|
26231
|
+
display: flex;
|
|
26232
|
+
flex-direction: row;
|
|
26233
|
+
justify-content: space-between;
|
|
26234
|
+
flex: 0 0 auto;
|
|
26235
|
+
margin-inline-start: var(--space-xs-ymlm0b, 8px);
|
|
26236
|
+
}
|
|
26237
|
+
|
|
26238
|
+
.divider {
|
|
26239
|
+
border-inline-end: var(--border-divider-section-width-uwo8my, 1px) solid var(--color-border-divider-default-nr68jt, #c6c6cd);
|
|
26240
|
+
margin-block: var(--space-scaled-xxs-pfm1nx, 4px);
|
|
26241
|
+
margin-inline: var(--space-scaled-xs-xwoogq, 8px);
|
|
26242
|
+
}
|
|
26243
|
+
`;
|
|
26244
|
+
|
|
26245
|
+
// src/split-panel/internal.ts
|
|
26246
|
+
var hostStyles70 = css152`:host { display: block; }`;
|
|
26247
|
+
var CsSplitPanelInternal = class extends CsBaseElement {
|
|
26248
|
+
constructor() {
|
|
26249
|
+
super(...arguments);
|
|
26250
|
+
this.header = "";
|
|
26251
|
+
this.hidePreferencesButton = false;
|
|
26252
|
+
this.closeBehavior = "collapse";
|
|
26253
|
+
this.size = 250;
|
|
26254
|
+
this.panelAriaLabel = "";
|
|
26255
|
+
this._isOpen = true;
|
|
26256
|
+
this._position = "bottom";
|
|
26257
|
+
this._onClose = () => {
|
|
26258
|
+
this._isOpen = false;
|
|
26259
|
+
this.requestUpdate();
|
|
26260
|
+
};
|
|
26261
|
+
this._onOpen = () => {
|
|
26262
|
+
this._isOpen = true;
|
|
26263
|
+
this.requestUpdate();
|
|
26264
|
+
};
|
|
26265
|
+
this._onPreferencesClick = () => {
|
|
26266
|
+
const newPosition = this._position === "bottom" ? "side" : "bottom";
|
|
26267
|
+
this._position = newPosition;
|
|
26268
|
+
fireNonCancelableEvent(this, "preferencesChange", { position: newPosition });
|
|
26269
|
+
};
|
|
26270
|
+
}
|
|
26271
|
+
static {
|
|
26272
|
+
this.styles = [sharedStyles, componentStyles68, hostStyles70];
|
|
26273
|
+
}
|
|
26274
|
+
get _regionLabel() {
|
|
26275
|
+
return this.panelAriaLabel || this.header;
|
|
26276
|
+
}
|
|
26277
|
+
render() {
|
|
26278
|
+
const closeLabel = this.i18nStrings?.closeButtonAriaLabel ?? "Close";
|
|
26279
|
+
const openLabel = this.i18nStrings?.openButtonAriaLabel ?? "Open";
|
|
26280
|
+
if (!this._isOpen && this.closeBehavior === "hide") {
|
|
26281
|
+
return html71``;
|
|
26282
|
+
}
|
|
26283
|
+
const isBottom = this._position === "bottom";
|
|
26284
|
+
const drawerClasses = {
|
|
26285
|
+
"drawer": true,
|
|
26286
|
+
"drawer-closed": !this._isOpen,
|
|
26287
|
+
"position-bottom": isBottom,
|
|
26288
|
+
"position-side": !isBottom,
|
|
26289
|
+
"refresh": true
|
|
26290
|
+
};
|
|
26291
|
+
const headerClasses = {
|
|
26292
|
+
"header": true
|
|
26293
|
+
};
|
|
26294
|
+
const contentBottomClasses = {
|
|
26295
|
+
"content-bottom": true
|
|
26296
|
+
};
|
|
26297
|
+
const contentSideClasses = {
|
|
26298
|
+
"content-side": true
|
|
26299
|
+
};
|
|
26300
|
+
const paneHeaderBottomClasses = {
|
|
26301
|
+
"pane-header-wrapper-bottom": true
|
|
26302
|
+
};
|
|
26303
|
+
const paneHeaderSideClasses = {
|
|
26304
|
+
"pane-header-wrapper-side": true
|
|
26305
|
+
};
|
|
26306
|
+
if (!this._isOpen) {
|
|
26307
|
+
return html71`
|
|
26308
|
+
<div class=${classMap58(drawerClasses)}
|
|
26309
|
+
role="region"
|
|
26310
|
+
aria-label=${this._regionLabel}>
|
|
26311
|
+
${isBottom ? html71`
|
|
26312
|
+
<div class="drawer-content-bottom">
|
|
26313
|
+
<div class=${classMap58(paneHeaderBottomClasses)}>
|
|
26314
|
+
<div class=${classMap58(headerClasses)}>
|
|
26315
|
+
<div class="header-main-row">
|
|
26316
|
+
<div class="header-main-content">
|
|
26317
|
+
<div class="header-text">${this.header}</div>
|
|
26318
|
+
</div>
|
|
26319
|
+
<div class="header-buttons">
|
|
26320
|
+
<cs-button
|
|
26321
|
+
variant="icon"
|
|
26322
|
+
icon-name="angle-up"
|
|
26323
|
+
aria-label=${openLabel}
|
|
26324
|
+
@click=${this._onOpen}
|
|
26325
|
+
></cs-button>
|
|
26326
|
+
</div>
|
|
26327
|
+
</div>
|
|
26328
|
+
</div>
|
|
26329
|
+
</div>
|
|
26330
|
+
</div>
|
|
26331
|
+
` : html71`
|
|
26332
|
+
<div class="drawer-content-side">
|
|
26333
|
+
<cs-button
|
|
26334
|
+
class="open-button-side"
|
|
26335
|
+
variant="icon"
|
|
26336
|
+
icon-name="angle-left"
|
|
26337
|
+
aria-label=${openLabel}
|
|
26338
|
+
@click=${this._onOpen}
|
|
26339
|
+
></cs-button>
|
|
26340
|
+
</div>
|
|
26341
|
+
`}
|
|
26342
|
+
</div>
|
|
26343
|
+
`;
|
|
26344
|
+
}
|
|
26345
|
+
return html71`
|
|
26346
|
+
<div class=${classMap58(drawerClasses)}
|
|
26347
|
+
role="region"
|
|
26348
|
+
aria-label=${this._regionLabel}
|
|
26349
|
+
style="block-size: ${this.size}px;">
|
|
26350
|
+
${isBottom ? html71`
|
|
26351
|
+
<div class="drawer-content-bottom">
|
|
26352
|
+
<div class=${classMap58(paneHeaderBottomClasses)}>
|
|
26353
|
+
<div class=${classMap58(headerClasses)}>
|
|
26354
|
+
<div class="header-main-row">
|
|
26355
|
+
<div class="header-main-content">
|
|
26356
|
+
<div class="header-text">${this.header}</div>
|
|
26357
|
+
</div>
|
|
26358
|
+
<div class="header-buttons">
|
|
26359
|
+
${!this.hidePreferencesButton ? html71`
|
|
26360
|
+
<cs-button
|
|
26361
|
+
variant="icon"
|
|
26362
|
+
icon-name="resize-area"
|
|
26363
|
+
aria-label="Preferences"
|
|
26364
|
+
@click=${this._onPreferencesClick}
|
|
26365
|
+
></cs-button>
|
|
26366
|
+
<div class="divider"></div>
|
|
26367
|
+
` : nothing40}
|
|
26368
|
+
<cs-button
|
|
26369
|
+
variant="icon"
|
|
26370
|
+
icon-name="angle-down"
|
|
26371
|
+
aria-label=${closeLabel}
|
|
26372
|
+
@click=${this._onClose}
|
|
26373
|
+
></cs-button>
|
|
26374
|
+
</div>
|
|
26375
|
+
</div>
|
|
26376
|
+
</div>
|
|
26377
|
+
</div>
|
|
26378
|
+
<div class=${classMap58(contentBottomClasses)}>
|
|
26379
|
+
<slot></slot>
|
|
26380
|
+
</div>
|
|
26381
|
+
</div>
|
|
26382
|
+
` : html71`
|
|
26383
|
+
<div class="drawer-content-side">
|
|
26384
|
+
<div class=${classMap58(contentSideClasses)}>
|
|
26385
|
+
<div class=${classMap58(paneHeaderSideClasses)}>
|
|
26386
|
+
<div class=${classMap58(headerClasses)}>
|
|
26387
|
+
<div class="header-main-row">
|
|
26388
|
+
<div class="header-main-content">
|
|
26389
|
+
<div class="header-text">${this.header}</div>
|
|
26390
|
+
</div>
|
|
26391
|
+
<div class="header-buttons">
|
|
26392
|
+
${!this.hidePreferencesButton ? html71`
|
|
26393
|
+
<cs-button
|
|
26394
|
+
variant="icon"
|
|
26395
|
+
icon-name="resize-area"
|
|
26396
|
+
aria-label="Preferences"
|
|
26397
|
+
@click=${this._onPreferencesClick}
|
|
26398
|
+
></cs-button>
|
|
26399
|
+
<div class="divider"></div>
|
|
26400
|
+
` : nothing40}
|
|
26401
|
+
<cs-button
|
|
26402
|
+
variant="icon"
|
|
26403
|
+
icon-name="close"
|
|
26404
|
+
aria-label=${closeLabel}
|
|
26405
|
+
@click=${this._onClose}
|
|
26406
|
+
></cs-button>
|
|
26407
|
+
</div>
|
|
26408
|
+
</div>
|
|
26409
|
+
</div>
|
|
26410
|
+
</div>
|
|
26411
|
+
<div class="pane-content-wrapper-side">
|
|
26412
|
+
<slot></slot>
|
|
26413
|
+
</div>
|
|
26414
|
+
</div>
|
|
26415
|
+
</div>
|
|
26416
|
+
`}
|
|
26417
|
+
</div>
|
|
26418
|
+
`;
|
|
26419
|
+
}
|
|
26420
|
+
};
|
|
26421
|
+
__decorateClass([
|
|
26422
|
+
property70({ type: String })
|
|
26423
|
+
], CsSplitPanelInternal.prototype, "header", 2);
|
|
26424
|
+
__decorateClass([
|
|
26425
|
+
property70({ type: Boolean, reflect: true })
|
|
26426
|
+
], CsSplitPanelInternal.prototype, "hidePreferencesButton", 2);
|
|
26427
|
+
__decorateClass([
|
|
26428
|
+
property70({ type: String, reflect: true })
|
|
26429
|
+
], CsSplitPanelInternal.prototype, "closeBehavior", 2);
|
|
26430
|
+
__decorateClass([
|
|
26431
|
+
property70({ type: Number })
|
|
26432
|
+
], CsSplitPanelInternal.prototype, "size", 2);
|
|
26433
|
+
__decorateClass([
|
|
26434
|
+
property70({ type: String, attribute: "panel-aria-label" })
|
|
26435
|
+
], CsSplitPanelInternal.prototype, "panelAriaLabel", 2);
|
|
26436
|
+
__decorateClass([
|
|
26437
|
+
property70({ type: Object })
|
|
26438
|
+
], CsSplitPanelInternal.prototype, "i18nStrings", 2);
|
|
26439
|
+
__decorateClass([
|
|
26440
|
+
state22()
|
|
26441
|
+
], CsSplitPanelInternal.prototype, "_isOpen", 2);
|
|
26442
|
+
__decorateClass([
|
|
26443
|
+
state22()
|
|
26444
|
+
], CsSplitPanelInternal.prototype, "_position", 2);
|
|
26445
|
+
|
|
26446
|
+
// src/split-panel/index.ts
|
|
26447
|
+
var CsSplitPanel = class extends CsSplitPanelInternal {
|
|
26448
|
+
};
|
|
26449
|
+
customElements.define("cs-split-panel", CsSplitPanel);
|
|
26450
|
+
|
|
26451
|
+
// src/annotation-context/internal.ts
|
|
26452
|
+
import { html as html72 } from "lit";
|
|
26453
|
+
import { property as property71 } from "lit/decorators.js";
|
|
26454
|
+
import { provide as provide4, createContext as createContext4 } from "@lit/context";
|
|
26455
|
+
var annotationContext = createContext4(
|
|
26456
|
+
/* @__PURE__ */ Symbol("annotation-context")
|
|
26457
|
+
);
|
|
26458
|
+
var CsAnnotationContextInternal = class extends CsBaseElement {
|
|
26459
|
+
constructor() {
|
|
26460
|
+
super(...arguments);
|
|
26461
|
+
this.currentTutorial = null;
|
|
26462
|
+
}
|
|
26463
|
+
createRenderRoot() {
|
|
26464
|
+
return this;
|
|
26465
|
+
}
|
|
26466
|
+
willUpdate() {
|
|
26467
|
+
let totalSteps = 0;
|
|
26468
|
+
if (this.currentTutorial) {
|
|
26469
|
+
for (const task of this.currentTutorial.tasks) {
|
|
26470
|
+
totalSteps += task.steps.length;
|
|
26471
|
+
}
|
|
26472
|
+
}
|
|
26473
|
+
this._contextValue = {
|
|
26474
|
+
currentTutorial: this.currentTutorial ?? null,
|
|
26475
|
+
currentStepIndex: 0,
|
|
26476
|
+
totalSteps,
|
|
26477
|
+
i18nStrings: this.i18nStrings,
|
|
26478
|
+
onStepChange: (detail) => {
|
|
26479
|
+
fireNonCancelableEvent(this, "stepChange", detail);
|
|
26480
|
+
},
|
|
26481
|
+
onDismiss: () => {
|
|
26482
|
+
if (this.currentTutorial) {
|
|
26483
|
+
fireNonCancelableEvent(this, "exitTutorial", { tutorial: this.currentTutorial });
|
|
26484
|
+
}
|
|
26485
|
+
}
|
|
26486
|
+
};
|
|
26487
|
+
}
|
|
26488
|
+
render() {
|
|
26489
|
+
return html72`<slot></slot>`;
|
|
26490
|
+
}
|
|
26491
|
+
};
|
|
26492
|
+
__decorateClass([
|
|
26493
|
+
property71({ attribute: false })
|
|
26494
|
+
], CsAnnotationContextInternal.prototype, "currentTutorial", 2);
|
|
26495
|
+
__decorateClass([
|
|
26496
|
+
property71({ attribute: false })
|
|
26497
|
+
], CsAnnotationContextInternal.prototype, "i18nStrings", 2);
|
|
26498
|
+
__decorateClass([
|
|
26499
|
+
provide4({ context: annotationContext })
|
|
26500
|
+
], CsAnnotationContextInternal.prototype, "_contextValue", 2);
|
|
26501
|
+
|
|
26502
|
+
// src/annotation-context/index.ts
|
|
26503
|
+
var CsAnnotationContext = class extends CsAnnotationContextInternal {
|
|
26504
|
+
};
|
|
26505
|
+
customElements.define("cs-annotation-context", CsAnnotationContext);
|
|
23211
26506
|
export {
|
|
23212
26507
|
CsAlert,
|
|
23213
26508
|
CsAnchorNavigation,
|
|
26509
|
+
CsAnnotationContext,
|
|
23214
26510
|
CsAttributeEditor,
|
|
23215
26511
|
CsAutosuggest,
|
|
23216
26512
|
CsBadge,
|
|
@@ -23222,6 +26518,7 @@ export {
|
|
|
23222
26518
|
CsCalendar,
|
|
23223
26519
|
CsCards,
|
|
23224
26520
|
CsCheckbox,
|
|
26521
|
+
CsCodeEditor,
|
|
23225
26522
|
CsCollectionPreferences,
|
|
23226
26523
|
CsColumnLayout,
|
|
23227
26524
|
CsContainer,
|
|
@@ -23230,6 +26527,7 @@ export {
|
|
|
23230
26527
|
CsDateInput,
|
|
23231
26528
|
CsDatePicker,
|
|
23232
26529
|
CsDateRangePicker,
|
|
26530
|
+
CsDrawer,
|
|
23233
26531
|
CsErrorBoundary,
|
|
23234
26532
|
CsExpandableSection,
|
|
23235
26533
|
CsFileDropzone,
|
|
@@ -23240,6 +26538,7 @@ export {
|
|
|
23240
26538
|
CsFormField,
|
|
23241
26539
|
CsGrid,
|
|
23242
26540
|
CsHeader,
|
|
26541
|
+
CsHelpPanel,
|
|
23243
26542
|
CsIcon,
|
|
23244
26543
|
CsIconProvider,
|
|
23245
26544
|
CsKeyValuePairs,
|
|
@@ -23256,9 +26555,11 @@ export {
|
|
|
23256
26555
|
CsRadioGroup,
|
|
23257
26556
|
CsSegmentedControl,
|
|
23258
26557
|
CsSelect,
|
|
26558
|
+
CsSideNavigation,
|
|
23259
26559
|
CsSlider,
|
|
23260
26560
|
CsSpaceBetween,
|
|
23261
26561
|
CsSpinner,
|
|
26562
|
+
CsSplitPanel,
|
|
23262
26563
|
CsStatusIndicator,
|
|
23263
26564
|
CsSteps,
|
|
23264
26565
|
CsTable,
|
|
@@ -23271,5 +26572,7 @@ export {
|
|
|
23271
26572
|
CsToken,
|
|
23272
26573
|
CsTokenGroup,
|
|
23273
26574
|
CsTooltip,
|
|
23274
|
-
|
|
26575
|
+
CsTopNavigation,
|
|
26576
|
+
CsTreeView,
|
|
26577
|
+
CsWizard
|
|
23275
26578
|
};
|