@ni/nimble-components 11.2.0 → 11.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/all-components-bundle.js +703 -61
- package/dist/all-components-bundle.js.map +1 -1
- package/dist/all-components-bundle.min.js +966 -892
- package/dist/all-components-bundle.min.js.map +1 -1
- package/dist/esm/all-components.d.ts +1 -0
- package/dist/esm/all-components.js +1 -0
- package/dist/esm/all-components.js.map +1 -1
- package/dist/esm/theme-provider/design-token-comments.js +2 -0
- package/dist/esm/theme-provider/design-token-comments.js.map +1 -1
- package/dist/esm/theme-provider/design-token-names.js +2 -0
- package/dist/esm/theme-provider/design-token-names.js.map +1 -1
- package/dist/esm/theme-provider/design-tokens.d.ts +2 -0
- package/dist/esm/theme-provider/design-tokens.js +7 -5
- package/dist/esm/theme-provider/design-tokens.js.map +1 -1
- package/dist/esm/tooltip/index.d.ts +11 -0
- package/dist/esm/tooltip/index.js +15 -0
- package/dist/esm/tooltip/index.js.map +1 -0
- package/dist/esm/tooltip/styles.d.ts +1 -0
- package/dist/esm/tooltip/styles.js +27 -0
- package/dist/esm/tooltip/styles.js.map +1 -0
- package/dist/tokens-internal.scss +12 -0
- package/dist/tokens.scss +6 -0
- package/package.json +1 -1
|
@@ -13138,6 +13138,607 @@
|
|
|
13138
13138
|
applyMixins(DelegatesARIAToolbar, ARIAGlobalStatesAndProperties);
|
|
13139
13139
|
applyMixins(Toolbar$1, StartEnd, DelegatesARIAToolbar);
|
|
13140
13140
|
|
|
13141
|
+
/**
|
|
13142
|
+
* Creates a template for the {@link @microsoft/fast-foundation#(Tooltip:class)} component using the provided prefix.
|
|
13143
|
+
* @public
|
|
13144
|
+
*/
|
|
13145
|
+
const tooltipTemplate = (context, definition) => {
|
|
13146
|
+
return html `
|
|
13147
|
+
${when(x => x.tooltipVisible, html `
|
|
13148
|
+
<${context.tagFor(AnchoredRegion$1)}
|
|
13149
|
+
fixed-placement="true"
|
|
13150
|
+
auto-update-mode="${x => x.autoUpdateMode}"
|
|
13151
|
+
vertical-positioning-mode="${x => x.verticalPositioningMode}"
|
|
13152
|
+
vertical-default-position="${x => x.verticalDefaultPosition}"
|
|
13153
|
+
vertical-inset="${x => x.verticalInset}"
|
|
13154
|
+
vertical-scaling="${x => x.verticalScaling}"
|
|
13155
|
+
horizontal-positioning-mode="${x => x.horizontalPositioningMode}"
|
|
13156
|
+
horizontal-default-position="${x => x.horizontalDefaultPosition}"
|
|
13157
|
+
horizontal-scaling="${x => x.horizontalScaling}"
|
|
13158
|
+
horizontal-inset="${x => x.horizontalInset}"
|
|
13159
|
+
vertical-viewport-lock="${x => x.horizontalViewportLock}"
|
|
13160
|
+
horizontal-viewport-lock="${x => x.verticalViewportLock}"
|
|
13161
|
+
dir="${x => x.currentDirection}"
|
|
13162
|
+
${ref("region")}
|
|
13163
|
+
>
|
|
13164
|
+
<div class="tooltip" part="tooltip" role="tooltip">
|
|
13165
|
+
<slot></slot>
|
|
13166
|
+
</div>
|
|
13167
|
+
</${context.tagFor(AnchoredRegion$1)}>
|
|
13168
|
+
`)}
|
|
13169
|
+
`;
|
|
13170
|
+
};
|
|
13171
|
+
|
|
13172
|
+
/**
|
|
13173
|
+
* Enumerates possible tooltip positions
|
|
13174
|
+
*
|
|
13175
|
+
* @public
|
|
13176
|
+
*/
|
|
13177
|
+
const TooltipPosition = {
|
|
13178
|
+
/**
|
|
13179
|
+
* The tooltip is positioned above the element
|
|
13180
|
+
*/
|
|
13181
|
+
top: "top",
|
|
13182
|
+
/**
|
|
13183
|
+
* The tooltip is positioned to the right of the element
|
|
13184
|
+
*/
|
|
13185
|
+
right: "right",
|
|
13186
|
+
/**
|
|
13187
|
+
* The tooltip is positioned below the element
|
|
13188
|
+
*/
|
|
13189
|
+
bottom: "bottom",
|
|
13190
|
+
/**
|
|
13191
|
+
* The tooltip is positioned to the left of the element
|
|
13192
|
+
*/
|
|
13193
|
+
left: "left",
|
|
13194
|
+
/**
|
|
13195
|
+
* The tooltip is positioned before the element
|
|
13196
|
+
*/
|
|
13197
|
+
start: "start",
|
|
13198
|
+
/**
|
|
13199
|
+
* The tooltip is positioned after the element
|
|
13200
|
+
*/
|
|
13201
|
+
end: "end",
|
|
13202
|
+
/**
|
|
13203
|
+
* The tooltip is positioned above the element and to the left
|
|
13204
|
+
*/
|
|
13205
|
+
topLeft: "top-left",
|
|
13206
|
+
/**
|
|
13207
|
+
* The tooltip is positioned above the element and to the right
|
|
13208
|
+
*/
|
|
13209
|
+
topRight: "top-right",
|
|
13210
|
+
/**
|
|
13211
|
+
* The tooltip is positioned below the element and to the left
|
|
13212
|
+
*/
|
|
13213
|
+
bottomLeft: "bottom-left",
|
|
13214
|
+
/**
|
|
13215
|
+
* The tooltip is positioned below the element and to the right
|
|
13216
|
+
*/
|
|
13217
|
+
bottomRight: "bottom-right",
|
|
13218
|
+
/**
|
|
13219
|
+
* The tooltip is positioned above the element and to the left
|
|
13220
|
+
*/
|
|
13221
|
+
topStart: "top-start",
|
|
13222
|
+
/**
|
|
13223
|
+
* The tooltip is positioned above the element and to the right
|
|
13224
|
+
*/
|
|
13225
|
+
topEnd: "top-end",
|
|
13226
|
+
/**
|
|
13227
|
+
* The tooltip is positioned below the element and to the left
|
|
13228
|
+
*/
|
|
13229
|
+
bottomStart: "bottom-start",
|
|
13230
|
+
/**
|
|
13231
|
+
* The tooltip is positioned below the element and to the right
|
|
13232
|
+
*/
|
|
13233
|
+
bottomEnd: "bottom-end",
|
|
13234
|
+
};
|
|
13235
|
+
|
|
13236
|
+
/**
|
|
13237
|
+
* An Tooltip Custom HTML Element.
|
|
13238
|
+
*
|
|
13239
|
+
* @slot - The default slot for the tooltip content
|
|
13240
|
+
* @csspart tooltip - The tooltip element
|
|
13241
|
+
* @fires dismiss - Fires a custom 'dismiss' event when the tooltip is visible and escape key is pressed
|
|
13242
|
+
*
|
|
13243
|
+
* @public
|
|
13244
|
+
*/
|
|
13245
|
+
class Tooltip$1 extends FoundationElement {
|
|
13246
|
+
constructor() {
|
|
13247
|
+
super(...arguments);
|
|
13248
|
+
/**
|
|
13249
|
+
* The id of the element the tooltip is anchored to
|
|
13250
|
+
*
|
|
13251
|
+
* @defaultValue - undefined
|
|
13252
|
+
* @public
|
|
13253
|
+
* HTML Attribute: anchor
|
|
13254
|
+
*/
|
|
13255
|
+
this.anchor = "";
|
|
13256
|
+
/**
|
|
13257
|
+
* The delay in milliseconds before a tooltip is shown after a hover event
|
|
13258
|
+
*
|
|
13259
|
+
* @defaultValue - 300
|
|
13260
|
+
* @public
|
|
13261
|
+
* HTML Attribute: delay
|
|
13262
|
+
*/
|
|
13263
|
+
this.delay = 300;
|
|
13264
|
+
/**
|
|
13265
|
+
* Controls when the tooltip updates its position, default is 'anchor' which only updates when
|
|
13266
|
+
* the anchor is resized. 'auto' will update on scroll/resize events.
|
|
13267
|
+
* Corresponds to anchored-region auto-update-mode.
|
|
13268
|
+
* @public
|
|
13269
|
+
* @remarks
|
|
13270
|
+
* HTML Attribute: auto-update-mode
|
|
13271
|
+
*/
|
|
13272
|
+
this.autoUpdateMode = "anchor";
|
|
13273
|
+
/**
|
|
13274
|
+
* the html element currently being used as anchor.
|
|
13275
|
+
* Setting this directly overrides the anchor attribute.
|
|
13276
|
+
*
|
|
13277
|
+
* @public
|
|
13278
|
+
*/
|
|
13279
|
+
this.anchorElement = null;
|
|
13280
|
+
/**
|
|
13281
|
+
* The current viewport element instance
|
|
13282
|
+
*
|
|
13283
|
+
* @internal
|
|
13284
|
+
*/
|
|
13285
|
+
this.viewportElement = null;
|
|
13286
|
+
/**
|
|
13287
|
+
* @internal
|
|
13288
|
+
* @defaultValue "dynamic"
|
|
13289
|
+
*/
|
|
13290
|
+
this.verticalPositioningMode = "dynamic";
|
|
13291
|
+
/**
|
|
13292
|
+
* @internal
|
|
13293
|
+
* @defaultValue "dynamic"
|
|
13294
|
+
*/
|
|
13295
|
+
this.horizontalPositioningMode = "dynamic";
|
|
13296
|
+
/**
|
|
13297
|
+
* @internal
|
|
13298
|
+
*/
|
|
13299
|
+
this.horizontalInset = "false";
|
|
13300
|
+
/**
|
|
13301
|
+
* @internal
|
|
13302
|
+
*/
|
|
13303
|
+
this.verticalInset = "false";
|
|
13304
|
+
/**
|
|
13305
|
+
* @internal
|
|
13306
|
+
*/
|
|
13307
|
+
this.horizontalScaling = "content";
|
|
13308
|
+
/**
|
|
13309
|
+
* @internal
|
|
13310
|
+
*/
|
|
13311
|
+
this.verticalScaling = "content";
|
|
13312
|
+
/**
|
|
13313
|
+
* @internal
|
|
13314
|
+
*/
|
|
13315
|
+
this.verticalDefaultPosition = undefined;
|
|
13316
|
+
/**
|
|
13317
|
+
* @internal
|
|
13318
|
+
*/
|
|
13319
|
+
this.horizontalDefaultPosition = undefined;
|
|
13320
|
+
/**
|
|
13321
|
+
* @internal
|
|
13322
|
+
*/
|
|
13323
|
+
this.tooltipVisible = false;
|
|
13324
|
+
/**
|
|
13325
|
+
* Track current direction to pass to the anchored region
|
|
13326
|
+
* updated when tooltip is shown
|
|
13327
|
+
*
|
|
13328
|
+
* @internal
|
|
13329
|
+
*/
|
|
13330
|
+
this.currentDirection = Direction.ltr;
|
|
13331
|
+
/**
|
|
13332
|
+
* The timer that tracks delay time before the tooltip is shown on hover
|
|
13333
|
+
*/
|
|
13334
|
+
this.showDelayTimer = null;
|
|
13335
|
+
/**
|
|
13336
|
+
* The timer that tracks delay time before the tooltip is hidden
|
|
13337
|
+
*/
|
|
13338
|
+
this.hideDelayTimer = null;
|
|
13339
|
+
/**
|
|
13340
|
+
* Indicates whether the anchor is currently being hovered or has focus
|
|
13341
|
+
*/
|
|
13342
|
+
this.isAnchorHoveredFocused = false;
|
|
13343
|
+
/**
|
|
13344
|
+
* Indicates whether the region is currently being hovered
|
|
13345
|
+
*/
|
|
13346
|
+
this.isRegionHovered = false;
|
|
13347
|
+
/**
|
|
13348
|
+
* invoked when the anchored region's position relative to the anchor changes
|
|
13349
|
+
*
|
|
13350
|
+
* @internal
|
|
13351
|
+
*/
|
|
13352
|
+
this.handlePositionChange = (ev) => {
|
|
13353
|
+
this.classList.toggle("top", this.region.verticalPosition === "start");
|
|
13354
|
+
this.classList.toggle("bottom", this.region.verticalPosition === "end");
|
|
13355
|
+
this.classList.toggle("inset-top", this.region.verticalPosition === "insetStart");
|
|
13356
|
+
this.classList.toggle("inset-bottom", this.region.verticalPosition === "insetEnd");
|
|
13357
|
+
this.classList.toggle("center-vertical", this.region.verticalPosition === "center");
|
|
13358
|
+
this.classList.toggle("left", this.region.horizontalPosition === "start");
|
|
13359
|
+
this.classList.toggle("right", this.region.horizontalPosition === "end");
|
|
13360
|
+
this.classList.toggle("inset-left", this.region.horizontalPosition === "insetStart");
|
|
13361
|
+
this.classList.toggle("inset-right", this.region.horizontalPosition === "insetEnd");
|
|
13362
|
+
this.classList.toggle("center-horizontal", this.region.horizontalPosition === "center");
|
|
13363
|
+
};
|
|
13364
|
+
/**
|
|
13365
|
+
* mouse enters region
|
|
13366
|
+
*/
|
|
13367
|
+
this.handleRegionMouseOver = (ev) => {
|
|
13368
|
+
this.isRegionHovered = true;
|
|
13369
|
+
};
|
|
13370
|
+
/**
|
|
13371
|
+
* mouse leaves region
|
|
13372
|
+
*/
|
|
13373
|
+
this.handleRegionMouseOut = (ev) => {
|
|
13374
|
+
this.isRegionHovered = false;
|
|
13375
|
+
this.startHideDelayTimer();
|
|
13376
|
+
};
|
|
13377
|
+
/**
|
|
13378
|
+
* mouse enters anchor
|
|
13379
|
+
*/
|
|
13380
|
+
this.handleAnchorMouseOver = (ev) => {
|
|
13381
|
+
if (this.tooltipVisible) {
|
|
13382
|
+
// tooltip is already visible, just set the anchor hover flag
|
|
13383
|
+
this.isAnchorHoveredFocused = true;
|
|
13384
|
+
return;
|
|
13385
|
+
}
|
|
13386
|
+
this.startShowDelayTimer();
|
|
13387
|
+
};
|
|
13388
|
+
/**
|
|
13389
|
+
* mouse leaves anchor
|
|
13390
|
+
*/
|
|
13391
|
+
this.handleAnchorMouseOut = (ev) => {
|
|
13392
|
+
this.isAnchorHoveredFocused = false;
|
|
13393
|
+
this.clearShowDelayTimer();
|
|
13394
|
+
this.startHideDelayTimer();
|
|
13395
|
+
};
|
|
13396
|
+
/**
|
|
13397
|
+
* anchor gets focus
|
|
13398
|
+
*/
|
|
13399
|
+
this.handleAnchorFocusIn = (ev) => {
|
|
13400
|
+
this.startShowDelayTimer();
|
|
13401
|
+
};
|
|
13402
|
+
/**
|
|
13403
|
+
* anchor loses focus
|
|
13404
|
+
*/
|
|
13405
|
+
this.handleAnchorFocusOut = (ev) => {
|
|
13406
|
+
this.isAnchorHoveredFocused = false;
|
|
13407
|
+
this.clearShowDelayTimer();
|
|
13408
|
+
this.startHideDelayTimer();
|
|
13409
|
+
};
|
|
13410
|
+
/**
|
|
13411
|
+
* starts the hide timer
|
|
13412
|
+
*/
|
|
13413
|
+
this.startHideDelayTimer = () => {
|
|
13414
|
+
this.clearHideDelayTimer();
|
|
13415
|
+
if (!this.tooltipVisible) {
|
|
13416
|
+
return;
|
|
13417
|
+
}
|
|
13418
|
+
// allow 60 ms for account for pointer to move between anchor/tooltip
|
|
13419
|
+
// without hiding tooltip
|
|
13420
|
+
this.hideDelayTimer = window.setTimeout(() => {
|
|
13421
|
+
this.updateTooltipVisibility();
|
|
13422
|
+
}, 60);
|
|
13423
|
+
};
|
|
13424
|
+
/**
|
|
13425
|
+
* clears the hide delay
|
|
13426
|
+
*/
|
|
13427
|
+
this.clearHideDelayTimer = () => {
|
|
13428
|
+
if (this.hideDelayTimer !== null) {
|
|
13429
|
+
clearTimeout(this.hideDelayTimer);
|
|
13430
|
+
this.hideDelayTimer = null;
|
|
13431
|
+
}
|
|
13432
|
+
};
|
|
13433
|
+
/**
|
|
13434
|
+
* starts the show timer if not currently running
|
|
13435
|
+
*/
|
|
13436
|
+
this.startShowDelayTimer = () => {
|
|
13437
|
+
if (this.isAnchorHoveredFocused) {
|
|
13438
|
+
return;
|
|
13439
|
+
}
|
|
13440
|
+
if (this.delay > 1) {
|
|
13441
|
+
if (this.showDelayTimer === null)
|
|
13442
|
+
this.showDelayTimer = window.setTimeout(() => {
|
|
13443
|
+
this.startHover();
|
|
13444
|
+
}, this.delay);
|
|
13445
|
+
return;
|
|
13446
|
+
}
|
|
13447
|
+
this.startHover();
|
|
13448
|
+
};
|
|
13449
|
+
/**
|
|
13450
|
+
* start hover
|
|
13451
|
+
*/
|
|
13452
|
+
this.startHover = () => {
|
|
13453
|
+
this.isAnchorHoveredFocused = true;
|
|
13454
|
+
this.updateTooltipVisibility();
|
|
13455
|
+
};
|
|
13456
|
+
/**
|
|
13457
|
+
* clears the show delay
|
|
13458
|
+
*/
|
|
13459
|
+
this.clearShowDelayTimer = () => {
|
|
13460
|
+
if (this.showDelayTimer !== null) {
|
|
13461
|
+
clearTimeout(this.showDelayTimer);
|
|
13462
|
+
this.showDelayTimer = null;
|
|
13463
|
+
}
|
|
13464
|
+
};
|
|
13465
|
+
/**
|
|
13466
|
+
* Gets the anchor element by id
|
|
13467
|
+
*/
|
|
13468
|
+
this.getAnchor = () => {
|
|
13469
|
+
const rootNode = this.getRootNode();
|
|
13470
|
+
if (rootNode instanceof ShadowRoot) {
|
|
13471
|
+
return rootNode.getElementById(this.anchor);
|
|
13472
|
+
}
|
|
13473
|
+
return document.getElementById(this.anchor);
|
|
13474
|
+
};
|
|
13475
|
+
/**
|
|
13476
|
+
* handles key down events to check for dismiss
|
|
13477
|
+
*/
|
|
13478
|
+
this.handleDocumentKeydown = (e) => {
|
|
13479
|
+
if (!e.defaultPrevented && this.tooltipVisible) {
|
|
13480
|
+
switch (e.key) {
|
|
13481
|
+
case keyEscape:
|
|
13482
|
+
this.isAnchorHoveredFocused = false;
|
|
13483
|
+
this.updateTooltipVisibility();
|
|
13484
|
+
this.$emit("dismiss");
|
|
13485
|
+
break;
|
|
13486
|
+
}
|
|
13487
|
+
}
|
|
13488
|
+
};
|
|
13489
|
+
/**
|
|
13490
|
+
* determines whether to show or hide the tooltip based on current state
|
|
13491
|
+
*/
|
|
13492
|
+
this.updateTooltipVisibility = () => {
|
|
13493
|
+
if (this.visible === false) {
|
|
13494
|
+
this.hideTooltip();
|
|
13495
|
+
}
|
|
13496
|
+
else if (this.visible === true) {
|
|
13497
|
+
this.showTooltip();
|
|
13498
|
+
return;
|
|
13499
|
+
}
|
|
13500
|
+
else {
|
|
13501
|
+
if (this.isAnchorHoveredFocused || this.isRegionHovered) {
|
|
13502
|
+
this.showTooltip();
|
|
13503
|
+
return;
|
|
13504
|
+
}
|
|
13505
|
+
this.hideTooltip();
|
|
13506
|
+
}
|
|
13507
|
+
};
|
|
13508
|
+
/**
|
|
13509
|
+
* shows the tooltip
|
|
13510
|
+
*/
|
|
13511
|
+
this.showTooltip = () => {
|
|
13512
|
+
if (this.tooltipVisible) {
|
|
13513
|
+
return;
|
|
13514
|
+
}
|
|
13515
|
+
this.currentDirection = getDirection(this);
|
|
13516
|
+
this.tooltipVisible = true;
|
|
13517
|
+
document.addEventListener("keydown", this.handleDocumentKeydown);
|
|
13518
|
+
DOM.queueUpdate(this.setRegionProps);
|
|
13519
|
+
};
|
|
13520
|
+
/**
|
|
13521
|
+
* hides the tooltip
|
|
13522
|
+
*/
|
|
13523
|
+
this.hideTooltip = () => {
|
|
13524
|
+
if (!this.tooltipVisible) {
|
|
13525
|
+
return;
|
|
13526
|
+
}
|
|
13527
|
+
this.clearHideDelayTimer();
|
|
13528
|
+
if (this.region !== null && this.region !== undefined) {
|
|
13529
|
+
this.region.removeEventListener("positionchange", this.handlePositionChange);
|
|
13530
|
+
this.region.viewportElement = null;
|
|
13531
|
+
this.region.anchorElement = null;
|
|
13532
|
+
this.region.removeEventListener("mouseover", this.handleRegionMouseOver);
|
|
13533
|
+
this.region.removeEventListener("mouseout", this.handleRegionMouseOut);
|
|
13534
|
+
}
|
|
13535
|
+
document.removeEventListener("keydown", this.handleDocumentKeydown);
|
|
13536
|
+
this.tooltipVisible = false;
|
|
13537
|
+
};
|
|
13538
|
+
/**
|
|
13539
|
+
* updates the tooltip anchored region props after it has been
|
|
13540
|
+
* added to the DOM
|
|
13541
|
+
*/
|
|
13542
|
+
this.setRegionProps = () => {
|
|
13543
|
+
if (!this.tooltipVisible) {
|
|
13544
|
+
return;
|
|
13545
|
+
}
|
|
13546
|
+
this.region.viewportElement = this.viewportElement;
|
|
13547
|
+
this.region.anchorElement = this.anchorElement;
|
|
13548
|
+
this.region.addEventListener("positionchange", this.handlePositionChange);
|
|
13549
|
+
this.region.addEventListener("mouseover", this.handleRegionMouseOver, {
|
|
13550
|
+
passive: true,
|
|
13551
|
+
});
|
|
13552
|
+
this.region.addEventListener("mouseout", this.handleRegionMouseOut, {
|
|
13553
|
+
passive: true,
|
|
13554
|
+
});
|
|
13555
|
+
};
|
|
13556
|
+
}
|
|
13557
|
+
visibleChanged() {
|
|
13558
|
+
if (this.$fastController.isConnected) {
|
|
13559
|
+
this.updateTooltipVisibility();
|
|
13560
|
+
this.updateLayout();
|
|
13561
|
+
}
|
|
13562
|
+
}
|
|
13563
|
+
anchorChanged() {
|
|
13564
|
+
if (this.$fastController.isConnected) {
|
|
13565
|
+
this.anchorElement = this.getAnchor();
|
|
13566
|
+
}
|
|
13567
|
+
}
|
|
13568
|
+
positionChanged() {
|
|
13569
|
+
if (this.$fastController.isConnected) {
|
|
13570
|
+
this.updateLayout();
|
|
13571
|
+
}
|
|
13572
|
+
}
|
|
13573
|
+
anchorElementChanged(oldValue) {
|
|
13574
|
+
if (this.$fastController.isConnected) {
|
|
13575
|
+
if (oldValue !== null && oldValue !== undefined) {
|
|
13576
|
+
oldValue.removeEventListener("mouseover", this.handleAnchorMouseOver);
|
|
13577
|
+
oldValue.removeEventListener("mouseout", this.handleAnchorMouseOut);
|
|
13578
|
+
oldValue.removeEventListener("focusin", this.handleAnchorFocusIn);
|
|
13579
|
+
oldValue.removeEventListener("focusout", this.handleAnchorFocusOut);
|
|
13580
|
+
}
|
|
13581
|
+
if (this.anchorElement !== null && this.anchorElement !== undefined) {
|
|
13582
|
+
this.anchorElement.addEventListener("mouseover", this.handleAnchorMouseOver, { passive: true });
|
|
13583
|
+
this.anchorElement.addEventListener("mouseout", this.handleAnchorMouseOut, { passive: true });
|
|
13584
|
+
this.anchorElement.addEventListener("focusin", this.handleAnchorFocusIn, {
|
|
13585
|
+
passive: true,
|
|
13586
|
+
});
|
|
13587
|
+
this.anchorElement.addEventListener("focusout", this.handleAnchorFocusOut, { passive: true });
|
|
13588
|
+
const anchorId = this.anchorElement.id;
|
|
13589
|
+
if (this.anchorElement.parentElement !== null) {
|
|
13590
|
+
this.anchorElement.parentElement
|
|
13591
|
+
.querySelectorAll(":hover")
|
|
13592
|
+
.forEach(element => {
|
|
13593
|
+
if (element.id === anchorId) {
|
|
13594
|
+
this.startShowDelayTimer();
|
|
13595
|
+
}
|
|
13596
|
+
});
|
|
13597
|
+
}
|
|
13598
|
+
}
|
|
13599
|
+
if (this.region !== null &&
|
|
13600
|
+
this.region !== undefined &&
|
|
13601
|
+
this.tooltipVisible) {
|
|
13602
|
+
this.region.anchorElement = this.anchorElement;
|
|
13603
|
+
}
|
|
13604
|
+
this.updateLayout();
|
|
13605
|
+
}
|
|
13606
|
+
}
|
|
13607
|
+
viewportElementChanged() {
|
|
13608
|
+
if (this.region !== null && this.region !== undefined) {
|
|
13609
|
+
this.region.viewportElement = this.viewportElement;
|
|
13610
|
+
}
|
|
13611
|
+
this.updateLayout();
|
|
13612
|
+
}
|
|
13613
|
+
connectedCallback() {
|
|
13614
|
+
super.connectedCallback();
|
|
13615
|
+
this.anchorElement = this.getAnchor();
|
|
13616
|
+
this.updateTooltipVisibility();
|
|
13617
|
+
}
|
|
13618
|
+
disconnectedCallback() {
|
|
13619
|
+
this.hideTooltip();
|
|
13620
|
+
this.clearShowDelayTimer();
|
|
13621
|
+
this.clearHideDelayTimer();
|
|
13622
|
+
super.disconnectedCallback();
|
|
13623
|
+
}
|
|
13624
|
+
/**
|
|
13625
|
+
* updated the properties being passed to the anchored region
|
|
13626
|
+
*/
|
|
13627
|
+
updateLayout() {
|
|
13628
|
+
this.verticalPositioningMode = "locktodefault";
|
|
13629
|
+
this.horizontalPositioningMode = "locktodefault";
|
|
13630
|
+
switch (this.position) {
|
|
13631
|
+
case TooltipPosition.top:
|
|
13632
|
+
case TooltipPosition.bottom:
|
|
13633
|
+
this.verticalDefaultPosition = this.position;
|
|
13634
|
+
this.horizontalDefaultPosition = "center";
|
|
13635
|
+
break;
|
|
13636
|
+
case TooltipPosition.right:
|
|
13637
|
+
case TooltipPosition.left:
|
|
13638
|
+
case TooltipPosition.start:
|
|
13639
|
+
case TooltipPosition.end:
|
|
13640
|
+
this.verticalDefaultPosition = "center";
|
|
13641
|
+
this.horizontalDefaultPosition = this.position;
|
|
13642
|
+
break;
|
|
13643
|
+
case TooltipPosition.topLeft:
|
|
13644
|
+
this.verticalDefaultPosition = "top";
|
|
13645
|
+
this.horizontalDefaultPosition = "left";
|
|
13646
|
+
break;
|
|
13647
|
+
case TooltipPosition.topRight:
|
|
13648
|
+
this.verticalDefaultPosition = "top";
|
|
13649
|
+
this.horizontalDefaultPosition = "right";
|
|
13650
|
+
break;
|
|
13651
|
+
case TooltipPosition.bottomLeft:
|
|
13652
|
+
this.verticalDefaultPosition = "bottom";
|
|
13653
|
+
this.horizontalDefaultPosition = "left";
|
|
13654
|
+
break;
|
|
13655
|
+
case TooltipPosition.bottomRight:
|
|
13656
|
+
this.verticalDefaultPosition = "bottom";
|
|
13657
|
+
this.horizontalDefaultPosition = "right";
|
|
13658
|
+
break;
|
|
13659
|
+
case TooltipPosition.topStart:
|
|
13660
|
+
this.verticalDefaultPosition = "top";
|
|
13661
|
+
this.horizontalDefaultPosition = "start";
|
|
13662
|
+
break;
|
|
13663
|
+
case TooltipPosition.topEnd:
|
|
13664
|
+
this.verticalDefaultPosition = "top";
|
|
13665
|
+
this.horizontalDefaultPosition = "end";
|
|
13666
|
+
break;
|
|
13667
|
+
case TooltipPosition.bottomStart:
|
|
13668
|
+
this.verticalDefaultPosition = "bottom";
|
|
13669
|
+
this.horizontalDefaultPosition = "start";
|
|
13670
|
+
break;
|
|
13671
|
+
case TooltipPosition.bottomEnd:
|
|
13672
|
+
this.verticalDefaultPosition = "bottom";
|
|
13673
|
+
this.horizontalDefaultPosition = "end";
|
|
13674
|
+
break;
|
|
13675
|
+
default:
|
|
13676
|
+
this.verticalPositioningMode = "dynamic";
|
|
13677
|
+
this.horizontalPositioningMode = "dynamic";
|
|
13678
|
+
this.verticalDefaultPosition = void 0;
|
|
13679
|
+
this.horizontalDefaultPosition = "center";
|
|
13680
|
+
break;
|
|
13681
|
+
}
|
|
13682
|
+
}
|
|
13683
|
+
}
|
|
13684
|
+
__decorate$1([
|
|
13685
|
+
attr({ mode: "boolean" })
|
|
13686
|
+
], Tooltip$1.prototype, "visible", void 0);
|
|
13687
|
+
__decorate$1([
|
|
13688
|
+
attr
|
|
13689
|
+
], Tooltip$1.prototype, "anchor", void 0);
|
|
13690
|
+
__decorate$1([
|
|
13691
|
+
attr
|
|
13692
|
+
], Tooltip$1.prototype, "delay", void 0);
|
|
13693
|
+
__decorate$1([
|
|
13694
|
+
attr
|
|
13695
|
+
], Tooltip$1.prototype, "position", void 0);
|
|
13696
|
+
__decorate$1([
|
|
13697
|
+
attr({ attribute: "auto-update-mode" })
|
|
13698
|
+
], Tooltip$1.prototype, "autoUpdateMode", void 0);
|
|
13699
|
+
__decorate$1([
|
|
13700
|
+
attr({ attribute: "horizontal-viewport-lock" })
|
|
13701
|
+
], Tooltip$1.prototype, "horizontalViewportLock", void 0);
|
|
13702
|
+
__decorate$1([
|
|
13703
|
+
attr({ attribute: "vertical-viewport-lock" })
|
|
13704
|
+
], Tooltip$1.prototype, "verticalViewportLock", void 0);
|
|
13705
|
+
__decorate$1([
|
|
13706
|
+
observable
|
|
13707
|
+
], Tooltip$1.prototype, "anchorElement", void 0);
|
|
13708
|
+
__decorate$1([
|
|
13709
|
+
observable
|
|
13710
|
+
], Tooltip$1.prototype, "viewportElement", void 0);
|
|
13711
|
+
__decorate$1([
|
|
13712
|
+
observable
|
|
13713
|
+
], Tooltip$1.prototype, "verticalPositioningMode", void 0);
|
|
13714
|
+
__decorate$1([
|
|
13715
|
+
observable
|
|
13716
|
+
], Tooltip$1.prototype, "horizontalPositioningMode", void 0);
|
|
13717
|
+
__decorate$1([
|
|
13718
|
+
observable
|
|
13719
|
+
], Tooltip$1.prototype, "horizontalInset", void 0);
|
|
13720
|
+
__decorate$1([
|
|
13721
|
+
observable
|
|
13722
|
+
], Tooltip$1.prototype, "verticalInset", void 0);
|
|
13723
|
+
__decorate$1([
|
|
13724
|
+
observable
|
|
13725
|
+
], Tooltip$1.prototype, "horizontalScaling", void 0);
|
|
13726
|
+
__decorate$1([
|
|
13727
|
+
observable
|
|
13728
|
+
], Tooltip$1.prototype, "verticalScaling", void 0);
|
|
13729
|
+
__decorate$1([
|
|
13730
|
+
observable
|
|
13731
|
+
], Tooltip$1.prototype, "verticalDefaultPosition", void 0);
|
|
13732
|
+
__decorate$1([
|
|
13733
|
+
observable
|
|
13734
|
+
], Tooltip$1.prototype, "horizontalDefaultPosition", void 0);
|
|
13735
|
+
__decorate$1([
|
|
13736
|
+
observable
|
|
13737
|
+
], Tooltip$1.prototype, "tooltipVisible", void 0);
|
|
13738
|
+
__decorate$1([
|
|
13739
|
+
observable
|
|
13740
|
+
], Tooltip$1.prototype, "currentDirection", void 0);
|
|
13741
|
+
|
|
13141
13742
|
/**
|
|
13142
13743
|
* The template for the {@link @microsoft/fast-foundation#(TreeItem:class)} component.
|
|
13143
13744
|
* @public
|
|
@@ -13692,7 +14293,7 @@
|
|
|
13692
14293
|
*/
|
|
13693
14294
|
const focusVisible$1 = canUseFocusVisible() ? "focus-visible" : "focus";
|
|
13694
14295
|
|
|
13695
|
-
const styles$
|
|
14296
|
+
const styles$t = css `
|
|
13696
14297
|
:host {
|
|
13697
14298
|
contain: layout;
|
|
13698
14299
|
display: block;
|
|
@@ -13716,7 +14317,7 @@
|
|
|
13716
14317
|
baseName: 'anchored-region',
|
|
13717
14318
|
baseClass: AnchoredRegion$1,
|
|
13718
14319
|
template: anchoredRegionTemplate,
|
|
13719
|
-
styles: styles$
|
|
14320
|
+
styles: styles$t
|
|
13720
14321
|
});
|
|
13721
14322
|
DesignSystem.getOrCreate()
|
|
13722
14323
|
.withPrefix('nimble')
|
|
@@ -13737,11 +14338,11 @@
|
|
|
13737
14338
|
const White = "#ffffff";
|
|
13738
14339
|
const Black88 = "#252526";
|
|
13739
14340
|
const Black85 = "#363738";
|
|
14341
|
+
const Black80 = "#505153";
|
|
13740
14342
|
const Black91 = "#161617";
|
|
13741
14343
|
const ForestGreen = "#074023";
|
|
13742
14344
|
const DigitalGreenLight = "#009b65";
|
|
13743
14345
|
const Warning100LightUi = "#ff4b00";
|
|
13744
|
-
const Black30 = "#d3d5d6";
|
|
13745
14346
|
const DigitalGreenDark = "#006b46";
|
|
13746
14347
|
const PowerGreen = "#32eb96";
|
|
13747
14348
|
const Title2Family = "Source Sans Pro";
|
|
@@ -13870,6 +14471,7 @@
|
|
|
13870
14471
|
const tokenNames = {
|
|
13871
14472
|
actionRgbPartialColor: 'action-rgb-partial-color',
|
|
13872
14473
|
applicationBackgroundColor: 'application-background-color',
|
|
14474
|
+
dividerBackgroundColor: 'divider-background-color',
|
|
13873
14475
|
headerBackgroundColor: 'header-background-color',
|
|
13874
14476
|
sectionBackgroundColor: 'section-background-color',
|
|
13875
14477
|
fillSelectedColor: 'fill-selected-color',
|
|
@@ -14017,6 +14619,7 @@
|
|
|
14017
14619
|
tooltipCaptionFontWeight: 'tooltip-caption-font-weight',
|
|
14018
14620
|
tooltipCaptionFontLineHeight: 'tooltip-caption-font-line-height',
|
|
14019
14621
|
tooltipCaptionFallbackFontFamily: 'tooltip-caption-fallback-font-family',
|
|
14622
|
+
tooltipBackgroundColor: 'tooltip-background-color',
|
|
14020
14623
|
errorTextFont: 'error-text-font',
|
|
14021
14624
|
errorTextFontColor: 'error-text-font-color',
|
|
14022
14625
|
errorTextDisabledFontColor: 'error-text-disabled-font-color',
|
|
@@ -14053,7 +14656,7 @@
|
|
|
14053
14656
|
|
|
14054
14657
|
const template$5 = html `<slot></slot>`;
|
|
14055
14658
|
|
|
14056
|
-
const styles$
|
|
14659
|
+
const styles$s = css `
|
|
14057
14660
|
:host {
|
|
14058
14661
|
display: contents;
|
|
14059
14662
|
}
|
|
@@ -14109,7 +14712,7 @@
|
|
|
14109
14712
|
], ThemeProvider.prototype, "theme", void 0);
|
|
14110
14713
|
const nimbleDesignSystemProvider = ThemeProvider.compose({
|
|
14111
14714
|
baseName: 'theme-provider',
|
|
14112
|
-
styles: styles$
|
|
14715
|
+
styles: styles$s,
|
|
14113
14716
|
template: template$5
|
|
14114
14717
|
});
|
|
14115
14718
|
DesignSystem.getOrCreate()
|
|
@@ -14132,7 +14735,8 @@
|
|
|
14132
14735
|
const actionRgbPartialColor = DesignToken.create(styleNameFromTokenName(tokenNames.actionRgbPartialColor)).withDefault((element) => hexToRgbPartial(getColorForTheme(element, Black91, Black15, White)));
|
|
14133
14736
|
const applicationBackgroundColor = DesignToken.create(styleNameFromTokenName(tokenNames.applicationBackgroundColor)).withDefault((element) => getColorForTheme(element, White, Black85, ForestGreen));
|
|
14134
14737
|
DesignToken.create(styleNameFromTokenName(tokenNames.headerBackgroundColor)).withDefault((element) => getColorForTheme(element, Black7, Black88, ForestGreen));
|
|
14135
|
-
DesignToken.create(styleNameFromTokenName(tokenNames.sectionBackgroundColor)).withDefault((element) => getColorForTheme(element,
|
|
14738
|
+
DesignToken.create(styleNameFromTokenName(tokenNames.sectionBackgroundColor)).withDefault((element) => getColorForTheme(element, Black15, Black80, ForestGreen));
|
|
14739
|
+
DesignToken.create(styleNameFromTokenName(tokenNames.dividerBackgroundColor)).withDefault((element) => getColorForTheme(element, Black15, Black80, ForestGreen));
|
|
14136
14740
|
const fillSelectedColor = DesignToken.create(styleNameFromTokenName(tokenNames.fillSelectedColor)).withDefault((element) => hexToRgbaCssColor(getFillSelectedColorForTheme(element), 0.2));
|
|
14137
14741
|
const fillSelectedRgbPartialColor = DesignToken.create(styleNameFromTokenName(tokenNames.fillSelectedRgbPartialColor)).withDefault((element) => hexToRgbPartial(getFillSelectedColorForTheme(element)));
|
|
14138
14742
|
const fillHoverSelectedColor = DesignToken.create(styleNameFromTokenName(tokenNames.fillHoverSelectedColor)).withDefault((element) => hexToRgbaCssColor(getFillSelectedColorForTheme(element), 0.15));
|
|
@@ -14148,6 +14752,7 @@
|
|
|
14148
14752
|
const iconColor = DesignToken.create(styleNameFromTokenName(tokenNames.iconColor)).withDefault((element) => getColorForTheme(element, Black91, Black15, White));
|
|
14149
14753
|
const popupBoxShadowColor = DesignToken.create(styleNameFromTokenName(tokenNames.popupBoxShadowColor)).withDefault((element) => hexToRgbaCssColor(getColorForTheme(element, Black75, Black85, Black85), 0.3));
|
|
14150
14754
|
const popupBorderColor = DesignToken.create(styleNameFromTokenName(tokenNames.popupBorderColor)).withDefault((element) => hexToRgbaCssColor(getColorForTheme(element, Black91, Black15, White), 0.3));
|
|
14755
|
+
const tooltipBackgroundColor = DesignToken.create(styleNameFromTokenName(tokenNames.tooltipBackgroundColor)).withDefault((element) => getColorForTheme(element, Black15, Black85, ForestGreen));
|
|
14151
14756
|
// Component Sizing Tokens
|
|
14152
14757
|
const controlHeight = DesignToken.create(styleNameFromTokenName(tokenNames.controlHeight)).withDefault('32px');
|
|
14153
14758
|
const smallPadding = DesignToken.create(styleNameFromTokenName(tokenNames.smallPadding)).withDefault('4px');
|
|
@@ -14171,7 +14776,7 @@
|
|
|
14171
14776
|
const [groupHeaderFont, groupHeaderFontColor, groupHeaderDisabledFontColor, groupHeaderFontFamily, groupHeaderFontWeight, groupHeaderFontSize, groupHeaderFontLineHeight, groupHeaderFallbackFontFamily] = createFontTokens(tokenNames.groupHeaderFont, (element) => getDefaultFontColorForTheme(element), (element) => hexToRgbaCssColor(getDefaultFontColorForTheme(element), 0.3), GroupLabel1Family, GroupLabel1Weight, GroupLabel1Size, GroupLabel1LineHeight, 'sans-serif');
|
|
14172
14777
|
const [controlLabelFont, controlLabelFontColor, controlLabelDisabledFontColor, controlLabelFontFamily, controlLabelFontWeight, controlLabelFontSize, controlLabelFontLineHeight, controlLabelFallbackFontFamily] = createFontTokens(tokenNames.controlLabelFont, (element) => hexToRgbaCssColor(getDefaultFontColorForTheme(element), 0.6), (element) => hexToRgbaCssColor(getDefaultFontColorForTheme(element), 0.3), ControlLabel1Family, ControlLabel1Weight, ControlLabel1Size, ControlLabel1LineHeight, 'sans-serif');
|
|
14173
14778
|
const [buttonLabelFont, buttonLabelFontColor, buttonLabelDisabledFontColor, buttonLabelFontFamily, buttonLabelFontWeight, buttonLabelFontSize, buttonLabelFontLineHeight, buttonLabelFallbackFontFamily] = createFontTokens(tokenNames.buttonLabelFont, (element) => getDefaultFontColorForTheme(element), (element) => hexToRgbaCssColor(getDefaultFontColorForTheme(element), 0.3), ButtonLabel1Family, ButtonLabel1Weight, ButtonLabel1Size, ButtonLabel1LineHeight, 'sans-serif');
|
|
14174
|
-
createFontTokens(tokenNames.tooltipCaptionFont, (element) => getDefaultFontColorForTheme(element), (element) => hexToRgbaCssColor(getDefaultFontColorForTheme(element), 0.3), TooltipCaptionFamily, TooltipCaptionWeight, TooltipCaptionSize, TooltipCaptionLineHeight, 'sans-serif');
|
|
14779
|
+
const [tooltipCaptionFont, tooltipCaptionFontColor, tooltipCaptionDisabledFontColor, tooltipCaptionFontFamily, tooltipCaptionFontWeight, tooltipCaptionFontSize, tooltipCaptionFontLineHeight, tooltipCaptionFallbackFontFamily] = createFontTokens(tokenNames.tooltipCaptionFont, (element) => getDefaultFontColorForTheme(element), (element) => hexToRgbaCssColor(getDefaultFontColorForTheme(element), 0.3), TooltipCaptionFamily, TooltipCaptionWeight, TooltipCaptionSize, TooltipCaptionLineHeight, 'sans-serif');
|
|
14175
14780
|
const [errorTextFont, errorTextFontColor, errorTextDisabledFontColor, errorTextFontFamily, errorTextFontWeight, errorTextFontSize, errorTextFontLineHeight, errorTextFallbackFontFamily] = createFontTokens(tokenNames.errorTextFont, (element) => getFailColorForTheme(element), (element) => hexToRgbaCssColor(getFailColorForTheme(element), 0.3), ErrorLightUiFamily, ErrorLightUiWeight, ErrorLightUiSize, TooltipCaptionLineHeight, 'sans-serif');
|
|
14176
14781
|
// Font Transform Tokens
|
|
14177
14782
|
const groupHeaderTextTransform = DesignToken.create(styleNameFromTokenName(tokenNames.groupHeaderTextTransform)).withDefault('uppercase');
|
|
@@ -14230,13 +14835,13 @@
|
|
|
14230
14835
|
}
|
|
14231
14836
|
}
|
|
14232
14837
|
function getWarningColorForTheme(element) {
|
|
14233
|
-
return getColorForTheme(element, Warning100LightUi, Warning100DarkUi,
|
|
14838
|
+
return getColorForTheme(element, Warning100LightUi, Warning100DarkUi, White);
|
|
14234
14839
|
}
|
|
14235
14840
|
function getFailColorForTheme(element) {
|
|
14236
|
-
return getColorForTheme(element, Fail100LightUi, Fail100DarkUi,
|
|
14841
|
+
return getColorForTheme(element, Fail100LightUi, Fail100DarkUi, White);
|
|
14237
14842
|
}
|
|
14238
14843
|
function getPassColorForTheme(element) {
|
|
14239
|
-
return getColorForTheme(element, Pass100LightUi, Pass100DarkUi,
|
|
14844
|
+
return getColorForTheme(element, Pass100LightUi, Pass100DarkUi, White);
|
|
14240
14845
|
}
|
|
14241
14846
|
function getDefaultLineColorForTheme(element) {
|
|
14242
14847
|
return getColorForTheme(element, Black91, Black15, White);
|
|
@@ -14358,7 +14963,7 @@
|
|
|
14358
14963
|
*/
|
|
14359
14964
|
const themeBehavior = (lightStyle, darkStyleOrAlias, colorStyleOrAlias) => new ThemeStyleSheetBehavior(lightStyle, darkStyleOrAlias, colorStyleOrAlias);
|
|
14360
14965
|
|
|
14361
|
-
const styles$
|
|
14966
|
+
const styles$r = css `
|
|
14362
14967
|
${display('inline-block')}
|
|
14363
14968
|
|
|
14364
14969
|
:host {
|
|
@@ -14421,7 +15026,7 @@
|
|
|
14421
15026
|
baseName: 'breadcrumb',
|
|
14422
15027
|
baseClass: Breadcrumb$1,
|
|
14423
15028
|
template: breadcrumbTemplate,
|
|
14424
|
-
styles: styles$
|
|
15029
|
+
styles: styles$r
|
|
14425
15030
|
});
|
|
14426
15031
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleBreadcrumb());
|
|
14427
15032
|
|
|
@@ -15007,7 +15612,7 @@
|
|
|
15007
15612
|
*/
|
|
15008
15613
|
const focusVisible = `:${focusVisible$1}`;
|
|
15009
15614
|
|
|
15010
|
-
const styles$
|
|
15615
|
+
const styles$q = css `
|
|
15011
15616
|
${display('inline-flex')}
|
|
15012
15617
|
|
|
15013
15618
|
:host {
|
|
@@ -15087,7 +15692,7 @@
|
|
|
15087
15692
|
baseName: 'breadcrumb-item',
|
|
15088
15693
|
baseClass: BreadcrumbItem$1,
|
|
15089
15694
|
template: breadcrumbItemTemplate,
|
|
15090
|
-
styles: styles$
|
|
15695
|
+
styles: styles$q,
|
|
15091
15696
|
separator: forwardSlash16X16.data
|
|
15092
15697
|
});
|
|
15093
15698
|
DesignSystem.getOrCreate()
|
|
@@ -15117,7 +15722,7 @@
|
|
|
15117
15722
|
block: 'block'
|
|
15118
15723
|
};
|
|
15119
15724
|
|
|
15120
|
-
const styles$
|
|
15725
|
+
const styles$p = css `
|
|
15121
15726
|
${display('inline-flex')}
|
|
15122
15727
|
|
|
15123
15728
|
:host {
|
|
@@ -15324,7 +15929,7 @@
|
|
|
15324
15929
|
`));
|
|
15325
15930
|
|
|
15326
15931
|
// prettier-ignore
|
|
15327
|
-
const styles$
|
|
15932
|
+
const styles$o = styles$p
|
|
15328
15933
|
.withBehaviors(appearanceBehavior(ButtonAppearance.outline, css `
|
|
15329
15934
|
:host(.primary) .control {
|
|
15330
15935
|
box-shadow: 0px 0px 0px ${borderWidth} rgba(${actionRgbPartialColor}, 0.3) inset;
|
|
@@ -15438,14 +16043,14 @@
|
|
|
15438
16043
|
baseName: 'button',
|
|
15439
16044
|
baseClass: Button$1,
|
|
15440
16045
|
template: buttonTemplate,
|
|
15441
|
-
styles: styles$
|
|
16046
|
+
styles: styles$o,
|
|
15442
16047
|
shadowOptions: {
|
|
15443
16048
|
delegatesFocus: true
|
|
15444
16049
|
}
|
|
15445
16050
|
});
|
|
15446
16051
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleButton());
|
|
15447
16052
|
|
|
15448
|
-
const styles$
|
|
16053
|
+
const styles$n = css `
|
|
15449
16054
|
${display('inline-flex')}
|
|
15450
16055
|
|
|
15451
16056
|
:host {
|
|
@@ -15563,7 +16168,7 @@
|
|
|
15563
16168
|
baseName: 'checkbox',
|
|
15564
16169
|
baseClass: Checkbox$1,
|
|
15565
16170
|
template: checkboxTemplate,
|
|
15566
|
-
styles: styles$
|
|
16171
|
+
styles: styles$n,
|
|
15567
16172
|
checkedIndicator: check16X16.data,
|
|
15568
16173
|
indeterminateIndicator: minus16X16.data
|
|
15569
16174
|
});
|
|
@@ -15581,7 +16186,7 @@
|
|
|
15581
16186
|
</template
|
|
15582
16187
|
`;
|
|
15583
16188
|
|
|
15584
|
-
const styles$
|
|
16189
|
+
const styles$m = css `
|
|
15585
16190
|
${display('inline-flex')}
|
|
15586
16191
|
|
|
15587
16192
|
:host {
|
|
@@ -15628,7 +16233,7 @@
|
|
|
15628
16233
|
const composedIcon = iconClass.compose({
|
|
15629
16234
|
baseName,
|
|
15630
16235
|
template: template$4,
|
|
15631
|
-
styles: styles$
|
|
16236
|
+
styles: styles$m,
|
|
15632
16237
|
baseClass: iconClass
|
|
15633
16238
|
});
|
|
15634
16239
|
DesignSystem.getOrCreate().withPrefix('nimble').register(composedIcon());
|
|
@@ -15656,7 +16261,7 @@
|
|
|
15656
16261
|
}
|
|
15657
16262
|
registerIcon('icon-arrow-expander-down', IconArrowExpanderDown);
|
|
15658
16263
|
|
|
15659
|
-
const styles$
|
|
16264
|
+
const styles$l = css `
|
|
15660
16265
|
${display('inline-flex')}
|
|
15661
16266
|
|
|
15662
16267
|
:host {
|
|
@@ -15845,7 +16450,7 @@
|
|
|
15845
16450
|
}
|
|
15846
16451
|
`;
|
|
15847
16452
|
|
|
15848
|
-
const styles$
|
|
16453
|
+
const styles$k = css `
|
|
15849
16454
|
.error-icon {
|
|
15850
16455
|
display: none;
|
|
15851
16456
|
}
|
|
@@ -15883,9 +16488,9 @@
|
|
|
15883
16488
|
}
|
|
15884
16489
|
`;
|
|
15885
16490
|
|
|
15886
|
-
const styles$
|
|
16491
|
+
const styles$j = css `
|
|
16492
|
+
${styles$l}
|
|
15887
16493
|
${styles$k}
|
|
15888
|
-
${styles$j}
|
|
15889
16494
|
|
|
15890
16495
|
:host {
|
|
15891
16496
|
--ni-private-hover-bottom-border-width: 2px;
|
|
@@ -16057,7 +16662,7 @@
|
|
|
16057
16662
|
baseName: 'combobox',
|
|
16058
16663
|
baseClass: Combobox$1,
|
|
16059
16664
|
template: comboboxTemplate,
|
|
16060
|
-
styles: styles$
|
|
16665
|
+
styles: styles$j,
|
|
16061
16666
|
shadowOptions: {
|
|
16062
16667
|
delegatesFocus: true
|
|
16063
16668
|
},
|
|
@@ -17182,7 +17787,7 @@
|
|
|
17182
17787
|
slideOutOptions
|
|
17183
17788
|
};
|
|
17184
17789
|
|
|
17185
|
-
const styles$
|
|
17790
|
+
const styles$i = css `
|
|
17186
17791
|
${display('block')}
|
|
17187
17792
|
|
|
17188
17793
|
:host {
|
|
@@ -17494,7 +18099,7 @@
|
|
|
17494
18099
|
const nimbleDrawer = Drawer.compose({
|
|
17495
18100
|
baseName: 'drawer',
|
|
17496
18101
|
template: dialogTemplate,
|
|
17497
|
-
styles: styles$
|
|
18102
|
+
styles: styles$i
|
|
17498
18103
|
});
|
|
17499
18104
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleDrawer());
|
|
17500
18105
|
|
|
@@ -19038,7 +19643,7 @@
|
|
|
19038
19643
|
}
|
|
19039
19644
|
registerIcon('icon-xmark-check', IconXmarkCheck);
|
|
19040
19645
|
|
|
19041
|
-
const styles$
|
|
19646
|
+
const styles$h = css `
|
|
19042
19647
|
${display('flex')}
|
|
19043
19648
|
|
|
19044
19649
|
:host {
|
|
@@ -19117,11 +19722,11 @@
|
|
|
19117
19722
|
baseName: 'list-option',
|
|
19118
19723
|
baseClass: ListboxOption,
|
|
19119
19724
|
template: listboxOptionTemplate,
|
|
19120
|
-
styles: styles$
|
|
19725
|
+
styles: styles$h
|
|
19121
19726
|
});
|
|
19122
19727
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleListOption());
|
|
19123
19728
|
|
|
19124
|
-
const styles$
|
|
19729
|
+
const styles$g = css `
|
|
19125
19730
|
${display('grid')}
|
|
19126
19731
|
|
|
19127
19732
|
:host {
|
|
@@ -19176,11 +19781,11 @@
|
|
|
19176
19781
|
baseName: 'menu',
|
|
19177
19782
|
baseClass: Menu$1,
|
|
19178
19783
|
template: menuTemplate,
|
|
19179
|
-
styles: styles$
|
|
19784
|
+
styles: styles$g
|
|
19180
19785
|
});
|
|
19181
19786
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleMenu());
|
|
19182
19787
|
|
|
19183
|
-
const styles$
|
|
19788
|
+
const styles$f = css `
|
|
19184
19789
|
${display('inline-block')}
|
|
19185
19790
|
|
|
19186
19791
|
:host {
|
|
@@ -19198,8 +19803,8 @@
|
|
|
19198
19803
|
}
|
|
19199
19804
|
`;
|
|
19200
19805
|
|
|
19201
|
-
const styles$
|
|
19202
|
-
${styles$
|
|
19806
|
+
const styles$e = css `
|
|
19807
|
+
${styles$p}
|
|
19203
19808
|
|
|
19204
19809
|
.control[aria-pressed='true'] {
|
|
19205
19810
|
background-color: ${fillSelectedColor};
|
|
@@ -19301,7 +19906,7 @@
|
|
|
19301
19906
|
const nimbleToggleButton = ToggleButton.compose({
|
|
19302
19907
|
baseName: 'toggle-button',
|
|
19303
19908
|
template: template$3,
|
|
19304
|
-
styles: styles$
|
|
19909
|
+
styles: styles$e,
|
|
19305
19910
|
shadowOptions: {
|
|
19306
19911
|
delegatesFocus: true
|
|
19307
19912
|
}
|
|
@@ -19518,14 +20123,14 @@
|
|
|
19518
20123
|
const nimbleMenuButton = MenuButton.compose({
|
|
19519
20124
|
baseName: 'menu-button',
|
|
19520
20125
|
template: template$2,
|
|
19521
|
-
styles: styles$
|
|
20126
|
+
styles: styles$f,
|
|
19522
20127
|
shadowOptions: {
|
|
19523
20128
|
delegatesFocus: true
|
|
19524
20129
|
}
|
|
19525
20130
|
});
|
|
19526
20131
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleMenuButton());
|
|
19527
20132
|
|
|
19528
|
-
const styles$
|
|
20133
|
+
const styles$d = css `
|
|
19529
20134
|
${display('grid')}
|
|
19530
20135
|
|
|
19531
20136
|
:host {
|
|
@@ -19623,7 +20228,7 @@
|
|
|
19623
20228
|
baseName: 'menu-item',
|
|
19624
20229
|
baseClass: MenuItem$1,
|
|
19625
20230
|
template: menuItemTemplate,
|
|
19626
|
-
styles: styles$
|
|
20231
|
+
styles: styles$d,
|
|
19627
20232
|
expandCollapseGlyph: arrowExpanderRight16X16.data
|
|
19628
20233
|
});
|
|
19629
20234
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleMenuItem());
|
|
@@ -19637,7 +20242,7 @@
|
|
|
19637
20242
|
block: 'block'
|
|
19638
20243
|
};
|
|
19639
20244
|
|
|
19640
|
-
const styles$
|
|
20245
|
+
const styles$c = css `
|
|
19641
20246
|
${display('inline-block')}
|
|
19642
20247
|
|
|
19643
20248
|
:host {
|
|
@@ -19834,7 +20439,7 @@
|
|
|
19834
20439
|
baseName: 'number-field',
|
|
19835
20440
|
baseClass: NumberField$1,
|
|
19836
20441
|
template: numberFieldTemplate,
|
|
19837
|
-
styles: styles$
|
|
20442
|
+
styles: styles$c,
|
|
19838
20443
|
shadowOptions: {
|
|
19839
20444
|
delegatesFocus: true
|
|
19840
20445
|
},
|
|
@@ -19863,8 +20468,8 @@
|
|
|
19863
20468
|
});
|
|
19864
20469
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleNumberField());
|
|
19865
20470
|
|
|
19866
|
-
const styles$
|
|
19867
|
-
${styles$
|
|
20471
|
+
const styles$b = css `
|
|
20472
|
+
${styles$l}
|
|
19868
20473
|
`;
|
|
19869
20474
|
|
|
19870
20475
|
/**
|
|
@@ -19902,12 +20507,12 @@
|
|
|
19902
20507
|
baseName: 'select',
|
|
19903
20508
|
baseClass: Select$1,
|
|
19904
20509
|
template: selectTemplate,
|
|
19905
|
-
styles: styles$
|
|
20510
|
+
styles: styles$b,
|
|
19906
20511
|
indicator: arrowExpanderDown16X16.data
|
|
19907
20512
|
});
|
|
19908
20513
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleSelect());
|
|
19909
20514
|
|
|
19910
|
-
const styles$
|
|
20515
|
+
const styles$a = css `
|
|
19911
20516
|
${display('inline-flex')}
|
|
19912
20517
|
|
|
19913
20518
|
:host {
|
|
@@ -20120,11 +20725,11 @@
|
|
|
20120
20725
|
baseClass: Switch$1,
|
|
20121
20726
|
baseName: 'switch',
|
|
20122
20727
|
template: template$1,
|
|
20123
|
-
styles: styles$
|
|
20728
|
+
styles: styles$a
|
|
20124
20729
|
});
|
|
20125
20730
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleSwitch());
|
|
20126
20731
|
|
|
20127
|
-
const styles$
|
|
20732
|
+
const styles$9 = css `
|
|
20128
20733
|
${display('inline-flex')}
|
|
20129
20734
|
|
|
20130
20735
|
:host {
|
|
@@ -20228,11 +20833,11 @@
|
|
|
20228
20833
|
baseName: 'tab',
|
|
20229
20834
|
baseClass: Tab$1,
|
|
20230
20835
|
template: tabTemplate,
|
|
20231
|
-
styles: styles$
|
|
20836
|
+
styles: styles$9
|
|
20232
20837
|
});
|
|
20233
20838
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTab());
|
|
20234
20839
|
|
|
20235
|
-
const styles$
|
|
20840
|
+
const styles$8 = css `
|
|
20236
20841
|
${display('block')}
|
|
20237
20842
|
|
|
20238
20843
|
:host {
|
|
@@ -20252,11 +20857,11 @@
|
|
|
20252
20857
|
baseName: 'tab-panel',
|
|
20253
20858
|
baseClass: TabPanel$1,
|
|
20254
20859
|
template: tabPanelTemplate,
|
|
20255
|
-
styles: styles$
|
|
20860
|
+
styles: styles$8
|
|
20256
20861
|
});
|
|
20257
20862
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTabPanel());
|
|
20258
20863
|
|
|
20259
|
-
const styles$
|
|
20864
|
+
const styles$7 = css `
|
|
20260
20865
|
${display('grid')}
|
|
20261
20866
|
|
|
20262
20867
|
:host {
|
|
@@ -20294,11 +20899,11 @@
|
|
|
20294
20899
|
baseName: 'tabs',
|
|
20295
20900
|
baseClass: Tabs$1,
|
|
20296
20901
|
template: tabsTemplate,
|
|
20297
|
-
styles: styles$
|
|
20902
|
+
styles: styles$7
|
|
20298
20903
|
});
|
|
20299
20904
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTabs());
|
|
20300
20905
|
|
|
20301
|
-
const styles$
|
|
20906
|
+
const styles$6 = css `
|
|
20302
20907
|
${display('flex')}
|
|
20303
20908
|
|
|
20304
20909
|
:host {
|
|
@@ -20333,7 +20938,7 @@
|
|
|
20333
20938
|
const nimbleTabsToolbar = TabsToolbar.compose({
|
|
20334
20939
|
baseName: 'tabs-toolbar',
|
|
20335
20940
|
template,
|
|
20336
|
-
styles: styles$
|
|
20941
|
+
styles: styles$6
|
|
20337
20942
|
});
|
|
20338
20943
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTabsToolbar());
|
|
20339
20944
|
|
|
@@ -20342,7 +20947,7 @@
|
|
|
20342
20947
|
block: 'block'
|
|
20343
20948
|
};
|
|
20344
20949
|
|
|
20345
|
-
const styles$
|
|
20950
|
+
const styles$5 = css `
|
|
20346
20951
|
${display('inline-flex')}
|
|
20347
20952
|
|
|
20348
20953
|
:host {
|
|
@@ -20484,7 +21089,7 @@
|
|
|
20484
21089
|
baseName: 'text-area',
|
|
20485
21090
|
baseClass: TextArea$1,
|
|
20486
21091
|
template: textAreaTemplate,
|
|
20487
|
-
styles: styles$
|
|
21092
|
+
styles: styles$5,
|
|
20488
21093
|
shadowOptions: {
|
|
20489
21094
|
delegatesFocus: true
|
|
20490
21095
|
}
|
|
@@ -20501,9 +21106,9 @@
|
|
|
20501
21106
|
frameless: 'frameless'
|
|
20502
21107
|
};
|
|
20503
21108
|
|
|
20504
|
-
const styles$
|
|
21109
|
+
const styles$4 = css `
|
|
20505
21110
|
${display('inline-block')}
|
|
20506
|
-
${styles$
|
|
21111
|
+
${styles$k}
|
|
20507
21112
|
|
|
20508
21113
|
:host {
|
|
20509
21114
|
font: ${bodyFont};
|
|
@@ -20785,7 +21390,7 @@
|
|
|
20785
21390
|
baseName: 'text-field',
|
|
20786
21391
|
baseClass: TextField$1,
|
|
20787
21392
|
template: textFieldTemplate,
|
|
20788
|
-
styles: styles$
|
|
21393
|
+
styles: styles$4,
|
|
20789
21394
|
shadowOptions: {
|
|
20790
21395
|
delegatesFocus: true
|
|
20791
21396
|
},
|
|
@@ -20801,7 +21406,7 @@
|
|
|
20801
21406
|
});
|
|
20802
21407
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTextField());
|
|
20803
21408
|
|
|
20804
|
-
const styles$
|
|
21409
|
+
const styles$3 = css `
|
|
20805
21410
|
.positioning-region {
|
|
20806
21411
|
display: flex;
|
|
20807
21412
|
padding: ${smallPadding} ${standardPadding};
|
|
@@ -20836,13 +21441,50 @@
|
|
|
20836
21441
|
baseName: 'toolbar',
|
|
20837
21442
|
baseClass: Toolbar$1,
|
|
20838
21443
|
template: toolbarTemplate,
|
|
20839
|
-
styles: styles$
|
|
21444
|
+
styles: styles$3,
|
|
20840
21445
|
shadowOptions: {
|
|
20841
21446
|
delegatesFocus: true
|
|
20842
21447
|
}
|
|
20843
21448
|
});
|
|
20844
21449
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleToolbar());
|
|
20845
21450
|
|
|
21451
|
+
const styles$2 = css `
|
|
21452
|
+
${display('inline-flex')}
|
|
21453
|
+
|
|
21454
|
+
:host {
|
|
21455
|
+
font: ${tooltipCaptionFont};
|
|
21456
|
+
color: ${tooltipCaptionFontColor};
|
|
21457
|
+
text-align: left;
|
|
21458
|
+
}
|
|
21459
|
+
|
|
21460
|
+
.tooltip {
|
|
21461
|
+
box-sizing: border-box;
|
|
21462
|
+
flex-shrink: 0;
|
|
21463
|
+
max-width: 440px;
|
|
21464
|
+
border: ${borderWidth} solid rgba(${borderRgbPartialColor}, 0.3);
|
|
21465
|
+
box-shadow: 0px 3px 4px ${popupBoxShadowColor};
|
|
21466
|
+
background-color: ${tooltipBackgroundColor};
|
|
21467
|
+
padding-bottom: 6px;
|
|
21468
|
+
padding-left: calc(${standardPadding} / 2);
|
|
21469
|
+
padding-right: calc(${standardPadding} / 2);
|
|
21470
|
+
padding-top: ${smallPadding};
|
|
21471
|
+
display: inline-flex;
|
|
21472
|
+
}
|
|
21473
|
+
`;
|
|
21474
|
+
|
|
21475
|
+
/**
|
|
21476
|
+
* A nimble-styled tooltip control.
|
|
21477
|
+
*/
|
|
21478
|
+
class Tooltip extends Tooltip$1 {
|
|
21479
|
+
}
|
|
21480
|
+
const nimbleTooltip = Tooltip.compose({
|
|
21481
|
+
baseName: 'tooltip',
|
|
21482
|
+
baseClass: Tooltip$1,
|
|
21483
|
+
template: tooltipTemplate,
|
|
21484
|
+
styles: styles$2
|
|
21485
|
+
});
|
|
21486
|
+
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTooltip());
|
|
21487
|
+
|
|
20846
21488
|
const groupSelectedAttribute = 'group-selected';
|
|
20847
21489
|
const TreeViewSelectionMode = {
|
|
20848
21490
|
all: 'all',
|