@ni/spright-components 4.3.1 → 4.3.3
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.
|
@@ -11120,89 +11120,6 @@
|
|
|
11120
11120
|
</template>
|
|
11121
11121
|
`;
|
|
11122
11122
|
|
|
11123
|
-
/**
|
|
11124
|
-
* The template for the {@link @microsoft/fast-foundation#(NumberField:class)} component.
|
|
11125
|
-
* @public
|
|
11126
|
-
*/
|
|
11127
|
-
const numberFieldTemplate = (context, definition) => html `
|
|
11128
|
-
<template class="${x => (x.readOnly ? "readonly" : "")}">
|
|
11129
|
-
<label
|
|
11130
|
-
part="label"
|
|
11131
|
-
for="control"
|
|
11132
|
-
class="${x => x.defaultSlottedNodes && x.defaultSlottedNodes.length
|
|
11133
|
-
? "label"
|
|
11134
|
-
: "label label__hidden"}"
|
|
11135
|
-
>
|
|
11136
|
-
<slot ${slotted("defaultSlottedNodes")}></slot>
|
|
11137
|
-
</label>
|
|
11138
|
-
<div class="root" part="root">
|
|
11139
|
-
${startSlotTemplate(context, definition)}
|
|
11140
|
-
<input
|
|
11141
|
-
class="control"
|
|
11142
|
-
part="control"
|
|
11143
|
-
id="control"
|
|
11144
|
-
@input="${x => x.handleTextInput()}"
|
|
11145
|
-
@change="${x => x.handleChange()}"
|
|
11146
|
-
@keydown="${(x, c) => x.handleKeyDown(c.event)}"
|
|
11147
|
-
@blur="${(x, c) => x.handleBlur()}"
|
|
11148
|
-
?autofocus="${x => x.autofocus}"
|
|
11149
|
-
?disabled="${x => x.disabled}"
|
|
11150
|
-
list="${x => x.list}"
|
|
11151
|
-
maxlength="${x => x.maxlength}"
|
|
11152
|
-
minlength="${x => x.minlength}"
|
|
11153
|
-
placeholder="${x => x.placeholder}"
|
|
11154
|
-
?readonly="${x => x.readOnly}"
|
|
11155
|
-
?required="${x => x.required}"
|
|
11156
|
-
size="${x => x.size}"
|
|
11157
|
-
type="text"
|
|
11158
|
-
inputmode="numeric"
|
|
11159
|
-
min="${x => x.min}"
|
|
11160
|
-
max="${x => x.max}"
|
|
11161
|
-
step="${x => x.step}"
|
|
11162
|
-
aria-atomic="${x => x.ariaAtomic}"
|
|
11163
|
-
aria-busy="${x => x.ariaBusy}"
|
|
11164
|
-
aria-controls="${x => x.ariaControls}"
|
|
11165
|
-
aria-current="${x => x.ariaCurrent}"
|
|
11166
|
-
aria-describedby="${x => x.ariaDescribedby}"
|
|
11167
|
-
aria-details="${x => x.ariaDetails}"
|
|
11168
|
-
aria-disabled="${x => x.ariaDisabled}"
|
|
11169
|
-
aria-errormessage="${x => x.ariaErrormessage}"
|
|
11170
|
-
aria-flowto="${x => x.ariaFlowto}"
|
|
11171
|
-
aria-haspopup="${x => x.ariaHaspopup}"
|
|
11172
|
-
aria-hidden="${x => x.ariaHidden}"
|
|
11173
|
-
aria-invalid="${x => x.ariaInvalid}"
|
|
11174
|
-
aria-keyshortcuts="${x => x.ariaKeyshortcuts}"
|
|
11175
|
-
aria-label="${x => x.ariaLabel}"
|
|
11176
|
-
aria-labelledby="${x => x.ariaLabelledby}"
|
|
11177
|
-
aria-live="${x => x.ariaLive}"
|
|
11178
|
-
aria-owns="${x => x.ariaOwns}"
|
|
11179
|
-
aria-relevant="${x => x.ariaRelevant}"
|
|
11180
|
-
aria-roledescription="${x => x.ariaRoledescription}"
|
|
11181
|
-
${ref("control")}
|
|
11182
|
-
/>
|
|
11183
|
-
${when(x => !x.hideStep && !x.readOnly && !x.disabled, html `
|
|
11184
|
-
<div class="controls" part="controls">
|
|
11185
|
-
<div class="step-up" part="step-up" @click="${x => x.stepUp()}">
|
|
11186
|
-
<slot name="step-up-glyph">
|
|
11187
|
-
${definition.stepUpGlyph || ""}
|
|
11188
|
-
</slot>
|
|
11189
|
-
</div>
|
|
11190
|
-
<div
|
|
11191
|
-
class="step-down"
|
|
11192
|
-
part="step-down"
|
|
11193
|
-
@click="${x => x.stepDown()}"
|
|
11194
|
-
>
|
|
11195
|
-
<slot name="step-down-glyph">
|
|
11196
|
-
${definition.stepDownGlyph || ""}
|
|
11197
|
-
</slot>
|
|
11198
|
-
</div>
|
|
11199
|
-
</div>
|
|
11200
|
-
`)}
|
|
11201
|
-
${endSlotTemplate(context, definition)}
|
|
11202
|
-
</div>
|
|
11203
|
-
</template>
|
|
11204
|
-
`;
|
|
11205
|
-
|
|
11206
11123
|
class _TextField extends FoundationElement {
|
|
11207
11124
|
}
|
|
11208
11125
|
/**
|
|
@@ -13444,74 +13361,6 @@
|
|
|
13444
13361
|
], TextArea$1.prototype, "defaultSlottedNodes", void 0);
|
|
13445
13362
|
applyMixins(TextArea$1, DelegatesARIATextbox);
|
|
13446
13363
|
|
|
13447
|
-
/**
|
|
13448
|
-
* The template for the {@link @microsoft/fast-foundation#(TextField:class)} component.
|
|
13449
|
-
* @public
|
|
13450
|
-
*/
|
|
13451
|
-
const textFieldTemplate = (context, definition) => html `
|
|
13452
|
-
<template
|
|
13453
|
-
class="
|
|
13454
|
-
${x => (x.readOnly ? "readonly" : "")}
|
|
13455
|
-
"
|
|
13456
|
-
>
|
|
13457
|
-
<label
|
|
13458
|
-
part="label"
|
|
13459
|
-
for="control"
|
|
13460
|
-
class="${x => x.defaultSlottedNodes && x.defaultSlottedNodes.length
|
|
13461
|
-
? "label"
|
|
13462
|
-
: "label label__hidden"}"
|
|
13463
|
-
>
|
|
13464
|
-
<slot
|
|
13465
|
-
${slotted({ property: "defaultSlottedNodes", filter: whitespaceFilter })}
|
|
13466
|
-
></slot>
|
|
13467
|
-
</label>
|
|
13468
|
-
<div class="root" part="root">
|
|
13469
|
-
${startSlotTemplate(context, definition)}
|
|
13470
|
-
<input
|
|
13471
|
-
class="control"
|
|
13472
|
-
part="control"
|
|
13473
|
-
id="control"
|
|
13474
|
-
@input="${x => x.handleTextInput()}"
|
|
13475
|
-
@change="${x => x.handleChange()}"
|
|
13476
|
-
?autofocus="${x => x.autofocus}"
|
|
13477
|
-
?disabled="${x => x.disabled}"
|
|
13478
|
-
list="${x => x.list}"
|
|
13479
|
-
maxlength="${x => x.maxlength}"
|
|
13480
|
-
minlength="${x => x.minlength}"
|
|
13481
|
-
pattern="${x => x.pattern}"
|
|
13482
|
-
placeholder="${x => x.placeholder}"
|
|
13483
|
-
?readonly="${x => x.readOnly}"
|
|
13484
|
-
?required="${x => x.required}"
|
|
13485
|
-
size="${x => x.size}"
|
|
13486
|
-
?spellcheck="${x => x.spellcheck}"
|
|
13487
|
-
:value="${x => x.value}"
|
|
13488
|
-
type="${x => x.type}"
|
|
13489
|
-
aria-atomic="${x => x.ariaAtomic}"
|
|
13490
|
-
aria-busy="${x => x.ariaBusy}"
|
|
13491
|
-
aria-controls="${x => x.ariaControls}"
|
|
13492
|
-
aria-current="${x => x.ariaCurrent}"
|
|
13493
|
-
aria-describedby="${x => x.ariaDescribedby}"
|
|
13494
|
-
aria-details="${x => x.ariaDetails}"
|
|
13495
|
-
aria-disabled="${x => x.ariaDisabled}"
|
|
13496
|
-
aria-errormessage="${x => x.ariaErrormessage}"
|
|
13497
|
-
aria-flowto="${x => x.ariaFlowto}"
|
|
13498
|
-
aria-haspopup="${x => x.ariaHaspopup}"
|
|
13499
|
-
aria-hidden="${x => x.ariaHidden}"
|
|
13500
|
-
aria-invalid="${x => x.ariaInvalid}"
|
|
13501
|
-
aria-keyshortcuts="${x => x.ariaKeyshortcuts}"
|
|
13502
|
-
aria-label="${x => x.ariaLabel}"
|
|
13503
|
-
aria-labelledby="${x => x.ariaLabelledby}"
|
|
13504
|
-
aria-live="${x => x.ariaLive}"
|
|
13505
|
-
aria-owns="${x => x.ariaOwns}"
|
|
13506
|
-
aria-relevant="${x => x.ariaRelevant}"
|
|
13507
|
-
aria-roledescription="${x => x.ariaRoledescription}"
|
|
13508
|
-
${ref("control")}
|
|
13509
|
-
/>
|
|
13510
|
-
${endSlotTemplate(context, definition)}
|
|
13511
|
-
</div>
|
|
13512
|
-
</template>
|
|
13513
|
-
`;
|
|
13514
|
-
|
|
13515
13364
|
/**
|
|
13516
13365
|
* The template for the {@link @microsoft/fast-foundation#(Toolbar:class)} component.
|
|
13517
13366
|
*
|
|
@@ -16472,7 +16321,7 @@
|
|
|
16472
16321
|
return `${prefix}${uniqueIdCounter++}`;
|
|
16473
16322
|
}
|
|
16474
16323
|
|
|
16475
|
-
const template$
|
|
16324
|
+
const template$P = html `<slot></slot>`;
|
|
16476
16325
|
|
|
16477
16326
|
const styles$11 = css `
|
|
16478
16327
|
${display$1('contents')}
|
|
@@ -16590,7 +16439,7 @@
|
|
|
16590
16439
|
const nimbleDesignSystemProvider = ThemeProvider.compose({
|
|
16591
16440
|
baseName: 'theme-provider',
|
|
16592
16441
|
styles: styles$11,
|
|
16593
|
-
template: template$
|
|
16442
|
+
template: template$P
|
|
16594
16443
|
});
|
|
16595
16444
|
DesignSystem.getOrCreate()
|
|
16596
16445
|
.withPrefix('nimble')
|
|
@@ -16893,7 +16742,7 @@
|
|
|
16893
16742
|
`;
|
|
16894
16743
|
|
|
16895
16744
|
// prettier-ignore
|
|
16896
|
-
const template$
|
|
16745
|
+
const template$O = (_context, definition) => html `${
|
|
16897
16746
|
/* top-container div is necessary because setting contenteditable directly on the native anchor instead
|
|
16898
16747
|
leaves it focusable, unlike the behavior you get when the anchor is _within_ a contenteditable element.
|
|
16899
16748
|
*/ ''}<div
|
|
@@ -16996,7 +16845,7 @@
|
|
|
16996
16845
|
const nimbleAnchor = Anchor.compose({
|
|
16997
16846
|
baseName: 'anchor',
|
|
16998
16847
|
baseClass: Anchor$1,
|
|
16999
|
-
template: template$
|
|
16848
|
+
template: template$O,
|
|
17000
16849
|
styles: styles$10,
|
|
17001
16850
|
shadowOptions: {
|
|
17002
16851
|
delegatesFocus: true
|
|
@@ -17414,7 +17263,7 @@
|
|
|
17414
17263
|
}
|
|
17415
17264
|
`;
|
|
17416
17265
|
|
|
17417
|
-
const template$
|
|
17266
|
+
const template$N = (context, definition) => html `
|
|
17418
17267
|
<a
|
|
17419
17268
|
class="control"
|
|
17420
17269
|
part="control"
|
|
@@ -17496,7 +17345,7 @@
|
|
|
17496
17345
|
], AnchorButton.prototype, "disabled", void 0);
|
|
17497
17346
|
const nimbleAnchorButton = AnchorButton.compose({
|
|
17498
17347
|
baseName: 'anchor-button',
|
|
17499
|
-
template: template$
|
|
17348
|
+
template: template$N,
|
|
17500
17349
|
styles: styles$_,
|
|
17501
17350
|
shadowOptions: {
|
|
17502
17351
|
delegatesFocus: true
|
|
@@ -17588,7 +17437,7 @@
|
|
|
17588
17437
|
}
|
|
17589
17438
|
`;
|
|
17590
17439
|
|
|
17591
|
-
const template$
|
|
17440
|
+
const template$M = (context, definition) => html `
|
|
17592
17441
|
<template
|
|
17593
17442
|
role="menuitem"
|
|
17594
17443
|
class="${x => (typeof x.startColumnCount === 'number'
|
|
@@ -17689,7 +17538,7 @@
|
|
|
17689
17538
|
// FoundationAnchor already applies the StartEnd mixin, so we don't need to do it here.
|
|
17690
17539
|
const nimbleAnchorMenuItem = AnchorMenuItem.compose({
|
|
17691
17540
|
baseName: 'anchor-menu-item',
|
|
17692
|
-
template: template$
|
|
17541
|
+
template: template$M,
|
|
17693
17542
|
styles: styles$Z,
|
|
17694
17543
|
shadowOptions: {
|
|
17695
17544
|
delegatesFocus: true
|
|
@@ -17817,7 +17666,7 @@
|
|
|
17817
17666
|
}
|
|
17818
17667
|
`;
|
|
17819
17668
|
|
|
17820
|
-
const template$
|
|
17669
|
+
const template$L = (context, definition) => html `
|
|
17821
17670
|
<template slot="anchortab" role="tab" aria-disabled="${x => x.disabled}">
|
|
17822
17671
|
<a
|
|
17823
17672
|
download="${x => x.download}"
|
|
@@ -17869,7 +17718,7 @@
|
|
|
17869
17718
|
// FoundationAnchor already applies the StartEnd mixin, so we don't need to do it here.
|
|
17870
17719
|
const nimbleAnchorTab = AnchorTab.compose({
|
|
17871
17720
|
baseName: 'anchor-tab',
|
|
17872
|
-
template: template$
|
|
17721
|
+
template: template$L,
|
|
17873
17722
|
styles: styles$Y,
|
|
17874
17723
|
shadowOptions: {
|
|
17875
17724
|
delegatesFocus: true
|
|
@@ -17922,7 +17771,7 @@
|
|
|
17922
17771
|
${buttonAppearanceVariantStyles}
|
|
17923
17772
|
`;
|
|
17924
17773
|
|
|
17925
|
-
const template$
|
|
17774
|
+
const template$K = (context, definition) => html `
|
|
17926
17775
|
<button
|
|
17927
17776
|
class="control"
|
|
17928
17777
|
part="control"
|
|
@@ -18013,7 +17862,7 @@
|
|
|
18013
17862
|
const nimbleButton = Button.compose({
|
|
18014
17863
|
baseName: 'button',
|
|
18015
17864
|
baseClass: Button$1,
|
|
18016
|
-
template: template$
|
|
17865
|
+
template: template$K,
|
|
18017
17866
|
styles: styles$W,
|
|
18018
17867
|
shadowOptions: {
|
|
18019
17868
|
delegatesFocus: true
|
|
@@ -18853,7 +18702,7 @@
|
|
|
18853
18702
|
};
|
|
18854
18703
|
|
|
18855
18704
|
// Avoiding any whitespace in the template because this is an inline element
|
|
18856
|
-
const template$
|
|
18705
|
+
const template$J = html `<div
|
|
18857
18706
|
class="icon"
|
|
18858
18707
|
aria-hidden="true"
|
|
18859
18708
|
:innerHTML=${x => x.icon.data}
|
|
@@ -18921,7 +18770,7 @@
|
|
|
18921
18770
|
const registerIcon = (baseName, iconClass) => {
|
|
18922
18771
|
const composedIcon = iconClass.compose({
|
|
18923
18772
|
baseName,
|
|
18924
|
-
template: template$
|
|
18773
|
+
template: template$J,
|
|
18925
18774
|
styles: styles$V
|
|
18926
18775
|
});
|
|
18927
18776
|
DesignSystem.getOrCreate().withPrefix('nimble').register(composedIcon());
|
|
@@ -19013,7 +18862,7 @@
|
|
|
19013
18862
|
}).withDefault(coreLabelDefaults.scrollForwardLabel);
|
|
19014
18863
|
|
|
19015
18864
|
// prettier-ignore
|
|
19016
|
-
const template$
|
|
18865
|
+
const template$I = (context, definition) => html `
|
|
19017
18866
|
<div
|
|
19018
18867
|
class="tab-bar"
|
|
19019
18868
|
>
|
|
@@ -19312,7 +19161,7 @@
|
|
|
19312
19161
|
applyMixins(AnchorTabs, StartEnd);
|
|
19313
19162
|
const nimbleAnchorTabs = AnchorTabs.compose({
|
|
19314
19163
|
baseName: 'anchor-tabs',
|
|
19315
|
-
template: template$
|
|
19164
|
+
template: template$I,
|
|
19316
19165
|
styles: styles$X,
|
|
19317
19166
|
shadowOptions: {
|
|
19318
19167
|
delegatesFocus: false
|
|
@@ -19425,7 +19274,7 @@
|
|
|
19425
19274
|
}
|
|
19426
19275
|
`;
|
|
19427
19276
|
|
|
19428
|
-
const template$
|
|
19277
|
+
const template$H = (context, definition) => html `
|
|
19429
19278
|
<template
|
|
19430
19279
|
role="treeitem"
|
|
19431
19280
|
slot="${x => (x.isNestedItem() ? 'item' : null)}"
|
|
@@ -19562,7 +19411,7 @@
|
|
|
19562
19411
|
// FoundationAnchor already applies the StartEnd mixin, so we don't need to do it here.
|
|
19563
19412
|
const nimbleAnchorTreeItem = AnchorTreeItem.compose({
|
|
19564
19413
|
baseName: 'anchor-tree-item',
|
|
19565
|
-
template: template$
|
|
19414
|
+
template: template$H,
|
|
19566
19415
|
styles: styles$U,
|
|
19567
19416
|
shadowOptions: {
|
|
19568
19417
|
delegatesFocus: true
|
|
@@ -19870,7 +19719,7 @@
|
|
|
19870
19719
|
};
|
|
19871
19720
|
|
|
19872
19721
|
// prettier-ignore
|
|
19873
|
-
const template$
|
|
19722
|
+
const template$G = html `
|
|
19874
19723
|
<${themeProviderTag} theme="${Theme.color}">
|
|
19875
19724
|
<div class="container"
|
|
19876
19725
|
role="status"
|
|
@@ -19988,7 +19837,7 @@
|
|
|
19988
19837
|
applyMixins(Banner, ARIAGlobalStatesAndProperties);
|
|
19989
19838
|
const nimbleBanner = Banner.compose({
|
|
19990
19839
|
baseName: 'banner',
|
|
19991
|
-
template: template$
|
|
19840
|
+
template: template$G,
|
|
19992
19841
|
styles: styles$S
|
|
19993
19842
|
});
|
|
19994
19843
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleBanner());
|
|
@@ -20155,7 +20004,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
20155
20004
|
}
|
|
20156
20005
|
`;
|
|
20157
20006
|
|
|
20158
|
-
const template$
|
|
20007
|
+
const template$F = html `
|
|
20159
20008
|
<section aria-labelledby="title-slot">
|
|
20160
20009
|
<span id="title-slot"><slot name="title"></slot></span>
|
|
20161
20010
|
<slot></slot>
|
|
@@ -20170,7 +20019,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
20170
20019
|
const nimbleCard = Card.compose({
|
|
20171
20020
|
baseName: 'card',
|
|
20172
20021
|
baseClass: Card$1,
|
|
20173
|
-
template: template$
|
|
20022
|
+
template: template$F,
|
|
20174
20023
|
styles: styles$P
|
|
20175
20024
|
});
|
|
20176
20025
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleCard());
|
|
@@ -20570,7 +20419,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
20570
20419
|
</div>
|
|
20571
20420
|
`;
|
|
20572
20421
|
|
|
20573
|
-
const template$
|
|
20422
|
+
const template$E = (_context, definition) => html `
|
|
20574
20423
|
<template
|
|
20575
20424
|
role="checkbox"
|
|
20576
20425
|
aria-checked="${x => x.checked}"
|
|
@@ -20655,7 +20504,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
20655
20504
|
const nimbleCheckbox = Checkbox.compose({
|
|
20656
20505
|
baseName: 'checkbox',
|
|
20657
20506
|
baseClass: Checkbox$1,
|
|
20658
|
-
template: template$
|
|
20507
|
+
template: template$E,
|
|
20659
20508
|
styles: styles$M,
|
|
20660
20509
|
checkedIndicator: check16X16.data,
|
|
20661
20510
|
indeterminateIndicator: minus16X16.data
|
|
@@ -20713,7 +20562,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
20713
20562
|
|
|
20714
20563
|
/* eslint-disable @typescript-eslint/indent */
|
|
20715
20564
|
// prettier-ignore
|
|
20716
|
-
const template$
|
|
20565
|
+
const template$D = (context, definition) => html `
|
|
20717
20566
|
<div
|
|
20718
20567
|
role="button"
|
|
20719
20568
|
part="control"
|
|
@@ -20809,7 +20658,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
20809
20658
|
applyMixins(ToggleButton, StartEnd, DelegatesARIAButton);
|
|
20810
20659
|
const nimbleToggleButton = ToggleButton.compose({
|
|
20811
20660
|
baseName: 'toggle-button',
|
|
20812
|
-
template: template$
|
|
20661
|
+
template: template$D,
|
|
20813
20662
|
styles: styles$L,
|
|
20814
20663
|
shadowOptions: {
|
|
20815
20664
|
delegatesFocus: true
|
|
@@ -21205,7 +21054,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
21205
21054
|
|
|
21206
21055
|
/* eslint-disable @typescript-eslint/indent */
|
|
21207
21056
|
// prettier-ignore
|
|
21208
|
-
const template$
|
|
21057
|
+
const template$C = (context, definition) => html `
|
|
21209
21058
|
<template
|
|
21210
21059
|
aria-disabled="${x => x.ariaDisabled}"
|
|
21211
21060
|
autocomplete="${x => x.autocomplete}"
|
|
@@ -21953,7 +21802,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
21953
21802
|
const nimbleCombobox = Combobox.compose({
|
|
21954
21803
|
baseName: 'combobox',
|
|
21955
21804
|
baseClass: FormAssociatedCombobox,
|
|
21956
|
-
template: template$
|
|
21805
|
+
template: template$C,
|
|
21957
21806
|
styles: styles$J,
|
|
21958
21807
|
shadowOptions: {
|
|
21959
21808
|
delegatesFocus: true
|
|
@@ -22091,7 +21940,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
22091
21940
|
}
|
|
22092
21941
|
`;
|
|
22093
21942
|
|
|
22094
|
-
const template$
|
|
21943
|
+
const template$B = html `
|
|
22095
21944
|
<template>
|
|
22096
21945
|
<dialog
|
|
22097
21946
|
${ref('dialogElement')}
|
|
@@ -22239,7 +22088,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
22239
22088
|
applyMixins(Dialog, ARIAGlobalStatesAndProperties);
|
|
22240
22089
|
const nimbleDialog = Dialog.compose({
|
|
22241
22090
|
baseName: 'dialog',
|
|
22242
|
-
template: template$
|
|
22091
|
+
template: template$B,
|
|
22243
22092
|
styles: styles$I,
|
|
22244
22093
|
baseClass: Dialog
|
|
22245
22094
|
});
|
|
@@ -22388,7 +22237,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
22388
22237
|
}
|
|
22389
22238
|
`;
|
|
22390
22239
|
|
|
22391
|
-
const template$
|
|
22240
|
+
const template$A = html `
|
|
22392
22241
|
<dialog
|
|
22393
22242
|
${ref('dialog')}
|
|
22394
22243
|
aria-label="${x => x.ariaLabel}"
|
|
@@ -22531,7 +22380,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
22531
22380
|
applyMixins(Drawer, ARIAGlobalStatesAndProperties);
|
|
22532
22381
|
const nimbleDrawer = Drawer.compose({
|
|
22533
22382
|
baseName: 'drawer',
|
|
22534
|
-
template: template$
|
|
22383
|
+
template: template$A,
|
|
22535
22384
|
styles: styles$H
|
|
22536
22385
|
});
|
|
22537
22386
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleDrawer());
|
|
@@ -25312,7 +25161,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25312
25161
|
* @public
|
|
25313
25162
|
*/
|
|
25314
25163
|
// prettier-ignore
|
|
25315
|
-
const template$
|
|
25164
|
+
const template$z = (context, definition) => html `
|
|
25316
25165
|
<template
|
|
25317
25166
|
aria-checked="${x => x.ariaChecked}"
|
|
25318
25167
|
aria-disabled="${x => x.ariaDisabled}"
|
|
@@ -25425,7 +25274,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25425
25274
|
const nimbleListOption = ListOption.compose({
|
|
25426
25275
|
baseName: 'list-option',
|
|
25427
25276
|
baseClass: ListboxOption,
|
|
25428
|
-
template: template$
|
|
25277
|
+
template: template$z,
|
|
25429
25278
|
styles: styles$F
|
|
25430
25279
|
});
|
|
25431
25280
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleListOption());
|
|
@@ -25494,7 +25343,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25494
25343
|
return n instanceof ListOption;
|
|
25495
25344
|
};
|
|
25496
25345
|
// prettier-ignore
|
|
25497
|
-
const template$
|
|
25346
|
+
const template$y = html `
|
|
25498
25347
|
<template
|
|
25499
25348
|
role="group"
|
|
25500
25349
|
aria-label="${x => x.labelContent}"
|
|
@@ -25636,7 +25485,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25636
25485
|
const nimbleListOptionGroup = ListOptionGroup.compose({
|
|
25637
25486
|
baseName: 'list-option-group',
|
|
25638
25487
|
baseClass: FoundationElement,
|
|
25639
|
-
template: template$
|
|
25488
|
+
template: template$y,
|
|
25640
25489
|
styles: styles$E
|
|
25641
25490
|
});
|
|
25642
25491
|
DesignSystem.getOrCreate()
|
|
@@ -25652,7 +25501,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25652
25501
|
attr()
|
|
25653
25502
|
], Mapping$1.prototype, "key", void 0);
|
|
25654
25503
|
|
|
25655
|
-
const template$
|
|
25504
|
+
const template$x = html `<template slot="mapping"></template>`;
|
|
25656
25505
|
|
|
25657
25506
|
const styles$D = css `
|
|
25658
25507
|
${display$1('none')}
|
|
@@ -25670,7 +25519,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25670
25519
|
], MappingEmpty.prototype, "text", void 0);
|
|
25671
25520
|
const emptyMapping = MappingEmpty.compose({
|
|
25672
25521
|
baseName: 'mapping-empty',
|
|
25673
|
-
template: template$
|
|
25522
|
+
template: template$x,
|
|
25674
25523
|
styles: styles$D
|
|
25675
25524
|
});
|
|
25676
25525
|
DesignSystem.getOrCreate().withPrefix('nimble').register(emptyMapping());
|
|
@@ -25741,7 +25590,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25741
25590
|
], MappingIcon.prototype, "resolvedIcon", void 0);
|
|
25742
25591
|
const iconMapping = MappingIcon.compose({
|
|
25743
25592
|
baseName: 'mapping-icon',
|
|
25744
|
-
template: template$
|
|
25593
|
+
template: template$x,
|
|
25745
25594
|
styles: styles$D
|
|
25746
25595
|
});
|
|
25747
25596
|
DesignSystem.getOrCreate().withPrefix('nimble').register(iconMapping());
|
|
@@ -25765,7 +25614,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25765
25614
|
], MappingSpinner.prototype, "textHidden", void 0);
|
|
25766
25615
|
const spinnerMapping = MappingSpinner.compose({
|
|
25767
25616
|
baseName: 'mapping-spinner',
|
|
25768
|
-
template: template$
|
|
25617
|
+
template: template$x,
|
|
25769
25618
|
styles: styles$D
|
|
25770
25619
|
});
|
|
25771
25620
|
DesignSystem.getOrCreate().withPrefix('nimble').register(spinnerMapping());
|
|
@@ -25782,7 +25631,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
25782
25631
|
], MappingText.prototype, "text", void 0);
|
|
25783
25632
|
const textMapping = MappingText.compose({
|
|
25784
25633
|
baseName: 'mapping-text',
|
|
25785
|
-
template: template$
|
|
25634
|
+
template: template$x,
|
|
25786
25635
|
styles: styles$D
|
|
25787
25636
|
});
|
|
25788
25637
|
DesignSystem.getOrCreate().withPrefix('nimble').register(textMapping());
|
|
@@ -26088,7 +25937,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
26088
25937
|
|
|
26089
25938
|
/* eslint-disable @typescript-eslint/indent */
|
|
26090
25939
|
// prettier-ignore
|
|
26091
|
-
const template$
|
|
25940
|
+
const template$w = () => html `
|
|
26092
25941
|
<template
|
|
26093
25942
|
slot="${x => {
|
|
26094
25943
|
if (x.slot) {
|
|
@@ -26177,7 +26026,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
26177
26026
|
const nimbleMenu = Menu.compose({
|
|
26178
26027
|
baseName: 'menu',
|
|
26179
26028
|
baseClass: Menu$1,
|
|
26180
|
-
template: template$
|
|
26029
|
+
template: template$w,
|
|
26181
26030
|
styles: styles$C
|
|
26182
26031
|
});
|
|
26183
26032
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleMenu());
|
|
@@ -26214,7 +26063,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
26214
26063
|
`;
|
|
26215
26064
|
|
|
26216
26065
|
// prettier-ignore
|
|
26217
|
-
const template$
|
|
26066
|
+
const template$v = html `
|
|
26218
26067
|
<template
|
|
26219
26068
|
?open="${x => x.open}"
|
|
26220
26069
|
@focusout="${(x, c) => x.focusoutHandler(c.event)}"
|
|
@@ -26464,7 +26313,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
26464
26313
|
], MenuButton.prototype, "slottedMenus", void 0);
|
|
26465
26314
|
const nimbleMenuButton = MenuButton.compose({
|
|
26466
26315
|
baseName: 'menu-button',
|
|
26467
|
-
template: template$
|
|
26316
|
+
template: template$v,
|
|
26468
26317
|
styles: styles$B,
|
|
26469
26318
|
shadowOptions: {
|
|
26470
26319
|
delegatesFocus: true
|
|
@@ -26774,6 +26623,93 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
26774
26623
|
}
|
|
26775
26624
|
`));
|
|
26776
26625
|
|
|
26626
|
+
/**
|
|
26627
|
+
* The template for the {@link @microsoft/fast-foundation#(NumberField:class)} component.
|
|
26628
|
+
* @public
|
|
26629
|
+
*/
|
|
26630
|
+
const template$u = (context, definition) => html `
|
|
26631
|
+
<template class="${x => (x.readOnly ? 'readonly' : '')}">
|
|
26632
|
+
<label
|
|
26633
|
+
part="label"
|
|
26634
|
+
for="control"
|
|
26635
|
+
class="${x => (x.defaultSlottedNodes?.length
|
|
26636
|
+
? 'label'
|
|
26637
|
+
: 'label label__hidden')}"
|
|
26638
|
+
>
|
|
26639
|
+
<slot ${slotted('defaultSlottedNodes')}></slot>
|
|
26640
|
+
</label>
|
|
26641
|
+
<div class="root" part="root">
|
|
26642
|
+
${startSlotTemplate(context, definition)}
|
|
26643
|
+
<input
|
|
26644
|
+
class="control"
|
|
26645
|
+
part="control"
|
|
26646
|
+
id="control"
|
|
26647
|
+
@input="${x => x.handleTextInput()}"
|
|
26648
|
+
@change="${x => x.handleChange()}"
|
|
26649
|
+
@keydown="${(x, c) => x.handleKeyDown(c.event)}"
|
|
26650
|
+
@blur="${x => x.handleBlur()}"
|
|
26651
|
+
?autofocus="${x => x.autofocus}"
|
|
26652
|
+
?disabled="${x => x.disabled}"
|
|
26653
|
+
list="${x => x.list}"
|
|
26654
|
+
maxlength="${x => x.maxlength}"
|
|
26655
|
+
minlength="${x => x.minlength}"
|
|
26656
|
+
placeholder="${x => x.placeholder}"
|
|
26657
|
+
?readonly="${x => x.readOnly}"
|
|
26658
|
+
?required="${x => x.required}"
|
|
26659
|
+
size="${x => x.size}"
|
|
26660
|
+
type="text"
|
|
26661
|
+
inputmode="numeric"
|
|
26662
|
+
min="${x => x.min}"
|
|
26663
|
+
max="${x => x.max}"
|
|
26664
|
+
step="${x => x.step}"
|
|
26665
|
+
aria-atomic="${x => x.ariaAtomic}"
|
|
26666
|
+
aria-busy="${x => x.ariaBusy}"
|
|
26667
|
+
aria-controls="${x => x.ariaControls}"
|
|
26668
|
+
aria-current="${x => x.ariaCurrent}"
|
|
26669
|
+
aria-describedby="${x => x.ariaDescribedby}"
|
|
26670
|
+
aria-details="${x => x.ariaDetails}"
|
|
26671
|
+
aria-disabled="${x => x.ariaDisabled}"
|
|
26672
|
+
aria-errormessage="${x => x.ariaErrormessage}"
|
|
26673
|
+
aria-flowto="${x => x.ariaFlowto}"
|
|
26674
|
+
aria-haspopup="${x => x.ariaHaspopup}"
|
|
26675
|
+
aria-hidden="${x => x.ariaHidden}"
|
|
26676
|
+
aria-invalid="${x => x.ariaInvalid}"
|
|
26677
|
+
aria-keyshortcuts="${x => x.ariaKeyshortcuts}"
|
|
26678
|
+
aria-label="${x => x.ariaLabel}"
|
|
26679
|
+
aria-labelledby="${x => x.ariaLabelledby}"
|
|
26680
|
+
aria-live="${x => x.ariaLive}"
|
|
26681
|
+
aria-owns="${x => x.ariaOwns}"
|
|
26682
|
+
aria-relevant="${x => x.ariaRelevant}"
|
|
26683
|
+
aria-roledescription="${x => x.ariaRoledescription}"
|
|
26684
|
+
${ref('control')}
|
|
26685
|
+
/>
|
|
26686
|
+
${when(x => !x.hideStep && !x.readOnly && !x.disabled, html `
|
|
26687
|
+
<div class="controls" part="controls">
|
|
26688
|
+
<div
|
|
26689
|
+
class="step-up"
|
|
26690
|
+
part="step-up"
|
|
26691
|
+
@click="${x => x.stepUp()}"
|
|
26692
|
+
>
|
|
26693
|
+
<slot name="step-up-glyph">
|
|
26694
|
+
${definition.stepUpGlyph || ''}
|
|
26695
|
+
</slot>
|
|
26696
|
+
</div>
|
|
26697
|
+
<div
|
|
26698
|
+
class="step-down"
|
|
26699
|
+
part="step-down"
|
|
26700
|
+
@click="${x => x.stepDown()}"
|
|
26701
|
+
>
|
|
26702
|
+
<slot name="step-down-glyph">
|
|
26703
|
+
${definition.stepDownGlyph || ''}
|
|
26704
|
+
</slot>
|
|
26705
|
+
</div>
|
|
26706
|
+
</div>
|
|
26707
|
+
`)}
|
|
26708
|
+
${endSlotTemplate(context, definition)}
|
|
26709
|
+
</div>
|
|
26710
|
+
</template>
|
|
26711
|
+
`;
|
|
26712
|
+
|
|
26777
26713
|
/**
|
|
26778
26714
|
* A nimble-styled HTML number input
|
|
26779
26715
|
*/
|
|
@@ -26802,7 +26738,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
26802
26738
|
const nimbleNumberField = NumberField.compose({
|
|
26803
26739
|
baseName: 'number-field',
|
|
26804
26740
|
baseClass: NumberField$1,
|
|
26805
|
-
template:
|
|
26741
|
+
template: template$u,
|
|
26806
26742
|
styles: styles$z,
|
|
26807
26743
|
shadowOptions: {
|
|
26808
26744
|
delegatesFocus: true
|
|
@@ -26992,7 +26928,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
26992
26928
|
`;
|
|
26993
26929
|
|
|
26994
26930
|
/* eslint-disable @typescript-eslint/indent */
|
|
26995
|
-
const template$
|
|
26931
|
+
const template$t = html `
|
|
26996
26932
|
<template
|
|
26997
26933
|
role="radiogroup"
|
|
26998
26934
|
aria-disabled="${x => x.disabled}"
|
|
@@ -27031,7 +26967,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
27031
26967
|
const nimbleRadioGroup = RadioGroup.compose({
|
|
27032
26968
|
baseName: 'radio-group',
|
|
27033
26969
|
baseClass: RadioGroup$1,
|
|
27034
|
-
template: template$
|
|
26970
|
+
template: template$t,
|
|
27035
26971
|
styles: styles$x,
|
|
27036
26972
|
shadowOptions: {
|
|
27037
26973
|
delegatesFocus: true
|
|
@@ -29953,6 +29889,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
29953
29889
|
this.options = options;
|
|
29954
29890
|
this.isOpen = isOpen;
|
|
29955
29891
|
this.open = 0;
|
|
29892
|
+
this.localPreserveWS = false;
|
|
29956
29893
|
let topNode = options.topNode, topContext;
|
|
29957
29894
|
let topOptions = wsOptionsFor(null, options.preserveWhitespace, 0) | (isOpen ? OPT_OPEN_LEFT : 0);
|
|
29958
29895
|
if (topNode)
|
|
@@ -29979,11 +29916,12 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
29979
29916
|
}
|
|
29980
29917
|
addTextNode(dom, marks) {
|
|
29981
29918
|
let value = dom.nodeValue;
|
|
29982
|
-
let top = this.top
|
|
29983
|
-
|
|
29919
|
+
let top = this.top, preserveWS = (top.options & OPT_PRESERVE_WS_FULL) ? "full"
|
|
29920
|
+
: this.localPreserveWS || (top.options & OPT_PRESERVE_WS) > 0;
|
|
29921
|
+
if (preserveWS === "full" ||
|
|
29984
29922
|
top.inlineContext(dom) ||
|
|
29985
29923
|
/[^ \t\r\n\u000c]/.test(value)) {
|
|
29986
|
-
if (!
|
|
29924
|
+
if (!preserveWS) {
|
|
29987
29925
|
value = value.replace(/[ \t\r\n\u000c]+/g, " ");
|
|
29988
29926
|
// If this starts with whitespace, and there is no node before it, or
|
|
29989
29927
|
// a hard break, or a text node that ends with whitespace, strip the
|
|
@@ -29997,7 +29935,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
29997
29935
|
value = value.slice(1);
|
|
29998
29936
|
}
|
|
29999
29937
|
}
|
|
30000
|
-
else if (
|
|
29938
|
+
else if (preserveWS !== "full") {
|
|
30001
29939
|
value = value.replace(/\r?\n|\r/g, " ");
|
|
30002
29940
|
}
|
|
30003
29941
|
else {
|
|
@@ -30014,12 +29952,15 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30014
29952
|
// Try to find a handler for the given tag and use that to parse. If
|
|
30015
29953
|
// none is found, the element's content nodes are added directly.
|
|
30016
29954
|
addElement(dom, marks, matchAfter) {
|
|
29955
|
+
let outerWS = this.localPreserveWS, top = this.top;
|
|
29956
|
+
if (dom.tagName == "PRE" || /pre/.test(dom.style && dom.style.whiteSpace))
|
|
29957
|
+
this.localPreserveWS = true;
|
|
30017
29958
|
let name = dom.nodeName.toLowerCase(), ruleID;
|
|
30018
29959
|
if (listTags.hasOwnProperty(name) && this.parser.normalizeLists)
|
|
30019
29960
|
normalizeList(dom);
|
|
30020
29961
|
let rule = (this.options.ruleFromNode && this.options.ruleFromNode(dom)) ||
|
|
30021
29962
|
(ruleID = this.parser.matchTag(dom, this, matchAfter));
|
|
30022
|
-
if (rule ? rule.ignore : ignoreTags.hasOwnProperty(name)) {
|
|
29963
|
+
out: if (rule ? rule.ignore : ignoreTags.hasOwnProperty(name)) {
|
|
30023
29964
|
this.findInside(dom);
|
|
30024
29965
|
this.ignoreFallback(dom, marks);
|
|
30025
29966
|
}
|
|
@@ -30028,7 +29969,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30028
29969
|
this.open = Math.max(0, this.open - 1);
|
|
30029
29970
|
else if (rule && rule.skip.nodeType)
|
|
30030
29971
|
dom = rule.skip;
|
|
30031
|
-
let sync,
|
|
29972
|
+
let sync, oldNeedsBlock = this.needsBlock;
|
|
30032
29973
|
if (blockTags.hasOwnProperty(name)) {
|
|
30033
29974
|
if (top.content.length && top.content[0].isInline && this.open) {
|
|
30034
29975
|
this.open--;
|
|
@@ -30040,7 +29981,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30040
29981
|
}
|
|
30041
29982
|
else if (!dom.firstChild) {
|
|
30042
29983
|
this.leafFallback(dom, marks);
|
|
30043
|
-
|
|
29984
|
+
break out;
|
|
30044
29985
|
}
|
|
30045
29986
|
let innerMarks = rule && rule.skip ? marks : this.readStyles(dom, marks);
|
|
30046
29987
|
if (innerMarks)
|
|
@@ -30054,6 +29995,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30054
29995
|
if (innerMarks)
|
|
30055
29996
|
this.addElementByRule(dom, rule, innerMarks, rule.consuming === false ? ruleID : undefined);
|
|
30056
29997
|
}
|
|
29998
|
+
this.localPreserveWS = outerWS;
|
|
30057
29999
|
}
|
|
30058
30000
|
// Called for leaf DOM nodes that would otherwise be ignored
|
|
30059
30001
|
leafFallback(dom, marks) {
|
|
@@ -30244,14 +30186,18 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
30244
30186
|
finish() {
|
|
30245
30187
|
this.open = 0;
|
|
30246
30188
|
this.closeExtra(this.isOpen);
|
|
30247
|
-
return this.nodes[0].finish(this.isOpen || this.options.topOpen);
|
|
30189
|
+
return this.nodes[0].finish(!!(this.isOpen || this.options.topOpen));
|
|
30248
30190
|
}
|
|
30249
30191
|
sync(to) {
|
|
30250
|
-
for (let i = this.open; i >= 0; i--)
|
|
30192
|
+
for (let i = this.open; i >= 0; i--) {
|
|
30251
30193
|
if (this.nodes[i] == to) {
|
|
30252
30194
|
this.open = i;
|
|
30253
30195
|
return true;
|
|
30254
30196
|
}
|
|
30197
|
+
else if (this.localPreserveWS) {
|
|
30198
|
+
this.nodes[i].options |= OPT_PRESERVE_WS;
|
|
30199
|
+
}
|
|
30200
|
+
}
|
|
30255
30201
|
return false;
|
|
30256
30202
|
}
|
|
30257
30203
|
get currentPos() {
|
|
@@ -34161,11 +34107,12 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
34161
34107
|
for (let cur = node, sawBlock = false;;) {
|
|
34162
34108
|
if (cur == view.dom)
|
|
34163
34109
|
break;
|
|
34164
|
-
let desc = view.docView.nearestDesc(cur, true);
|
|
34110
|
+
let desc = view.docView.nearestDesc(cur, true), rect;
|
|
34165
34111
|
if (!desc)
|
|
34166
34112
|
return null;
|
|
34167
|
-
if (desc.dom.nodeType == 1 && (desc.node.isBlock && desc.parent || !desc.contentDOM)
|
|
34168
|
-
|
|
34113
|
+
if (desc.dom.nodeType == 1 && (desc.node.isBlock && desc.parent || !desc.contentDOM) &&
|
|
34114
|
+
// Ignore elements with zero-size bounding rectangles
|
|
34115
|
+
((rect = desc.dom.getBoundingClientRect()).width || rect.height)) {
|
|
34169
34116
|
if (desc.node.isBlock && desc.parent) {
|
|
34170
34117
|
// Only apply the horizontal test to the innermost block. Vertical for any parent.
|
|
34171
34118
|
if (!sawBlock && rect.left > coords.left || rect.top > coords.top)
|
|
@@ -36807,7 +36754,7 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
36807
36754
|
this.lastIOSEnterFallbackTimeout = -1;
|
|
36808
36755
|
this.lastFocus = 0;
|
|
36809
36756
|
this.lastTouch = 0;
|
|
36810
|
-
this.
|
|
36757
|
+
this.lastChromeDelete = 0;
|
|
36811
36758
|
this.composing = false;
|
|
36812
36759
|
this.compositionNode = null;
|
|
36813
36760
|
this.composingTimeout = -1;
|
|
@@ -38784,11 +38731,11 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
38784
38731
|
view.domObserver.suppressSelectionUpdates(); // #820
|
|
38785
38732
|
return;
|
|
38786
38733
|
}
|
|
38787
|
-
// Chrome
|
|
38734
|
+
// Chrome will occasionally, during composition, delete the
|
|
38788
38735
|
// entire composition and then immediately insert it again. This is
|
|
38789
38736
|
// used to detect that situation.
|
|
38790
|
-
if (chrome &&
|
|
38791
|
-
view.input.
|
|
38737
|
+
if (chrome && change.endB == change.start)
|
|
38738
|
+
view.input.lastChromeDelete = Date.now();
|
|
38792
38739
|
// This tries to detect Android virtual keyboard
|
|
38793
38740
|
// enter-and-pick-suggestion action. That sometimes (see issue
|
|
38794
38741
|
// #1059) first fires a DOM mutation, before moving the selection to
|
|
@@ -38839,13 +38786,13 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
38839
38786
|
tr = view.state.tr.replace(chFrom, chTo, parse.doc.slice(change.start - parse.from, change.endB - parse.from));
|
|
38840
38787
|
if (parse.sel) {
|
|
38841
38788
|
let sel = resolveSelection(view, tr.doc, parse.sel);
|
|
38842
|
-
// Chrome
|
|
38789
|
+
// Chrome will sometimes, during composition, report the
|
|
38843
38790
|
// selection in the wrong place. If it looks like that is
|
|
38844
38791
|
// happening, don't update the selection.
|
|
38845
38792
|
// Edge just doesn't move the cursor forward when you start typing
|
|
38846
38793
|
// in an empty block or between br nodes.
|
|
38847
|
-
if (sel && !(chrome &&
|
|
38848
|
-
(change.start != change.endB || view.input.
|
|
38794
|
+
if (sel && !(chrome && view.composing && sel.empty &&
|
|
38795
|
+
(change.start != change.endB || view.input.lastChromeDelete < Date.now() - 100) &&
|
|
38849
38796
|
(sel.head == chFrom || sel.head == tr.mapping.map(chTo) - 1) ||
|
|
38850
38797
|
ie$1 && sel.empty && sel.head == chFrom))
|
|
38851
38798
|
tr.setSelection(sel);
|
|
@@ -40341,28 +40288,44 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
40341
40288
|
function wrapInList$1(listType, attrs = null) {
|
|
40342
40289
|
return function (state, dispatch) {
|
|
40343
40290
|
let { $from, $to } = state.selection;
|
|
40344
|
-
let range = $from.blockRange($to)
|
|
40291
|
+
let range = $from.blockRange($to);
|
|
40345
40292
|
if (!range)
|
|
40346
40293
|
return false;
|
|
40347
|
-
|
|
40348
|
-
if (
|
|
40349
|
-
// Don't do anything if this is the top of the list
|
|
40350
|
-
if ($from.index(range.depth - 1) == 0)
|
|
40351
|
-
return false;
|
|
40352
|
-
let $insert = state.doc.resolve(range.start - 2);
|
|
40353
|
-
outerRange = new NodeRange($insert, $insert, range.depth);
|
|
40354
|
-
if (range.endIndex < range.parent.childCount)
|
|
40355
|
-
range = new NodeRange($from, state.doc.resolve($to.end(range.depth)), range.depth);
|
|
40356
|
-
doJoin = true;
|
|
40357
|
-
}
|
|
40358
|
-
let wrap = findWrapping(outerRange, listType, attrs, range);
|
|
40359
|
-
if (!wrap)
|
|
40294
|
+
let tr = dispatch ? state.tr : null;
|
|
40295
|
+
if (!wrapRangeInList(tr, range, listType, attrs))
|
|
40360
40296
|
return false;
|
|
40361
40297
|
if (dispatch)
|
|
40362
|
-
dispatch(
|
|
40298
|
+
dispatch(tr.scrollIntoView());
|
|
40363
40299
|
return true;
|
|
40364
40300
|
};
|
|
40365
40301
|
}
|
|
40302
|
+
/**
|
|
40303
|
+
Try to wrap the given node range in a list of the given type.
|
|
40304
|
+
Return `true` when this is possible, `false` otherwise. When `tr`
|
|
40305
|
+
is non-null, the wrapping is added to that transaction. When it is
|
|
40306
|
+
`null`, the function only queries whether the wrapping is
|
|
40307
|
+
possible.
|
|
40308
|
+
*/
|
|
40309
|
+
function wrapRangeInList(tr, range, listType, attrs = null) {
|
|
40310
|
+
let doJoin = false, outerRange = range, doc = range.$from.doc;
|
|
40311
|
+
// This is at the top of an existing list item
|
|
40312
|
+
if (range.depth >= 2 && range.$from.node(range.depth - 1).type.compatibleContent(listType) && range.startIndex == 0) {
|
|
40313
|
+
// Don't do anything if this is the top of the list
|
|
40314
|
+
if (range.$from.index(range.depth - 1) == 0)
|
|
40315
|
+
return false;
|
|
40316
|
+
let $insert = doc.resolve(range.start - 2);
|
|
40317
|
+
outerRange = new NodeRange($insert, $insert, range.depth);
|
|
40318
|
+
if (range.endIndex < range.parent.childCount)
|
|
40319
|
+
range = new NodeRange(range.$from, doc.resolve(range.$to.end(range.depth)), range.depth);
|
|
40320
|
+
doJoin = true;
|
|
40321
|
+
}
|
|
40322
|
+
let wrap = findWrapping(outerRange, listType, attrs, range);
|
|
40323
|
+
if (!wrap)
|
|
40324
|
+
return false;
|
|
40325
|
+
if (tr)
|
|
40326
|
+
doWrapInList(tr, range, wrap, doJoin, listType);
|
|
40327
|
+
return true;
|
|
40328
|
+
}
|
|
40366
40329
|
function doWrapInList(tr, range, wrappers, joinBefore, listType) {
|
|
40367
40330
|
let content = Fragment.empty;
|
|
40368
40331
|
for (let i = wrappers.length - 1; i >= 0; i--)
|
|
@@ -41460,6 +41423,8 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
41460
41423
|
const success = handlers.every(handler => handler !== null);
|
|
41461
41424
|
return success;
|
|
41462
41425
|
}
|
|
41426
|
+
// When dragging across editors, must get another editor instance to delete selection content.
|
|
41427
|
+
let tiptapDragFromOtherEditor = null;
|
|
41463
41428
|
const createClipboardPasteEvent = (text) => {
|
|
41464
41429
|
var _a;
|
|
41465
41430
|
const event = new ClipboardEvent('paste', {
|
|
@@ -41522,11 +41487,21 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
41522
41487
|
dragSourceElement = ((_a = view.dom.parentElement) === null || _a === void 0 ? void 0 : _a.contains(event.target))
|
|
41523
41488
|
? view.dom.parentElement
|
|
41524
41489
|
: null;
|
|
41490
|
+
if (dragSourceElement) {
|
|
41491
|
+
tiptapDragFromOtherEditor = editor;
|
|
41492
|
+
}
|
|
41493
|
+
};
|
|
41494
|
+
const handleDragend = () => {
|
|
41495
|
+
if (tiptapDragFromOtherEditor) {
|
|
41496
|
+
tiptapDragFromOtherEditor = null;
|
|
41497
|
+
}
|
|
41525
41498
|
};
|
|
41526
41499
|
window.addEventListener('dragstart', handleDragstart);
|
|
41500
|
+
window.addEventListener('dragend', handleDragend);
|
|
41527
41501
|
return {
|
|
41528
41502
|
destroy() {
|
|
41529
41503
|
window.removeEventListener('dragstart', handleDragstart);
|
|
41504
|
+
window.removeEventListener('dragend', handleDragend);
|
|
41530
41505
|
},
|
|
41531
41506
|
};
|
|
41532
41507
|
},
|
|
@@ -41535,6 +41510,18 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
41535
41510
|
drop: (view, event) => {
|
|
41536
41511
|
isDroppedFromProseMirror = dragSourceElement === view.dom.parentElement;
|
|
41537
41512
|
dropEvent = event;
|
|
41513
|
+
if (!isDroppedFromProseMirror) {
|
|
41514
|
+
const dragFromOtherEditor = tiptapDragFromOtherEditor;
|
|
41515
|
+
if (dragFromOtherEditor) {
|
|
41516
|
+
// setTimeout to avoid the wrong content after drop, timeout arg can't be empty or 0
|
|
41517
|
+
setTimeout(() => {
|
|
41518
|
+
const selection = dragFromOtherEditor.state.selection;
|
|
41519
|
+
if (selection) {
|
|
41520
|
+
dragFromOtherEditor.commands.deleteRange({ from: selection.from, to: selection.to });
|
|
41521
|
+
}
|
|
41522
|
+
}, 10);
|
|
41523
|
+
}
|
|
41524
|
+
}
|
|
41538
41525
|
return false;
|
|
41539
41526
|
},
|
|
41540
41527
|
paste: (_view, event) => {
|
|
@@ -42293,30 +42280,13 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
42293
42280
|
return TextSelection.create(doc, minMax(position, minPos, maxPos), minMax(position, minPos, maxPos));
|
|
42294
42281
|
}
|
|
42295
42282
|
|
|
42296
|
-
function isiOS() {
|
|
42297
|
-
return [
|
|
42298
|
-
'iPad Simulator',
|
|
42299
|
-
'iPhone Simulator',
|
|
42300
|
-
'iPod Simulator',
|
|
42301
|
-
'iPad',
|
|
42302
|
-
'iPhone',
|
|
42303
|
-
'iPod',
|
|
42304
|
-
].includes(navigator.platform)
|
|
42305
|
-
// iPad on iOS 13 detection
|
|
42306
|
-
|| (navigator.userAgent.includes('Mac') && 'ontouchend' in document);
|
|
42307
|
-
}
|
|
42308
|
-
|
|
42309
42283
|
const focus = (position = null, options = {}) => ({ editor, view, tr, dispatch, }) => {
|
|
42310
42284
|
options = {
|
|
42311
42285
|
scrollIntoView: true,
|
|
42312
42286
|
...options,
|
|
42313
42287
|
};
|
|
42314
42288
|
const delayedFocus = () => {
|
|
42315
|
-
|
|
42316
|
-
// so we have to call this
|
|
42317
|
-
if (isiOS()) {
|
|
42318
|
-
view.dom.focus();
|
|
42319
|
-
}
|
|
42289
|
+
view.dom.focus();
|
|
42320
42290
|
// For React we have to focus asynchronously. Otherwise wild things happen.
|
|
42321
42291
|
// see: https://github.com/ueberdosis/tiptap/issues/1520
|
|
42322
42292
|
requestAnimationFrame(() => {
|
|
@@ -42647,6 +42617,19 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
42647
42617
|
return joinTextblockForward$1(state, dispatch);
|
|
42648
42618
|
};
|
|
42649
42619
|
|
|
42620
|
+
function isiOS() {
|
|
42621
|
+
return [
|
|
42622
|
+
'iPad Simulator',
|
|
42623
|
+
'iPhone Simulator',
|
|
42624
|
+
'iPod Simulator',
|
|
42625
|
+
'iPad',
|
|
42626
|
+
'iPhone',
|
|
42627
|
+
'iPod',
|
|
42628
|
+
].includes(navigator.platform)
|
|
42629
|
+
// iPad on iOS 13 detection
|
|
42630
|
+
|| (navigator.userAgent.includes('Mac') && 'ontouchend' in document);
|
|
42631
|
+
}
|
|
42632
|
+
|
|
42650
42633
|
function isMacOS() {
|
|
42651
42634
|
return typeof navigator !== 'undefined'
|
|
42652
42635
|
? /Mac/.test(navigator.platform)
|
|
@@ -42857,11 +42840,12 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
42857
42840
|
return true;
|
|
42858
42841
|
};
|
|
42859
42842
|
|
|
42860
|
-
const selectAll = () => ({ tr,
|
|
42861
|
-
|
|
42862
|
-
|
|
42863
|
-
|
|
42864
|
-
}
|
|
42843
|
+
const selectAll = () => ({ tr, dispatch }) => {
|
|
42844
|
+
if (dispatch) {
|
|
42845
|
+
const selection = new AllSelection(tr.doc);
|
|
42846
|
+
tr.setSelection(selection);
|
|
42847
|
+
}
|
|
42848
|
+
return true;
|
|
42865
42849
|
};
|
|
42866
42850
|
|
|
42867
42851
|
const selectNodeBackward = () => ({ state, dispatch }) => {
|
|
@@ -45351,7 +45335,7 @@ img.ProseMirror-separator {
|
|
|
45351
45335
|
|
|
45352
45336
|
/* eslint-disable @typescript-eslint/indent */
|
|
45353
45337
|
// prettier-ignore
|
|
45354
|
-
const template$
|
|
45338
|
+
const template$s = html `
|
|
45355
45339
|
<template>
|
|
45356
45340
|
<${anchoredRegionTag}
|
|
45357
45341
|
${ref('region')}
|
|
@@ -45639,7 +45623,7 @@ img.ProseMirror-separator {
|
|
|
45639
45623
|
], RichTextMentionListbox.prototype, "anchorElement", void 0);
|
|
45640
45624
|
const nimbleRichTextMentionListbox = RichTextMentionListbox.compose({
|
|
45641
45625
|
baseName: 'rich-text-mention-listbox',
|
|
45642
|
-
template: template$
|
|
45626
|
+
template: template$s,
|
|
45643
45627
|
styles: styles$v
|
|
45644
45628
|
});
|
|
45645
45629
|
DesignSystem.getOrCreate()
|
|
@@ -45648,7 +45632,7 @@ img.ProseMirror-separator {
|
|
|
45648
45632
|
const richTextMentionListboxTag = 'nimble-rich-text-mention-listbox';
|
|
45649
45633
|
|
|
45650
45634
|
// prettier-ignore
|
|
45651
|
-
const template$
|
|
45635
|
+
const template$r = html `
|
|
45652
45636
|
<template
|
|
45653
45637
|
${children$1({ property: 'childItems', filter: elements() })}
|
|
45654
45638
|
@focusout="${x => x.focusoutHandler()}"
|
|
@@ -56143,8 +56127,8 @@ img.ProseMirror-separator {
|
|
|
56143
56127
|
this.values = values;
|
|
56144
56128
|
}
|
|
56145
56129
|
|
|
56146
|
-
|
|
56147
|
-
Leaf.prototype = Object.create( RopeSequence
|
|
56130
|
+
Leaf.__proto__ = RopeSequence;
|
|
56131
|
+
Leaf.prototype = Object.create( RopeSequence.prototype );
|
|
56148
56132
|
Leaf.prototype.constructor = Leaf;
|
|
56149
56133
|
|
|
56150
56134
|
var prototypeAccessors = { length: { configurable: true },depth: { configurable: true } };
|
|
@@ -56204,8 +56188,8 @@ img.ProseMirror-separator {
|
|
|
56204
56188
|
this.depth = Math.max(left.depth, right.depth) + 1;
|
|
56205
56189
|
}
|
|
56206
56190
|
|
|
56207
|
-
|
|
56208
|
-
Append.prototype = Object.create( RopeSequence
|
|
56191
|
+
Append.__proto__ = RopeSequence;
|
|
56192
|
+
Append.prototype = Object.create( RopeSequence.prototype );
|
|
56209
56193
|
Append.prototype.constructor = Append;
|
|
56210
56194
|
|
|
56211
56195
|
Append.prototype.flatten = function flatten () {
|
|
@@ -57165,6 +57149,8 @@ img.ProseMirror-separator {
|
|
|
57165
57149
|
// A valid web domain token
|
|
57166
57150
|
const WORD = 'WORD'; // only contains a-z
|
|
57167
57151
|
const UWORD = 'UWORD'; // contains letters other than a-z, used for IDN
|
|
57152
|
+
const ASCIINUMERICAL = 'ASCIINUMERICAL'; // contains a-z, 0-9
|
|
57153
|
+
const ALPHANUMERICAL = 'ALPHANUMERICAL'; // contains numbers and letters other than a-z, used for IDN
|
|
57168
57154
|
|
|
57169
57155
|
// Special case of word
|
|
57170
57156
|
const LOCALHOST = 'LOCALHOST';
|
|
@@ -57192,7 +57178,7 @@ img.ProseMirror-separator {
|
|
|
57192
57178
|
const WS = 'WS';
|
|
57193
57179
|
|
|
57194
57180
|
// New line (unix style)
|
|
57195
|
-
const NL
|
|
57181
|
+
const NL = 'NL'; // \n
|
|
57196
57182
|
|
|
57197
57183
|
// Opening/closing bracket classes
|
|
57198
57184
|
// TODO: Rename OPEN -> LEFT and CLOSE -> RIGHT in v5 to fit with Unicode names
|
|
@@ -57252,6 +57238,8 @@ img.ProseMirror-separator {
|
|
|
57252
57238
|
__proto__: null,
|
|
57253
57239
|
WORD: WORD,
|
|
57254
57240
|
UWORD: UWORD,
|
|
57241
|
+
ASCIINUMERICAL: ASCIINUMERICAL,
|
|
57242
|
+
ALPHANUMERICAL: ALPHANUMERICAL,
|
|
57255
57243
|
LOCALHOST: LOCALHOST,
|
|
57256
57244
|
TLD: TLD,
|
|
57257
57245
|
UTLD: UTLD,
|
|
@@ -57259,7 +57247,7 @@ img.ProseMirror-separator {
|
|
|
57259
57247
|
SLASH_SCHEME: SLASH_SCHEME,
|
|
57260
57248
|
NUM: NUM,
|
|
57261
57249
|
WS: WS,
|
|
57262
|
-
NL: NL
|
|
57250
|
+
NL: NL,
|
|
57263
57251
|
OPENBRACE: OPENBRACE,
|
|
57264
57252
|
CLOSEBRACE: CLOSEBRACE,
|
|
57265
57253
|
OPENBRACKET: OPENBRACKET,
|
|
@@ -57316,9 +57304,11 @@ img.ProseMirror-separator {
|
|
|
57316
57304
|
The scanner provides an interface that takes a string of text as input, and
|
|
57317
57305
|
outputs an array of tokens instances that can be used for easy URL parsing.
|
|
57318
57306
|
*/
|
|
57319
|
-
const
|
|
57307
|
+
const CR = '\r'; // carriage-return character
|
|
57308
|
+
const LF = '\n'; // line-feed character
|
|
57320
57309
|
const EMOJI_VARIATION = '\ufe0f'; // Variation selector, follows heart and others
|
|
57321
57310
|
const EMOJI_JOINER = '\u200d'; // zero-width joiner
|
|
57311
|
+
const OBJECT_REPLACEMENT = '\ufffc'; // whitespace placeholder that sometimes appears in rich text editors
|
|
57322
57312
|
|
|
57323
57313
|
let tlds = null,
|
|
57324
57314
|
utlds = null; // don't change so only have to be computed once
|
|
@@ -57404,49 +57394,73 @@ img.ProseMirror-separator {
|
|
|
57404
57394
|
[numeric]: true
|
|
57405
57395
|
});
|
|
57406
57396
|
tr(Num, DIGIT, Num);
|
|
57397
|
+
const Asciinumeric = tr(Num, ASCII_LETTER, ASCIINUMERICAL, {
|
|
57398
|
+
[asciinumeric]: true
|
|
57399
|
+
});
|
|
57400
|
+
const Alphanumeric = tr(Num, LETTER, ALPHANUMERICAL, {
|
|
57401
|
+
[alphanumeric$1]: true
|
|
57402
|
+
});
|
|
57407
57403
|
|
|
57408
57404
|
// State which emits a word token
|
|
57409
57405
|
const Word = tr(Start, ASCII_LETTER, WORD, {
|
|
57410
57406
|
[ascii]: true
|
|
57411
57407
|
});
|
|
57408
|
+
tr(Word, DIGIT, Asciinumeric);
|
|
57412
57409
|
tr(Word, ASCII_LETTER, Word);
|
|
57410
|
+
tr(Asciinumeric, DIGIT, Asciinumeric);
|
|
57411
|
+
tr(Asciinumeric, ASCII_LETTER, Asciinumeric);
|
|
57413
57412
|
|
|
57414
57413
|
// Same as previous, but specific to non-fsm.ascii alphabet words
|
|
57415
57414
|
const UWord = tr(Start, LETTER, UWORD, {
|
|
57416
57415
|
[alpha]: true
|
|
57417
57416
|
});
|
|
57418
57417
|
tr(UWord, ASCII_LETTER); // Non-accepting
|
|
57418
|
+
tr(UWord, DIGIT, Alphanumeric);
|
|
57419
57419
|
tr(UWord, LETTER, UWord);
|
|
57420
|
+
tr(Alphanumeric, DIGIT, Alphanumeric);
|
|
57421
|
+
tr(Alphanumeric, ASCII_LETTER); // Non-accepting
|
|
57422
|
+
tr(Alphanumeric, LETTER, Alphanumeric); // Non-accepting
|
|
57420
57423
|
|
|
57421
57424
|
// Whitespace jumps
|
|
57422
57425
|
// Tokens of only non-newline whitespace are arbitrarily long
|
|
57423
57426
|
// If any whitespace except newline, more whitespace!
|
|
57424
|
-
const
|
|
57427
|
+
const Nl = tt(Start, LF, NL, {
|
|
57428
|
+
[whitespace]: true
|
|
57429
|
+
});
|
|
57430
|
+
const Cr = tt(Start, CR, WS, {
|
|
57425
57431
|
[whitespace]: true
|
|
57426
57432
|
});
|
|
57427
|
-
|
|
57433
|
+
const Ws = tr(Start, SPACE, WS, {
|
|
57428
57434
|
[whitespace]: true
|
|
57429
57435
|
});
|
|
57430
|
-
tt(
|
|
57436
|
+
tt(Start, OBJECT_REPLACEMENT, Ws);
|
|
57437
|
+
tt(Cr, LF, Nl); // \r\n
|
|
57438
|
+
tt(Cr, OBJECT_REPLACEMENT, Ws);
|
|
57439
|
+
tr(Cr, SPACE, Ws);
|
|
57440
|
+
tt(Ws, CR); // non-accepting state to avoid mixing whitespaces
|
|
57441
|
+
tt(Ws, LF); // non-accepting state to avoid mixing whitespaces
|
|
57431
57442
|
tr(Ws, SPACE, Ws);
|
|
57443
|
+
tt(Ws, OBJECT_REPLACEMENT, Ws);
|
|
57432
57444
|
|
|
57433
57445
|
// Emoji tokens. They are not grouped by the scanner except in cases where a
|
|
57434
57446
|
// zero-width joiner is present
|
|
57435
57447
|
const Emoji = tr(Start, EMOJI, EMOJI$1, {
|
|
57436
57448
|
[emoji]: true
|
|
57437
57449
|
});
|
|
57450
|
+
tt(Emoji, '#'); // no transition, emoji regex seems to match #
|
|
57438
57451
|
tr(Emoji, EMOJI, Emoji);
|
|
57439
57452
|
tt(Emoji, EMOJI_VARIATION, Emoji);
|
|
57440
57453
|
// tt(Start, EMOJI_VARIATION, Emoji); // This one is sketchy
|
|
57441
57454
|
|
|
57442
57455
|
const EmojiJoiner = tt(Emoji, EMOJI_JOINER);
|
|
57456
|
+
tt(EmojiJoiner, '#');
|
|
57443
57457
|
tr(EmojiJoiner, EMOJI, Emoji);
|
|
57444
57458
|
// tt(EmojiJoiner, EMOJI_VARIATION, Emoji); // also sketchy
|
|
57445
57459
|
|
|
57446
57460
|
// Generates states for top-level domains
|
|
57447
57461
|
// Note that this is most accurate when tlds are in alphabetical order
|
|
57448
|
-
const wordjr = [[ASCII_LETTER, Word]];
|
|
57449
|
-
const uwordjr = [[ASCII_LETTER, null], [LETTER, UWord]];
|
|
57462
|
+
const wordjr = [[ASCII_LETTER, Word], [DIGIT, Asciinumeric]];
|
|
57463
|
+
const uwordjr = [[ASCII_LETTER, null], [LETTER, UWord], [DIGIT, Alphanumeric]];
|
|
57450
57464
|
for (let i = 0; i < tlds.length; i++) {
|
|
57451
57465
|
fastts(Start, tlds[i], TLD, WORD, wordjr);
|
|
57452
57466
|
}
|
|
@@ -58135,7 +58149,7 @@ img.ProseMirror-separator {
|
|
|
58135
58149
|
// Types of tokens that can follow a URL and be part of the query string
|
|
58136
58150
|
// but cannot be the very last characters
|
|
58137
58151
|
// Characters that cannot appear in the URL at all should be excluded
|
|
58138
|
-
const qsNonAccepting = [
|
|
58152
|
+
const qsNonAccepting = [COLON, COMMA, DOT, EXCLAMATION, PERCENT, QUERY, QUOTE, SEMI, OPENANGLEBRACKET, CLOSEANGLEBRACKET, OPENBRACE, CLOSEBRACE, CLOSEBRACKET, OPENBRACKET, OPENPAREN, CLOSEPAREN, FULLWIDTHLEFTPAREN, FULLWIDTHRIGHTPAREN, LEFTCORNERBRACKET, RIGHTCORNERBRACKET, LEFTWHITECORNERBRACKET, RIGHTWHITECORNERBRACKET, FULLWIDTHLESSTHAN, FULLWIDTHGREATERTHAN];
|
|
58139
58153
|
|
|
58140
58154
|
// For addresses without the mailto prefix
|
|
58141
58155
|
// Tokens allowed in the localpart of the email
|
|
@@ -58180,6 +58194,7 @@ img.ProseMirror-separator {
|
|
|
58180
58194
|
|
|
58181
58195
|
// Hyphen can jump back to a domain name
|
|
58182
58196
|
const EmailDomainHyphen = tt(EmailDomain, HYPHEN); // parsed string starts with local email info + @ with a potential domain name
|
|
58197
|
+
tt(EmailDomainHyphen, HYPHEN, EmailDomainHyphen);
|
|
58183
58198
|
ta(EmailDomainHyphen, groups.domain, EmailDomain);
|
|
58184
58199
|
ta(Email$1, groups.domain, EmailDomain);
|
|
58185
58200
|
tt(Email$1, DOT, EmailDomainDot);
|
|
@@ -58194,6 +58209,7 @@ img.ProseMirror-separator {
|
|
|
58194
58209
|
// (but not TLDs)
|
|
58195
58210
|
const DomainHyphen = tt(Domain, HYPHEN); // domain followed by hyphen
|
|
58196
58211
|
const DomainDot = tt(Domain, DOT); // domain followed by DOT
|
|
58212
|
+
tt(DomainHyphen, HYPHEN, DomainHyphen);
|
|
58197
58213
|
ta(DomainHyphen, groups.domain, Domain);
|
|
58198
58214
|
ta(DomainDot, localpartAccepting, Localpart);
|
|
58199
58215
|
ta(DomainDot, groups.domain, Domain);
|
|
@@ -58244,6 +58260,7 @@ img.ProseMirror-separator {
|
|
|
58244
58260
|
// Force URL with scheme prefix followed by anything sane
|
|
58245
58261
|
ta(SchemeColon, groups.domain, Url$1);
|
|
58246
58262
|
tt(SchemeColon, SLASH, Url$1);
|
|
58263
|
+
tt(SchemeColon, QUERY, Url$1);
|
|
58247
58264
|
ta(UriPrefix, groups.domain, Url$1);
|
|
58248
58265
|
ta(UriPrefix, qsAccepting, Url$1);
|
|
58249
58266
|
tt(UriPrefix, SLASH, Url$1);
|
|
@@ -58292,7 +58309,7 @@ img.ProseMirror-separator {
|
|
|
58292
58309
|
tt(UrlOpenSyms, CLOSE, Url$1);
|
|
58293
58310
|
}
|
|
58294
58311
|
tt(Start, LOCALHOST, DomainDotTld); // localhost is a valid URL state
|
|
58295
|
-
tt(Start, NL
|
|
58312
|
+
tt(Start, NL, Nl); // single new line
|
|
58296
58313
|
|
|
58297
58314
|
return {
|
|
58298
58315
|
start: Start,
|
|
@@ -58447,7 +58464,7 @@ img.ProseMirror-separator {
|
|
|
58447
58464
|
* Detect URLs with the following additional protocol. Anything with format
|
|
58448
58465
|
* "protocol://..." will be considered a link. If `optionalSlashSlash` is set to
|
|
58449
58466
|
* `true`, anything with format "protocol:..." will be considered a link.
|
|
58450
|
-
* @param {string}
|
|
58467
|
+
* @param {string} scheme
|
|
58451
58468
|
* @param {boolean} [optionalSlashSlash]
|
|
58452
58469
|
*/
|
|
58453
58470
|
function registerCustomProtocol(scheme, optionalSlashSlash = false) {
|
|
@@ -58841,9 +58858,25 @@ img.ProseMirror-separator {
|
|
|
58841
58858
|
addCommands() {
|
|
58842
58859
|
return {
|
|
58843
58860
|
setLink: attributes => ({ chain }) => {
|
|
58861
|
+
const { href } = attributes;
|
|
58862
|
+
if (!this.options.isAllowedUri(href, {
|
|
58863
|
+
defaultValidate: url => !!isAllowedUri(url, this.options.protocols),
|
|
58864
|
+
protocols: this.options.protocols,
|
|
58865
|
+
defaultProtocol: this.options.defaultProtocol,
|
|
58866
|
+
})) {
|
|
58867
|
+
return false;
|
|
58868
|
+
}
|
|
58844
58869
|
return chain().setMark(this.name, attributes).setMeta('preventAutolink', true).run();
|
|
58845
58870
|
},
|
|
58846
58871
|
toggleLink: attributes => ({ chain }) => {
|
|
58872
|
+
const { href } = attributes;
|
|
58873
|
+
if (!this.options.isAllowedUri(href, {
|
|
58874
|
+
defaultValidate: url => !!isAllowedUri(url, this.options.protocols),
|
|
58875
|
+
protocols: this.options.protocols,
|
|
58876
|
+
defaultProtocol: this.options.defaultProtocol,
|
|
58877
|
+
})) {
|
|
58878
|
+
return false;
|
|
58879
|
+
}
|
|
58847
58880
|
return chain()
|
|
58848
58881
|
.toggleMark(this.name, attributes, { extendEmptyMarkRange: true })
|
|
58849
58882
|
.setMeta('preventAutolink', true)
|
|
@@ -58959,13 +58992,15 @@ img.ProseMirror-separator {
|
|
|
58959
58992
|
|
|
58960
58993
|
function findSuggestionMatch(config) {
|
|
58961
58994
|
var _a;
|
|
58962
|
-
const { char, allowSpaces, allowedPrefixes, startOfLine, $position, } = config;
|
|
58995
|
+
const { char, allowSpaces: allowSpacesOption, allowToIncludeChar, allowedPrefixes, startOfLine, $position, } = config;
|
|
58996
|
+
const allowSpaces = allowSpacesOption && !allowToIncludeChar;
|
|
58963
58997
|
const escapedChar = escapeForRegEx(char);
|
|
58964
58998
|
const suffix = new RegExp(`\\s${escapedChar}$`);
|
|
58965
58999
|
const prefix = startOfLine ? '^' : '';
|
|
59000
|
+
const finalEscapedChar = allowToIncludeChar ? '' : escapedChar;
|
|
58966
59001
|
const regexp = allowSpaces
|
|
58967
|
-
? new RegExp(`${prefix}${escapedChar}.*?(?=\\s${
|
|
58968
|
-
: new RegExp(`${prefix}(?:^)?${escapedChar}[^\\s${
|
|
59002
|
+
? new RegExp(`${prefix}${escapedChar}.*?(?=\\s${finalEscapedChar}|$)`, 'gm')
|
|
59003
|
+
: new RegExp(`${prefix}(?:^)?${escapedChar}[^\\s${finalEscapedChar}]*`, 'gm');
|
|
58969
59004
|
const text = ((_a = $position.nodeBefore) === null || _a === void 0 ? void 0 : _a.isText) && $position.nodeBefore.text;
|
|
58970
59005
|
if (!text) {
|
|
58971
59006
|
return null;
|
|
@@ -59010,7 +59045,7 @@ img.ProseMirror-separator {
|
|
|
59010
59045
|
* This utility allows you to create suggestions.
|
|
59011
59046
|
* @see https://tiptap.dev/api/utilities/suggestion
|
|
59012
59047
|
*/
|
|
59013
|
-
function Suggestion({ pluginKey = SuggestionPluginKey, editor, char = '@', allowSpaces = false, allowedPrefixes = [' '], startOfLine = false, decorationTag = 'span', decorationClass = 'suggestion', command = () => null, items = () => [], render = () => ({}), allow = () => true, findSuggestionMatch: findSuggestionMatch$1 = findSuggestionMatch, }) {
|
|
59048
|
+
function Suggestion({ pluginKey = SuggestionPluginKey, editor, char = '@', allowSpaces = false, allowToIncludeChar = false, allowedPrefixes = [' '], startOfLine = false, decorationTag = 'span', decorationClass = 'suggestion', command = () => null, items = () => [], render = () => ({}), allow = () => true, findSuggestionMatch: findSuggestionMatch$1 = findSuggestionMatch, }) {
|
|
59014
59049
|
let props;
|
|
59015
59050
|
const renderer = render === null || render === void 0 ? void 0 : render();
|
|
59016
59051
|
const plugin = new Plugin({
|
|
@@ -59127,6 +59162,7 @@ img.ProseMirror-separator {
|
|
|
59127
59162
|
const match = findSuggestionMatch$1({
|
|
59128
59163
|
char,
|
|
59129
59164
|
allowSpaces,
|
|
59165
|
+
allowToIncludeChar,
|
|
59130
59166
|
allowedPrefixes,
|
|
59131
59167
|
startOfLine,
|
|
59132
59168
|
$position: selection.$from,
|
|
@@ -60392,7 +60428,7 @@ img.ProseMirror-separator {
|
|
|
60392
60428
|
applyMixins(RichTextEditor, ARIAGlobalStatesAndProperties);
|
|
60393
60429
|
const nimbleRichTextEditor = RichTextEditor.compose({
|
|
60394
60430
|
baseName: 'rich-text-editor',
|
|
60395
|
-
template: template$
|
|
60431
|
+
template: template$r,
|
|
60396
60432
|
styles: styles$u,
|
|
60397
60433
|
shadowOptions: {
|
|
60398
60434
|
delegatesFocus: true
|
|
@@ -60402,7 +60438,7 @@ img.ProseMirror-separator {
|
|
|
60402
60438
|
.withPrefix('nimble')
|
|
60403
60439
|
.register(nimbleRichTextEditor());
|
|
60404
60440
|
|
|
60405
|
-
const template$
|
|
60441
|
+
const template$q = html `
|
|
60406
60442
|
<template ${children$1({ property: 'childItems', filter: elements() })}>
|
|
60407
60443
|
<div ${ref('viewer')} class="viewer"></div>
|
|
60408
60444
|
</template>
|
|
@@ -60519,7 +60555,7 @@ img.ProseMirror-separator {
|
|
|
60519
60555
|
], RichTextViewer.prototype, "markdown", void 0);
|
|
60520
60556
|
const nimbleRichTextViewer = RichTextViewer.compose({
|
|
60521
60557
|
baseName: 'rich-text-viewer',
|
|
60522
|
-
template: template$
|
|
60558
|
+
template: template$q,
|
|
60523
60559
|
styles: styles$t
|
|
60524
60560
|
});
|
|
60525
60561
|
DesignSystem.getOrCreate()
|
|
@@ -60853,7 +60889,7 @@ img.ProseMirror-separator {
|
|
|
60853
60889
|
|
|
60854
60890
|
/* eslint-disable @typescript-eslint/indent */
|
|
60855
60891
|
// prettier-ignore
|
|
60856
|
-
const template$
|
|
60892
|
+
const template$p = html `
|
|
60857
60893
|
<template role="progressbar">
|
|
60858
60894
|
${''
|
|
60859
60895
|
/**
|
|
@@ -60901,7 +60937,7 @@ img.ProseMirror-separator {
|
|
|
60901
60937
|
], Spinner.prototype, "appearance", void 0);
|
|
60902
60938
|
const nimbleSpinner = Spinner.compose({
|
|
60903
60939
|
baseName: 'spinner',
|
|
60904
|
-
template: template$
|
|
60940
|
+
template: template$p,
|
|
60905
60941
|
styles: styles$r
|
|
60906
60942
|
});
|
|
60907
60943
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleSpinner());
|
|
@@ -60915,7 +60951,7 @@ img.ProseMirror-separator {
|
|
|
60915
60951
|
};
|
|
60916
60952
|
/* eslint-disable @typescript-eslint/indent */
|
|
60917
60953
|
// prettier-ignore
|
|
60918
|
-
const template$
|
|
60954
|
+
const template$o = (context, definition) => html `
|
|
60919
60955
|
<template
|
|
60920
60956
|
class="${x => [
|
|
60921
60957
|
x.collapsible && 'collapsible',
|
|
@@ -62125,7 +62161,7 @@ img.ProseMirror-separator {
|
|
|
62125
62161
|
const nimbleSelect = Select.compose({
|
|
62126
62162
|
baseName: 'select',
|
|
62127
62163
|
baseClass: Select$2,
|
|
62128
|
-
template: template$
|
|
62164
|
+
template: template$o,
|
|
62129
62165
|
styles: styles$s,
|
|
62130
62166
|
indicator: arrowExpanderDown16X16.data,
|
|
62131
62167
|
end: html `
|
|
@@ -62302,7 +62338,7 @@ img.ProseMirror-separator {
|
|
|
62302
62338
|
`));
|
|
62303
62339
|
|
|
62304
62340
|
// prettier-ignore
|
|
62305
|
-
const template$
|
|
62341
|
+
const template$n = html `
|
|
62306
62342
|
<template
|
|
62307
62343
|
role="switch"
|
|
62308
62344
|
aria-checked="${x => x.checked}"
|
|
@@ -62346,7 +62382,7 @@ img.ProseMirror-separator {
|
|
|
62346
62382
|
const nimbleSwitch = Switch.compose({
|
|
62347
62383
|
baseClass: Switch$1,
|
|
62348
62384
|
baseName: 'switch',
|
|
62349
|
-
template: template$
|
|
62385
|
+
template: template$n,
|
|
62350
62386
|
styles: styles$q
|
|
62351
62387
|
});
|
|
62352
62388
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleSwitch());
|
|
@@ -66462,7 +66498,7 @@ focus outline in that case.
|
|
|
66462
66498
|
`;
|
|
66463
66499
|
|
|
66464
66500
|
// prettier-ignore
|
|
66465
|
-
const template$
|
|
66501
|
+
const template$m = html `
|
|
66466
66502
|
<template role="columnheader"
|
|
66467
66503
|
class="${x => (x.alignment === TableColumnAlignment.right ? 'right-align' : '')}"
|
|
66468
66504
|
aria-sort="${x => x.ariaSort}"
|
|
@@ -66548,7 +66584,7 @@ focus outline in that case.
|
|
|
66548
66584
|
], TableHeader.prototype, "isGrouped", void 0);
|
|
66549
66585
|
const nimbleTableHeader = TableHeader.compose({
|
|
66550
66586
|
baseName: 'table-header',
|
|
66551
|
-
template: template$
|
|
66587
|
+
template: template$m,
|
|
66552
66588
|
styles: styles$m
|
|
66553
66589
|
});
|
|
66554
66590
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTableHeader());
|
|
@@ -66797,7 +66833,7 @@ focus outline in that case.
|
|
|
66797
66833
|
`;
|
|
66798
66834
|
|
|
66799
66835
|
// prettier-ignore
|
|
66800
|
-
const template$
|
|
66836
|
+
const template$l = html `
|
|
66801
66837
|
<template role="cell" style="--ni-private-table-cell-nesting-level: ${x => x.nestingLevel}"
|
|
66802
66838
|
@focusin="${x => x.onCellFocusIn()}"
|
|
66803
66839
|
@blur="${x => x.onCellBlur()}"
|
|
@@ -66894,14 +66930,14 @@ focus outline in that case.
|
|
|
66894
66930
|
], TableCell.prototype, "nestingLevel", void 0);
|
|
66895
66931
|
const nimbleTableCell = TableCell.compose({
|
|
66896
66932
|
baseName: 'table-cell',
|
|
66897
|
-
template: template$
|
|
66933
|
+
template: template$l,
|
|
66898
66934
|
styles: styles$j
|
|
66899
66935
|
});
|
|
66900
66936
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTableCell());
|
|
66901
66937
|
const tableCellTag = 'nimble-table-cell';
|
|
66902
66938
|
|
|
66903
66939
|
// prettier-ignore
|
|
66904
|
-
const template$
|
|
66940
|
+
const template$k = html `
|
|
66905
66941
|
<template
|
|
66906
66942
|
role="row"
|
|
66907
66943
|
aria-selected=${x => x.ariaSelected}
|
|
@@ -67295,7 +67331,7 @@ focus outline in that case.
|
|
|
67295
67331
|
], TableRow.prototype, "ariaSelected", null);
|
|
67296
67332
|
const nimbleTableRow = TableRow.compose({
|
|
67297
67333
|
baseName: 'table-row',
|
|
67298
|
-
template: template$
|
|
67334
|
+
template: template$k,
|
|
67299
67335
|
styles: styles$k
|
|
67300
67336
|
});
|
|
67301
67337
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTableRow());
|
|
@@ -67393,7 +67429,7 @@ focus outline in that case.
|
|
|
67393
67429
|
|
|
67394
67430
|
/* eslint-disable @typescript-eslint/indent */
|
|
67395
67431
|
// prettier-ignore
|
|
67396
|
-
const template$
|
|
67432
|
+
const template$j = html `
|
|
67397
67433
|
<template
|
|
67398
67434
|
role="row"
|
|
67399
67435
|
@click=${x => x.onGroupExpandToggle()}
|
|
@@ -67551,14 +67587,14 @@ focus outline in that case.
|
|
|
67551
67587
|
], TableGroupRow.prototype, "allowHover", void 0);
|
|
67552
67588
|
const nimbleTableGroupRow = TableGroupRow.compose({
|
|
67553
67589
|
baseName: 'table-group-row',
|
|
67554
|
-
template: template$
|
|
67590
|
+
template: template$j,
|
|
67555
67591
|
styles: styles$i
|
|
67556
67592
|
});
|
|
67557
67593
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTableGroupRow());
|
|
67558
67594
|
const tableGroupRowTag = 'nimble-table-group-row';
|
|
67559
67595
|
|
|
67560
67596
|
// prettier-ignore
|
|
67561
|
-
const template$
|
|
67597
|
+
const template$i = html `
|
|
67562
67598
|
<template
|
|
67563
67599
|
role="treegrid"
|
|
67564
67600
|
${'' /* tabindex managed dynamically by KeyboardNavigationManager */}
|
|
@@ -68290,20 +68326,12 @@ focus outline in that case.
|
|
|
68290
68326
|
const size = this.getSize();
|
|
68291
68327
|
const scrollOffset = this.getScrollOffset();
|
|
68292
68328
|
if (align === "auto") {
|
|
68293
|
-
if (toOffset
|
|
68294
|
-
align = "start";
|
|
68295
|
-
} else if (toOffset >= scrollOffset + size) {
|
|
68329
|
+
if (toOffset >= scrollOffset + size) {
|
|
68296
68330
|
align = "end";
|
|
68297
|
-
} else {
|
|
68298
|
-
align = "start";
|
|
68299
68331
|
}
|
|
68300
68332
|
}
|
|
68301
|
-
if (align === "
|
|
68302
|
-
toOffset
|
|
68303
|
-
} else if (align === "end") {
|
|
68304
|
-
toOffset = toOffset - size;
|
|
68305
|
-
} else if (align === "center") {
|
|
68306
|
-
toOffset = toOffset - size / 2;
|
|
68333
|
+
if (align === "end") {
|
|
68334
|
+
toOffset -= size;
|
|
68307
68335
|
}
|
|
68308
68336
|
const scrollSizeProp = this.options.horizontal ? "scrollWidth" : "scrollHeight";
|
|
68309
68337
|
const scrollSize = this.scrollElement ? "document" in this.scrollElement ? this.scrollElement.document.documentElement[scrollSizeProp] : this.scrollElement[scrollSizeProp] : 0;
|
|
@@ -68327,8 +68355,27 @@ focus outline in that case.
|
|
|
68327
68355
|
return [scrollOffset, align];
|
|
68328
68356
|
}
|
|
68329
68357
|
}
|
|
68330
|
-
const
|
|
68331
|
-
|
|
68358
|
+
const centerOffset = item.start - this.options.scrollPaddingStart + (item.size - size) / 2;
|
|
68359
|
+
switch (align) {
|
|
68360
|
+
case "center":
|
|
68361
|
+
return [this.getOffsetForAlignment(centerOffset, align), align];
|
|
68362
|
+
case "end":
|
|
68363
|
+
return [
|
|
68364
|
+
this.getOffsetForAlignment(
|
|
68365
|
+
item.end + this.options.scrollPaddingEnd,
|
|
68366
|
+
align
|
|
68367
|
+
),
|
|
68368
|
+
align
|
|
68369
|
+
];
|
|
68370
|
+
default:
|
|
68371
|
+
return [
|
|
68372
|
+
this.getOffsetForAlignment(
|
|
68373
|
+
item.start - this.options.scrollPaddingStart,
|
|
68374
|
+
align
|
|
68375
|
+
),
|
|
68376
|
+
align
|
|
68377
|
+
];
|
|
68378
|
+
}
|
|
68332
68379
|
};
|
|
68333
68380
|
this.isDynamicMode = () => this.elementsCache.size > 0;
|
|
68334
68381
|
this.cancelScrollToIndex = () => {
|
|
@@ -71608,7 +71655,7 @@ focus outline in that case.
|
|
|
71608
71655
|
], Table$1.prototype, "windowShiftKeyDown", void 0);
|
|
71609
71656
|
const nimbleTable = Table$1.compose({
|
|
71610
71657
|
baseName: 'table',
|
|
71611
|
-
template: template$
|
|
71658
|
+
template: template$i,
|
|
71612
71659
|
styles: styles$n
|
|
71613
71660
|
});
|
|
71614
71661
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTable());
|
|
@@ -71626,7 +71673,7 @@ focus outline in that case.
|
|
|
71626
71673
|
// Avoiding a wrapping <template> and be careful about starting and ending whitspace
|
|
71627
71674
|
// so the template can be composed into other column header templates
|
|
71628
71675
|
// prettier-ignore
|
|
71629
|
-
const template$
|
|
71676
|
+
const template$h = html `<span
|
|
71630
71677
|
${overflow('hasOverflow')}
|
|
71631
71678
|
class="header-content"
|
|
71632
71679
|
title=${x => (x.hasOverflow && x.headerTextContent ? x.headerTextContent : null)}
|
|
@@ -71734,7 +71781,7 @@ focus outline in that case.
|
|
|
71734
71781
|
|
|
71735
71782
|
/* eslint-disable @typescript-eslint/indent */
|
|
71736
71783
|
// prettier-ignore
|
|
71737
|
-
const template$
|
|
71784
|
+
const template$g = html `
|
|
71738
71785
|
<template
|
|
71739
71786
|
@click="${(x, c) => {
|
|
71740
71787
|
if (typeof x.cellRecord?.href === 'string') {
|
|
@@ -71827,7 +71874,7 @@ focus outline in that case.
|
|
|
71827
71874
|
], TableColumnAnchorCellView.prototype, "showAnchor", null);
|
|
71828
71875
|
const anchorCellView = TableColumnAnchorCellView.compose({
|
|
71829
71876
|
baseName: 'table-column-anchor-cell-view',
|
|
71830
|
-
template: template$
|
|
71877
|
+
template: template$g,
|
|
71831
71878
|
styles: styles$g
|
|
71832
71879
|
});
|
|
71833
71880
|
DesignSystem.getOrCreate().withPrefix('nimble').register(anchorCellView());
|
|
@@ -71905,7 +71952,7 @@ focus outline in that case.
|
|
|
71905
71952
|
observable
|
|
71906
71953
|
], TableColumnTextGroupHeaderViewBase.prototype, "text", void 0);
|
|
71907
71954
|
|
|
71908
|
-
const template$
|
|
71955
|
+
const template$f = html `
|
|
71909
71956
|
<span
|
|
71910
71957
|
${overflow('hasOverflow')}
|
|
71911
71958
|
title="${x => (x.hasOverflow && x.text ? x.text : null)}"
|
|
@@ -71938,7 +71985,7 @@ focus outline in that case.
|
|
|
71938
71985
|
}
|
|
71939
71986
|
const tableColumnTextGroupHeaderView = TableColumnTextGroupHeaderView.compose({
|
|
71940
71987
|
baseName: 'table-column-text-group-header-view',
|
|
71941
|
-
template: template$
|
|
71988
|
+
template: template$f,
|
|
71942
71989
|
styles: styles$f
|
|
71943
71990
|
});
|
|
71944
71991
|
DesignSystem.getOrCreate()
|
|
@@ -72191,7 +72238,7 @@ focus outline in that case.
|
|
|
72191
72238
|
], TableColumnAnchor.prototype, "download", void 0);
|
|
72192
72239
|
const nimbleTableColumnAnchor = TableColumnAnchor.compose({
|
|
72193
72240
|
baseName: 'table-column-anchor',
|
|
72194
|
-
template: template$
|
|
72241
|
+
template: template$h,
|
|
72195
72242
|
styles: styles$h
|
|
72196
72243
|
});
|
|
72197
72244
|
DesignSystem.getOrCreate()
|
|
@@ -72244,7 +72291,7 @@ focus outline in that case.
|
|
|
72244
72291
|
}
|
|
72245
72292
|
const tableColumnDateTextGroupHeaderView = TableColumnDateTextGroupHeaderView.compose({
|
|
72246
72293
|
baseName: 'table-column-date-text-group-header-view',
|
|
72247
|
-
template: template$
|
|
72294
|
+
template: template$f,
|
|
72248
72295
|
styles: styles$f
|
|
72249
72296
|
});
|
|
72250
72297
|
DesignSystem.getOrCreate()
|
|
@@ -72253,7 +72300,7 @@ focus outline in that case.
|
|
|
72253
72300
|
const tableColumnDateTextGroupHeaderViewTag = 'nimble-table-column-date-text-group-header-view';
|
|
72254
72301
|
|
|
72255
72302
|
// prettier-ignore
|
|
72256
|
-
const template$
|
|
72303
|
+
const template$e = html `
|
|
72257
72304
|
<template
|
|
72258
72305
|
class="
|
|
72259
72306
|
${x => (x.alignment === TableColumnAlignment.right ? 'right-align' : '')}
|
|
@@ -72371,7 +72418,7 @@ focus outline in that case.
|
|
|
72371
72418
|
}
|
|
72372
72419
|
const dateTextCellView = TableColumnDateTextCellView.compose({
|
|
72373
72420
|
baseName: 'table-column-date-text-cell-view',
|
|
72374
|
-
template: template$
|
|
72421
|
+
template: template$e,
|
|
72375
72422
|
styles: styles$e
|
|
72376
72423
|
});
|
|
72377
72424
|
DesignSystem.getOrCreate().withPrefix('nimble').register(dateTextCellView());
|
|
@@ -72632,7 +72679,7 @@ focus outline in that case.
|
|
|
72632
72679
|
], TableColumnDateText.prototype, "customHourCycle", void 0);
|
|
72633
72680
|
const nimbleTableColumnDateText = TableColumnDateText.compose({
|
|
72634
72681
|
baseName: 'table-column-date-text',
|
|
72635
|
-
template: template$
|
|
72682
|
+
template: template$h,
|
|
72636
72683
|
styles: styles$h
|
|
72637
72684
|
});
|
|
72638
72685
|
DesignSystem.getOrCreate()
|
|
@@ -72649,7 +72696,7 @@ focus outline in that case.
|
|
|
72649
72696
|
}
|
|
72650
72697
|
const durationTextCellView = TableColumnDurationTextCellView.compose({
|
|
72651
72698
|
baseName: 'table-column-duration-text-cell-view',
|
|
72652
|
-
template: template$
|
|
72699
|
+
template: template$e,
|
|
72653
72700
|
styles: styles$e
|
|
72654
72701
|
});
|
|
72655
72702
|
DesignSystem.getOrCreate()
|
|
@@ -72751,7 +72798,7 @@ focus outline in that case.
|
|
|
72751
72798
|
}
|
|
72752
72799
|
const tableColumnDurationTextGroupHeaderView = TableColumnDurationTextGroupHeaderView.compose({
|
|
72753
72800
|
baseName: 'table-column-duration-text-group-header-view',
|
|
72754
|
-
template: template$
|
|
72801
|
+
template: template$f,
|
|
72755
72802
|
styles: styles$f
|
|
72756
72803
|
});
|
|
72757
72804
|
DesignSystem.getOrCreate()
|
|
@@ -72804,7 +72851,7 @@ focus outline in that case.
|
|
|
72804
72851
|
}
|
|
72805
72852
|
const nimbleTableColumnDurationText = TableColumnDurationText.compose({
|
|
72806
72853
|
baseName: 'table-column-duration-text',
|
|
72807
|
-
template: template$
|
|
72854
|
+
template: template$h,
|
|
72808
72855
|
styles: styles$h
|
|
72809
72856
|
});
|
|
72810
72857
|
DesignSystem.getOrCreate()
|
|
@@ -72921,7 +72968,7 @@ focus outline in that case.
|
|
|
72921
72968
|
}
|
|
72922
72969
|
`;
|
|
72923
72970
|
|
|
72924
|
-
const template$
|
|
72971
|
+
const template$d = html `${template$h}<slot ${slotted('mappings')} name="mapping"></slot>`;
|
|
72925
72972
|
|
|
72926
72973
|
const enumBaseValidityFlagNames = [
|
|
72927
72974
|
'invalidMappingKeyValueForType',
|
|
@@ -73032,7 +73079,7 @@ focus outline in that case.
|
|
|
73032
73079
|
`;
|
|
73033
73080
|
|
|
73034
73081
|
// prettier-ignore
|
|
73035
|
-
const template$
|
|
73082
|
+
const template$c = html `
|
|
73036
73083
|
${when(x => x.visualizationTemplate, html `
|
|
73037
73084
|
<span class="reserve-icon-size">
|
|
73038
73085
|
${x => x.visualizationTemplate}
|
|
@@ -73181,7 +73228,7 @@ focus outline in that case.
|
|
|
73181
73228
|
], TableColumnMappingGroupHeaderView.prototype, "visualizationTemplate", void 0);
|
|
73182
73229
|
const mappingGroupHeaderView = TableColumnMappingGroupHeaderView.compose({
|
|
73183
73230
|
baseName: 'table-column-mapping-group-header-view',
|
|
73184
|
-
template: template$
|
|
73231
|
+
template: template$c,
|
|
73185
73232
|
styles: styles$c
|
|
73186
73233
|
});
|
|
73187
73234
|
DesignSystem.getOrCreate()
|
|
@@ -73214,7 +73261,7 @@ focus outline in that case.
|
|
|
73214
73261
|
`;
|
|
73215
73262
|
|
|
73216
73263
|
// prettier-ignore
|
|
73217
|
-
const template$
|
|
73264
|
+
const template$b = html `
|
|
73218
73265
|
${when(x => x.visualizationTemplate, html `
|
|
73219
73266
|
<span class="reserve-icon-size">
|
|
73220
73267
|
${x => x.visualizationTemplate}
|
|
@@ -73301,7 +73348,7 @@ focus outline in that case.
|
|
|
73301
73348
|
], TableColumnMappingCellView.prototype, "hasOverflow", void 0);
|
|
73302
73349
|
const mappingCellView = TableColumnMappingCellView.compose({
|
|
73303
73350
|
baseName: 'table-column-mapping-cell-view',
|
|
73304
|
-
template: template$
|
|
73351
|
+
template: template$b,
|
|
73305
73352
|
styles: styles$b
|
|
73306
73353
|
});
|
|
73307
73354
|
DesignSystem.getOrCreate().withPrefix('nimble').register(mappingCellView());
|
|
@@ -73386,16 +73433,16 @@ focus outline in that case.
|
|
|
73386
73433
|
], TableColumnMapping.prototype, "widthMode", void 0);
|
|
73387
73434
|
const nimbleTableColumnMapping = TableColumnMapping.compose({
|
|
73388
73435
|
baseName: 'table-column-mapping',
|
|
73389
|
-
template: template$
|
|
73436
|
+
template: template$d,
|
|
73390
73437
|
styles: styles$d
|
|
73391
73438
|
});
|
|
73392
73439
|
DesignSystem.getOrCreate()
|
|
73393
73440
|
.withPrefix('nimble')
|
|
73394
73441
|
.register(nimbleTableColumnMapping());
|
|
73395
73442
|
|
|
73396
|
-
const template$
|
|
73443
|
+
const template$a = html `
|
|
73397
73444
|
<template @delegated-event="${(x, c) => x.onDelegatedEvent(c.event)}"
|
|
73398
|
-
>${template$
|
|
73445
|
+
>${template$h}</template
|
|
73399
73446
|
>
|
|
73400
73447
|
`;
|
|
73401
73448
|
|
|
@@ -73403,7 +73450,7 @@ focus outline in that case.
|
|
|
73403
73450
|
const cellViewMenuSlotName = 'menu-button-menu';
|
|
73404
73451
|
|
|
73405
73452
|
// prettier-ignore
|
|
73406
|
-
const template$
|
|
73453
|
+
const template$9 = html `
|
|
73407
73454
|
${when(x => x.showMenuButton, html `
|
|
73408
73455
|
<${menuButtonTag}
|
|
73409
73456
|
${ref('menuButton')}
|
|
@@ -73497,7 +73544,7 @@ focus outline in that case.
|
|
|
73497
73544
|
], TableColumnMenuButtonCellView.prototype, "showMenuButton", null);
|
|
73498
73545
|
const menuButtonCellView = TableColumnMenuButtonCellView.compose({
|
|
73499
73546
|
baseName: 'table-column-menu-button-cell-view',
|
|
73500
|
-
template: template$
|
|
73547
|
+
template: template$9,
|
|
73501
73548
|
styles: styles$a
|
|
73502
73549
|
});
|
|
73503
73550
|
DesignSystem.getOrCreate().withPrefix('nimble').register(menuButtonCellView());
|
|
@@ -73553,7 +73600,7 @@ focus outline in that case.
|
|
|
73553
73600
|
], TableColumnMenuButton.prototype, "menuSlot", void 0);
|
|
73554
73601
|
const nimbleTableColumnMenuButton = TableColumnMenuButton.compose({
|
|
73555
73602
|
baseName: 'table-column-menu-button',
|
|
73556
|
-
template: template$
|
|
73603
|
+
template: template$a,
|
|
73557
73604
|
styles: styles$h
|
|
73558
73605
|
});
|
|
73559
73606
|
DesignSystem.getOrCreate()
|
|
@@ -73563,7 +73610,7 @@ focus outline in that case.
|
|
|
73563
73610
|
// Avoiding a wrapping <template> and be careful about starting and ending whitespace
|
|
73564
73611
|
// so the template can be composed into other column header templates
|
|
73565
73612
|
// prettier-ignore
|
|
73566
|
-
const template$
|
|
73613
|
+
const template$8 = html `<span
|
|
73567
73614
|
${overflow('hasOverflow')}
|
|
73568
73615
|
class="header-content"
|
|
73569
73616
|
title=${x => (x.hasOverflow && x.headerTextContent ? x.headerTextContent : null)}
|
|
@@ -73582,7 +73629,7 @@ focus outline in that case.
|
|
|
73582
73629
|
}
|
|
73583
73630
|
const tableColumnNumberTextGroupHeaderView = TableColumnNumberTextGroupHeaderView.compose({
|
|
73584
73631
|
baseName: 'table-column-number-text-group-header-view',
|
|
73585
|
-
template: template$
|
|
73632
|
+
template: template$f,
|
|
73586
73633
|
styles: styles$f
|
|
73587
73634
|
});
|
|
73588
73635
|
DesignSystem.getOrCreate()
|
|
@@ -73604,7 +73651,7 @@ focus outline in that case.
|
|
|
73604
73651
|
}
|
|
73605
73652
|
const numberTextCellView = TableColumnNumberTextCellView.compose({
|
|
73606
73653
|
baseName: 'table-column-number-text-cell-view',
|
|
73607
|
-
template: template$
|
|
73654
|
+
template: template$e,
|
|
73608
73655
|
styles: styles$e
|
|
73609
73656
|
});
|
|
73610
73657
|
DesignSystem.getOrCreate().withPrefix('nimble').register(numberTextCellView());
|
|
@@ -74146,7 +74193,7 @@ focus outline in that case.
|
|
|
74146
74193
|
], TableColumnNumberText.prototype, "unit", void 0);
|
|
74147
74194
|
const nimbleTableColumnNumberText = TableColumnNumberText.compose({
|
|
74148
74195
|
baseName: 'table-column-number-text',
|
|
74149
|
-
template: template$
|
|
74196
|
+
template: template$8,
|
|
74150
74197
|
styles: styles$h
|
|
74151
74198
|
});
|
|
74152
74199
|
DesignSystem.getOrCreate()
|
|
@@ -74165,7 +74212,7 @@ focus outline in that case.
|
|
|
74165
74212
|
}
|
|
74166
74213
|
const textCellView = TableColumnTextCellView.compose({
|
|
74167
74214
|
baseName: 'table-column-text-cell-view',
|
|
74168
|
-
template: template$
|
|
74215
|
+
template: template$e,
|
|
74169
74216
|
styles: styles$e
|
|
74170
74217
|
});
|
|
74171
74218
|
DesignSystem.getOrCreate().withPrefix('nimble').register(textCellView());
|
|
@@ -74220,7 +74267,7 @@ focus outline in that case.
|
|
|
74220
74267
|
}
|
|
74221
74268
|
const nimbleTableColumnText = TableColumnText.compose({
|
|
74222
74269
|
baseName: 'table-column-text',
|
|
74223
|
-
template: template$
|
|
74270
|
+
template: template$h,
|
|
74224
74271
|
styles: styles$h
|
|
74225
74272
|
});
|
|
74226
74273
|
DesignSystem.getOrCreate()
|
|
@@ -74309,7 +74356,7 @@ focus outline in that case.
|
|
|
74309
74356
|
const nimbleTabs = Tabs.compose({
|
|
74310
74357
|
baseName: 'tabs',
|
|
74311
74358
|
baseClass: Tabs$1,
|
|
74312
|
-
template: template$
|
|
74359
|
+
template: template$I,
|
|
74313
74360
|
styles: styles$9
|
|
74314
74361
|
});
|
|
74315
74362
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTabs());
|
|
@@ -74333,7 +74380,7 @@ focus outline in that case.
|
|
|
74333
74380
|
}
|
|
74334
74381
|
`;
|
|
74335
74382
|
|
|
74336
|
-
const template$
|
|
74383
|
+
const template$7 = html `
|
|
74337
74384
|
<template slot="end">
|
|
74338
74385
|
<div class="separator"></div>
|
|
74339
74386
|
<slot></slot>
|
|
@@ -74347,7 +74394,7 @@ focus outline in that case.
|
|
|
74347
74394
|
}
|
|
74348
74395
|
const nimbleTabsToolbar = TabsToolbar.compose({
|
|
74349
74396
|
baseName: 'tabs-toolbar',
|
|
74350
|
-
template: template$
|
|
74397
|
+
template: template$7,
|
|
74351
74398
|
styles: styles$8
|
|
74352
74399
|
});
|
|
74353
74400
|
DesignSystem.getOrCreate().withPrefix('nimble').register(nimbleTabsToolbar());
|
|
@@ -74521,7 +74568,7 @@ focus outline in that case.
|
|
|
74521
74568
|
}
|
|
74522
74569
|
`));
|
|
74523
74570
|
|
|
74524
|
-
const template$
|
|
74571
|
+
const template$6 = () => html `
|
|
74525
74572
|
<label
|
|
74526
74573
|
part="label"
|
|
74527
74574
|
for="control"
|
|
@@ -74670,7 +74717,7 @@ focus outline in that case.
|
|
|
74670
74717
|
const nimbleTextArea = TextArea.compose({
|
|
74671
74718
|
baseName: 'text-area',
|
|
74672
74719
|
baseClass: TextArea$1,
|
|
74673
|
-
template: template$
|
|
74720
|
+
template: template$6,
|
|
74674
74721
|
styles: styles$7,
|
|
74675
74722
|
shadowOptions: {
|
|
74676
74723
|
delegatesFocus: true
|
|
@@ -74927,6 +74974,77 @@ focus outline in that case.
|
|
|
74927
74974
|
}
|
|
74928
74975
|
`));
|
|
74929
74976
|
|
|
74977
|
+
/**
|
|
74978
|
+
* The template for the {@link @microsoft/fast-foundation#(TextField:class)} component.
|
|
74979
|
+
* @public
|
|
74980
|
+
*/
|
|
74981
|
+
const template$5 = (context, definition) => html `
|
|
74982
|
+
<template
|
|
74983
|
+
class="
|
|
74984
|
+
${x => (x.readOnly ? 'readonly' : '')}
|
|
74985
|
+
"
|
|
74986
|
+
>
|
|
74987
|
+
<label
|
|
74988
|
+
part="label"
|
|
74989
|
+
for="control"
|
|
74990
|
+
class="${x => (x.defaultSlottedNodes?.length
|
|
74991
|
+
? 'label'
|
|
74992
|
+
: 'label label__hidden')}"
|
|
74993
|
+
>
|
|
74994
|
+
<slot
|
|
74995
|
+
${slotted({
|
|
74996
|
+
property: 'defaultSlottedNodes',
|
|
74997
|
+
filter: whitespaceFilter
|
|
74998
|
+
})}
|
|
74999
|
+
></slot>
|
|
75000
|
+
</label>
|
|
75001
|
+
<div class="root" part="root">
|
|
75002
|
+
${startSlotTemplate(context, definition)}
|
|
75003
|
+
<input
|
|
75004
|
+
class="control"
|
|
75005
|
+
part="control"
|
|
75006
|
+
id="control"
|
|
75007
|
+
@input="${x => x.handleTextInput()}"
|
|
75008
|
+
@change="${x => x.handleChange()}"
|
|
75009
|
+
?autofocus="${x => x.autofocus}"
|
|
75010
|
+
?disabled="${x => x.disabled}"
|
|
75011
|
+
list="${x => x.list}"
|
|
75012
|
+
maxlength="${x => x.maxlength}"
|
|
75013
|
+
minlength="${x => x.minlength}"
|
|
75014
|
+
pattern="${x => x.pattern}"
|
|
75015
|
+
placeholder="${x => x.placeholder}"
|
|
75016
|
+
?readonly="${x => x.readOnly}"
|
|
75017
|
+
?required="${x => x.required}"
|
|
75018
|
+
size="${x => x.size}"
|
|
75019
|
+
?spellcheck="${x => x.spellcheck}"
|
|
75020
|
+
:value="${x => x.value}"
|
|
75021
|
+
type="${x => x.type}"
|
|
75022
|
+
aria-atomic="${x => x.ariaAtomic}"
|
|
75023
|
+
aria-busy="${x => x.ariaBusy}"
|
|
75024
|
+
aria-controls="${x => x.ariaControls}"
|
|
75025
|
+
aria-current="${x => x.ariaCurrent}"
|
|
75026
|
+
aria-describedby="${x => x.ariaDescribedby}"
|
|
75027
|
+
aria-details="${x => x.ariaDetails}"
|
|
75028
|
+
aria-disabled="${x => x.ariaDisabled}"
|
|
75029
|
+
aria-errormessage="${x => x.ariaErrormessage}"
|
|
75030
|
+
aria-flowto="${x => x.ariaFlowto}"
|
|
75031
|
+
aria-haspopup="${x => x.ariaHaspopup}"
|
|
75032
|
+
aria-hidden="${x => x.ariaHidden}"
|
|
75033
|
+
aria-invalid="${x => x.ariaInvalid}"
|
|
75034
|
+
aria-keyshortcuts="${x => x.ariaKeyshortcuts}"
|
|
75035
|
+
aria-label="${x => x.ariaLabel}"
|
|
75036
|
+
aria-labelledby="${x => x.ariaLabelledby}"
|
|
75037
|
+
aria-live="${x => x.ariaLive}"
|
|
75038
|
+
aria-owns="${x => x.ariaOwns}"
|
|
75039
|
+
aria-relevant="${x => x.ariaRelevant}"
|
|
75040
|
+
aria-roledescription="${x => x.ariaRoledescription}"
|
|
75041
|
+
${ref('control')}
|
|
75042
|
+
/>
|
|
75043
|
+
${endSlotTemplate(context, definition)}
|
|
75044
|
+
</div>
|
|
75045
|
+
</template>
|
|
75046
|
+
`;
|
|
75047
|
+
|
|
74930
75048
|
/**
|
|
74931
75049
|
* A nimble-styed HTML text input
|
|
74932
75050
|
*/
|
|
@@ -74953,7 +75071,7 @@ focus outline in that case.
|
|
|
74953
75071
|
const nimbleTextField = TextField.compose({
|
|
74954
75072
|
baseName: 'text-field',
|
|
74955
75073
|
baseClass: TextField$1,
|
|
74956
|
-
template:
|
|
75074
|
+
template: template$5,
|
|
74957
75075
|
styles: styles$6,
|
|
74958
75076
|
shadowOptions: {
|
|
74959
75077
|
delegatesFocus: true
|