@geotab/zenith 3.13.0-beta.0 → 3.13.1-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -1
- package/dist/chart/lineChart/getDefaultOptions.js +7 -2
- package/dist/commonHelpers/hooks/usePillSize.js +2 -2
- package/dist/controlledPopup/controlledPopup.d.ts +4 -1
- package/dist/controlledPopup/controlledPopup.js +2 -2
- package/dist/filters/components/filtersContainer.js +64 -7
- package/dist/filters/components/filtersSearch.d.ts +7 -2
- package/dist/filters/components/filtersSearch.js +36 -72
- package/dist/filters/components/filtersSearchList.js +18 -35
- package/dist/filters/filters.d.ts +2 -0
- package/dist/filters/filters.js +66 -180
- package/dist/filters/filtersHelper.js +1 -1
- package/dist/groupsFilterRaw/groupsFilterRaw.js +7 -1
- package/dist/index.css +158 -69
- package/dist/inputAdornments/inputAdornments.d.ts +2 -1
- package/dist/inputAdornments/inputAdornments.js +2 -2
- package/dist/searchInputRaw/searchInputRaw.js +6 -2
- package/dist/searchInputRaw/types.d.ts +4 -0
- package/dist/utils/localization/translations/en.json +1 -0
- package/dist/utils/positioningUtils/calculatePosition.js +3 -1
- package/dist/utils/positioningUtils/normalizeVertically.js +1 -1
- package/esm/chart/lineChart/getDefaultOptions.js +7 -2
- package/esm/commonHelpers/hooks/usePillSize.js +2 -2
- package/esm/controlledPopup/controlledPopup.d.ts +4 -1
- package/esm/controlledPopup/controlledPopup.js +2 -2
- package/esm/filters/components/filtersContainer.js +65 -8
- package/esm/filters/components/filtersSearch.d.ts +7 -2
- package/esm/filters/components/filtersSearch.js +36 -49
- package/esm/filters/components/filtersSearchList.js +18 -35
- package/esm/filters/filters.d.ts +2 -0
- package/esm/filters/filters.js +67 -181
- package/esm/filters/filtersHelper.js +1 -1
- package/esm/groupsFilterRaw/groupsFilterRaw.js +7 -1
- package/esm/inputAdornments/inputAdornments.d.ts +2 -1
- package/esm/inputAdornments/inputAdornments.js +2 -2
- package/esm/searchInputRaw/searchInputRaw.js +6 -2
- package/esm/searchInputRaw/types.d.ts +4 -0
- package/esm/utils/localization/translations/en.json +1 -0
- package/esm/utils/positioningUtils/calculatePosition.js +3 -1
- package/esm/utils/positioningUtils/normalizeVertically.js +1 -1
- package/package.json +1 -1
package/dist/index.css
CHANGED
|
@@ -9402,11 +9402,13 @@ html:lang(ar) .zen-text-input {
|
|
|
9402
9402
|
line-height: 1rem;
|
|
9403
9403
|
text-transform: none;
|
|
9404
9404
|
text-decoration: none;
|
|
9405
|
-
font-size: 16px !important;
|
|
9406
9405
|
}
|
|
9407
9406
|
html:lang(ar) .zen-text-input.zen-text-input--mobile {
|
|
9408
9407
|
font-family: "Noto Sans Arabic", Roboto, "Segoe UI", Segoe, "Helvetica Neue", Helvetica, sans-serif;
|
|
9409
9408
|
}
|
|
9409
|
+
.zen-text-input.zen-text-input--mobile input {
|
|
9410
|
+
font-size: 16px;
|
|
9411
|
+
}
|
|
9410
9412
|
.zen-input-adornments-border {
|
|
9411
9413
|
box-sizing: border-box;
|
|
9412
9414
|
border: 0;
|
|
@@ -9534,7 +9536,6 @@ html:lang(ar) .zen-text-input.zen-text-input--mobile {
|
|
|
9534
9536
|
display: grid;
|
|
9535
9537
|
gap: 0.5rem;
|
|
9536
9538
|
align-items: center;
|
|
9537
|
-
font-size: 1.0625rem;
|
|
9538
9539
|
}
|
|
9539
9540
|
.zen-input-adornments.zen-input-adornments--mobile.zen-input-adornments--has-start,
|
|
9540
9541
|
.zen-input-adornments.zen-input-adornments--mobile.zen-input-adornments--has-end {
|
|
@@ -13130,17 +13131,51 @@ html:lang(ar) .zen-file-upload__file-name {
|
|
|
13130
13131
|
}
|
|
13131
13132
|
}
|
|
13132
13133
|
.zen-filters {
|
|
13133
|
-
|
|
13134
|
+
display: flex;
|
|
13135
|
+
align-items: center;
|
|
13136
|
+
gap: 0.5rem;
|
|
13137
|
+
width: 100%;
|
|
13134
13138
|
box-sizing: border-box;
|
|
13135
13139
|
}
|
|
13136
13140
|
.zen-filters * {
|
|
13137
13141
|
box-sizing: border-box;
|
|
13138
13142
|
}
|
|
13143
|
+
.zen-filters .zen-filters-search {
|
|
13144
|
+
flex-grow: 0;
|
|
13145
|
+
flex-shrink: 0;
|
|
13146
|
+
margin: 0;
|
|
13147
|
+
width: 11.25rem;
|
|
13148
|
+
}
|
|
13149
|
+
.zen-filters--mobile {
|
|
13150
|
+
flex-wrap: nowrap;
|
|
13151
|
+
overflow-inline: auto;
|
|
13152
|
+
overflow-block: hidden;
|
|
13153
|
+
scrollbar-width: none;
|
|
13154
|
+
-ms-overflow-style: none;
|
|
13155
|
+
}
|
|
13156
|
+
.zen-filters--mobile::-webkit-scrollbar {
|
|
13157
|
+
display: none;
|
|
13158
|
+
}
|
|
13159
|
+
.zen-filters--mobile .zen-filters__main-row--mobile {
|
|
13160
|
+
flex-shrink: 0;
|
|
13161
|
+
}
|
|
13162
|
+
.zen-filters--mobile .zen-filters-container {
|
|
13163
|
+
flex-shrink: 0;
|
|
13164
|
+
flex-grow: 0;
|
|
13165
|
+
flex-wrap: nowrap;
|
|
13166
|
+
width: auto;
|
|
13167
|
+
min-width: unset;
|
|
13168
|
+
}
|
|
13169
|
+
.zen-filters--mobile .zen-filters-container__mobile-scroll-wrapper {
|
|
13170
|
+
overflow: visible;
|
|
13171
|
+
width: auto;
|
|
13172
|
+
flex-shrink: 0;
|
|
13173
|
+
}
|
|
13139
13174
|
.zen-filters__main-row {
|
|
13140
13175
|
display: flex;
|
|
13141
13176
|
align-items: center;
|
|
13142
13177
|
box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.15);
|
|
13143
|
-
border-radius:
|
|
13178
|
+
border-radius: 999px;
|
|
13144
13179
|
border: var(--border-width-default) solid var(--borders-general);
|
|
13145
13180
|
background-color: var(--backgrounds-main);
|
|
13146
13181
|
}
|
|
@@ -13150,12 +13185,15 @@ html:lang(ar) .zen-file-upload__file-name {
|
|
|
13150
13185
|
.zen-filters__main-row:hover .zen-search-input__input {
|
|
13151
13186
|
background-color: var(--backgrounds-content-0);
|
|
13152
13187
|
}
|
|
13153
|
-
.zen-filters__main-row--mobile {
|
|
13154
|
-
margin: 0.5rem;
|
|
13155
|
-
}
|
|
13156
13188
|
.zen-filters__main-row--initial {
|
|
13157
13189
|
view-transition-name: expand-panel;
|
|
13158
13190
|
}
|
|
13191
|
+
.zen-filters__main-row--mobile {
|
|
13192
|
+
width: auto;
|
|
13193
|
+
}
|
|
13194
|
+
.zen-filters__main-row--mobile .zen-filters-search {
|
|
13195
|
+
width: auto;
|
|
13196
|
+
}
|
|
13159
13197
|
.zen-filters__select-trigger {
|
|
13160
13198
|
width: auto;
|
|
13161
13199
|
flex-shrink: 0;
|
|
@@ -13202,39 +13240,53 @@ html:lang(ar) .zen-file-upload__file-name {
|
|
|
13202
13240
|
}
|
|
13203
13241
|
.zen-filters__search .zen-search-input__input {
|
|
13204
13242
|
border: none;
|
|
13205
|
-
|
|
13206
|
-
|
|
13207
|
-
|
|
13243
|
+
border-radius: 999px;
|
|
13244
|
+
display: flex;
|
|
13245
|
+
}
|
|
13246
|
+
.zen-filters__search-with-pills {
|
|
13247
|
+
border-radius: 999px;
|
|
13208
13248
|
}
|
|
13209
|
-
.zen-filters-popup.zen-filters-popup
|
|
13249
|
+
.zen-filters-popup.zen-filters-popup {
|
|
13210
13250
|
box-sizing: border-box;
|
|
13211
|
-
|
|
13212
|
-
|
|
13251
|
+
border-radius: 0.5rem;
|
|
13252
|
+
overflow: hidden;
|
|
13253
|
+
display: flex;
|
|
13254
|
+
flex-direction: column;
|
|
13255
|
+
width: 28.125rem;
|
|
13256
|
+
max-width: 100%;
|
|
13213
13257
|
view-transition-name: expand-panel;
|
|
13258
|
+
padding: 0;
|
|
13214
13259
|
}
|
|
13215
|
-
.zen-filters-popup.zen-filters-popup
|
|
13260
|
+
.zen-filters-popup.zen-filters-popup * {
|
|
13216
13261
|
box-sizing: border-box;
|
|
13217
13262
|
}
|
|
13218
13263
|
.zen-filters-popup__first-row {
|
|
13219
13264
|
display: flex;
|
|
13220
|
-
justify-content: space-between;
|
|
13221
13265
|
align-items: center;
|
|
13222
|
-
|
|
13223
|
-
padding: 0;
|
|
13266
|
+
border-block-end: var(--border-width-default) solid var(--borders-general);
|
|
13224
13267
|
}
|
|
13225
|
-
.zen-filters-popup__first-row
|
|
13226
|
-
|
|
13268
|
+
.zen-filters-popup__first-row .zen-filters-search {
|
|
13269
|
+
flex-grow: 1;
|
|
13270
|
+
margin: 0;
|
|
13271
|
+
width: 100%;
|
|
13227
13272
|
}
|
|
13228
|
-
.zen-filters-
|
|
13229
|
-
|
|
13230
|
-
padding: 1rem 0;
|
|
13273
|
+
.zen-filters-popup__first-row .zen-search-input__close-button--visible {
|
|
13274
|
+
visibility: visible;
|
|
13231
13275
|
}
|
|
13232
|
-
.zen-filters-popup__second-row
|
|
13276
|
+
.zen-filters-popup__second-row {
|
|
13233
13277
|
border-block-start: none;
|
|
13234
13278
|
padding: 0;
|
|
13279
|
+
display: flex;
|
|
13280
|
+
flex-direction: column;
|
|
13281
|
+
flex: 1;
|
|
13282
|
+
min-height: 0;
|
|
13283
|
+
overflow-block: hidden;
|
|
13235
13284
|
}
|
|
13236
13285
|
.zen-filters-popup__content {
|
|
13237
13286
|
display: flex;
|
|
13287
|
+
flex: 1;
|
|
13288
|
+
min-height: 0;
|
|
13289
|
+
overflow: hidden;
|
|
13238
13290
|
}
|
|
13239
13291
|
.zen-filters-popup__content .zen-filters-popup__left-panel {
|
|
13240
13292
|
display: flex;
|
|
@@ -13250,36 +13302,55 @@ html:lang(ar) .zen-file-upload__file-name {
|
|
|
13250
13302
|
}
|
|
13251
13303
|
.zen-filters-popup__content .zen-filters-popup__right-panel {
|
|
13252
13304
|
flex-grow: 1;
|
|
13253
|
-
|
|
13254
|
-
|
|
13255
|
-
|
|
13256
|
-
.zen-filters-popup.zen-filters-popup--mobile {
|
|
13257
|
-
width: 100%;
|
|
13258
|
-
max-width: 100%;
|
|
13259
|
-
view-transition-name: expand-panel;
|
|
13260
|
-
}
|
|
13261
|
-
.zen-filters-popup.zen-filters-popup--mobile .zen-filters-popup__right-panel {
|
|
13305
|
+
display: flex;
|
|
13306
|
+
flex-direction: column;
|
|
13307
|
+
min-height: 0;
|
|
13262
13308
|
max-width: 100%;
|
|
13263
13309
|
}
|
|
13264
13310
|
.zen-filters-container {
|
|
13265
13311
|
display: flex;
|
|
13266
13312
|
flex-flow: row wrap;
|
|
13313
|
+
flex-grow: 1;
|
|
13314
|
+
min-width: 0;
|
|
13267
13315
|
gap: 0.25rem;
|
|
13268
|
-
margin-block-start: 0
|
|
13316
|
+
margin-block-start: 0;
|
|
13269
13317
|
padding: 0.5rem 0;
|
|
13270
13318
|
}
|
|
13271
|
-
.zen-filters-
|
|
13272
|
-
|
|
13273
|
-
|
|
13319
|
+
.zen-filters-container .zen-chip--default {
|
|
13320
|
+
background-color: var(--backgrounds-main);
|
|
13321
|
+
color: var(--text-secondary);
|
|
13322
|
+
fill: var(--text-secondary);
|
|
13323
|
+
}
|
|
13324
|
+
.zen-filters-container .zen-chip--default:hover {
|
|
13325
|
+
background-color: var(--backgrounds-content-1);
|
|
13326
|
+
}
|
|
13327
|
+
.zen-filters-container .zen-chip--active {
|
|
13328
|
+
background-color: var(--accents-general--main);
|
|
13329
|
+
color: var(--action-primary--active);
|
|
13330
|
+
fill: var(--action-primary--active);
|
|
13331
|
+
border-color: var(--action-primary--active);
|
|
13332
|
+
}
|
|
13333
|
+
.zen-filters-container .zen-chip--active:hover {
|
|
13334
|
+
border-color: var(--action-primary--active);
|
|
13335
|
+
}
|
|
13336
|
+
.zen-filters-container .zen-chip--accent {
|
|
13337
|
+
background-color: var(--action-primary--active);
|
|
13338
|
+
color: var(--accents-general--main);
|
|
13339
|
+
fill: var(--accents-general--main);
|
|
13340
|
+
border-color: var(--action-primary--active);
|
|
13274
13341
|
}
|
|
13275
|
-
.zen-filters-
|
|
13276
|
-
border:
|
|
13342
|
+
.zen-filters-container__save-chip.zen-chip--active {
|
|
13343
|
+
border-color: var(--borders-general);
|
|
13277
13344
|
}
|
|
13278
13345
|
.zen-filters-container.zen-filters-container--mobile {
|
|
13279
13346
|
padding: 0;
|
|
13280
13347
|
}
|
|
13348
|
+
.zen-filters-container.zen-filters-container--mobile .zen-chip {
|
|
13349
|
+
height: 40px;
|
|
13350
|
+
padding-block: 0.75rem;
|
|
13351
|
+
padding-inline: 0.5rem;
|
|
13352
|
+
}
|
|
13281
13353
|
.zen-filters-container__mobile-scroll-wrapper {
|
|
13282
|
-
margin-inline-start: 0.5rem;
|
|
13283
13354
|
padding: 0.125rem;
|
|
13284
13355
|
display: flex;
|
|
13285
13356
|
flex-flow: row nowrap;
|
|
@@ -13298,9 +13369,6 @@ html:lang(ar) .zen-file-upload__file-name {
|
|
|
13298
13369
|
.zen-filters-container__mobile-scroll-wrapper > * {
|
|
13299
13370
|
flex-shrink: 0;
|
|
13300
13371
|
}
|
|
13301
|
-
.zen-filters-container__mobile-scroll-wrapper:last-child {
|
|
13302
|
-
margin-inline-end: 0.5rem;
|
|
13303
|
-
}
|
|
13304
13372
|
.zen-filters-container.zen-filters__container--no-search {
|
|
13305
13373
|
margin-block-start: 0;
|
|
13306
13374
|
padding: 0;
|
|
@@ -14517,19 +14585,19 @@ html:lang(ar) .zen-list-item__secondary {
|
|
|
14517
14585
|
justify-content: center;
|
|
14518
14586
|
}
|
|
14519
14587
|
.zen-filters-search-list {
|
|
14520
|
-
|
|
14521
|
-
min-height:
|
|
14588
|
+
flex: 1;
|
|
14589
|
+
min-height: 0;
|
|
14590
|
+
overflow-block: auto;
|
|
14522
14591
|
}
|
|
14523
14592
|
.zen-filters-search-list--mobile {
|
|
14524
14593
|
padding: 1rem 0;
|
|
14525
|
-
overflow-block: auto;
|
|
14526
14594
|
}
|
|
14527
14595
|
.zen-filters-search-list__header {
|
|
14528
14596
|
display: flex;
|
|
14529
14597
|
align-items: center;
|
|
14530
14598
|
justify-content: space-between;
|
|
14531
|
-
margin-block:
|
|
14532
|
-
margin-inline:
|
|
14599
|
+
margin-block: 1rem;
|
|
14600
|
+
margin-inline: 1rem;
|
|
14533
14601
|
}
|
|
14534
14602
|
.zen-filters-search-list__header-title {
|
|
14535
14603
|
font-family: Roboto, "Segoe UI", Segoe, "Helvetica Neue", Helvetica, sans-serif;
|
|
@@ -14545,9 +14613,10 @@ html:lang(ar) .zen-list-item__secondary {
|
|
|
14545
14613
|
html:lang(ar) .zen-filters-search-list__header-title {
|
|
14546
14614
|
font-family: "Noto Sans Arabic", Roboto, "Segoe UI", Segoe, "Helvetica Neue", Helvetica, sans-serif;
|
|
14547
14615
|
}
|
|
14548
|
-
.zen-filters-search-
|
|
14549
|
-
|
|
14550
|
-
|
|
14616
|
+
.zen-filters-search-list__header-actions {
|
|
14617
|
+
display: flex;
|
|
14618
|
+
align-items: center;
|
|
14619
|
+
gap: 0.25rem;
|
|
14551
14620
|
}
|
|
14552
14621
|
.zen-filters-search-list .zen-filters-search-list__header--drive .zen-filters-search-list__header-title {
|
|
14553
14622
|
font-family: "Roboto Mono", "Segoe UI", Segoe, "Helvetica Neue", Helvetica, sans-serif;
|
|
@@ -14699,10 +14768,6 @@ html:lang(ar) .zen-search-item-data__identifier {
|
|
|
14699
14768
|
line-height: 1rem;
|
|
14700
14769
|
text-transform: none;
|
|
14701
14770
|
text-decoration: none;
|
|
14702
|
-
overflow: hidden;
|
|
14703
|
-
text-overflow: ellipsis;
|
|
14704
|
-
white-space: nowrap;
|
|
14705
|
-
overflow-wrap: normal;
|
|
14706
14771
|
color: var(--text-primary);
|
|
14707
14772
|
flex: 1 1 auto;
|
|
14708
14773
|
align-content: center;
|
|
@@ -16208,27 +16273,55 @@ html:lang(ar) .zen-filters-saved-popup__content.zen-filters-saved-popup__content
|
|
|
16208
16273
|
flex-grow: 1;
|
|
16209
16274
|
margin: 0 0.75rem;
|
|
16210
16275
|
}
|
|
16276
|
+
.zen-filters-search__search-input {
|
|
16277
|
+
flex: 1;
|
|
16278
|
+
min-width: 0;
|
|
16279
|
+
}
|
|
16211
16280
|
.zen-filters-search__selected {
|
|
16212
16281
|
display: flex;
|
|
16213
16282
|
gap: 0.5rem;
|
|
16214
16283
|
flex-wrap: nowrap;
|
|
16215
16284
|
align-items: center;
|
|
16216
|
-
margin-inline-
|
|
16217
|
-
|
|
16285
|
+
margin-inline-end: 0.5rem;
|
|
16286
|
+
flex-shrink: 0;
|
|
16218
16287
|
}
|
|
16219
16288
|
.zen-filters-search__selected-item {
|
|
16220
16289
|
max-width: 11.3125rem;
|
|
16221
16290
|
}
|
|
16222
16291
|
.zen-filters-search__selected-item--more {
|
|
16223
16292
|
flex-shrink: 0;
|
|
16293
|
+
min-width: 1.375rem;
|
|
16294
|
+
justify-content: center;
|
|
16224
16295
|
}
|
|
16225
|
-
.zen-filters-search.zen-filters-popup__search-with-pills
|
|
16296
|
+
.zen-filters-search.zen-filters-popup__search-with-pills {
|
|
16226
16297
|
margin: 0;
|
|
16227
16298
|
padding: 0 0.75rem;
|
|
16228
|
-
border: var(--border-width-default) solid var(--borders-general);
|
|
16229
|
-
border-radius: var(--border-radius-default);
|
|
16230
16299
|
}
|
|
16231
|
-
.zen-filters-search.zen-filters-popup__search-with-pills
|
|
16300
|
+
.zen-filters-search.zen-filters-popup__search-with-pills .zen-filters-search__selected {
|
|
16301
|
+
flex-shrink: 0;
|
|
16302
|
+
}
|
|
16303
|
+
.zen-filters-search--mobile {
|
|
16304
|
+
margin: 0;
|
|
16305
|
+
}
|
|
16306
|
+
.zen-filters-search__mobile-trigger {
|
|
16307
|
+
display: flex;
|
|
16308
|
+
align-items: center;
|
|
16309
|
+
justify-content: center;
|
|
16310
|
+
background: none;
|
|
16311
|
+
border: none;
|
|
16312
|
+
cursor: pointer;
|
|
16313
|
+
padding: 0 0.5rem;
|
|
16314
|
+
width: 2.5rem;
|
|
16315
|
+
height: 2.5rem;
|
|
16316
|
+
color: inherit;
|
|
16317
|
+
fill: currentcolor;
|
|
16318
|
+
flex-shrink: 0;
|
|
16319
|
+
}
|
|
16320
|
+
.zen-filters-search__mobile-trigger:focus-visible {
|
|
16321
|
+
outline: var(--border-width-default) solid var(--borders-form-field--active);
|
|
16322
|
+
border-radius: 999px;
|
|
16323
|
+
}
|
|
16324
|
+
.zen-filters-search__mobile-trigger-icon {
|
|
16232
16325
|
flex-shrink: 0;
|
|
16233
16326
|
}
|
|
16234
16327
|
.zen-side-panel-filters {
|
|
@@ -16426,16 +16519,12 @@ html:lang(ar) .zen-side-panel-filters__item-label--mobile {
|
|
|
16426
16519
|
}
|
|
16427
16520
|
}
|
|
16428
16521
|
.zen-filters-select-compact {
|
|
16429
|
-
padding: 0.25rem
|
|
16522
|
+
padding-block: 1rem 0.25rem;
|
|
16523
|
+
padding-inline: 1rem;
|
|
16430
16524
|
width: 100%;
|
|
16525
|
+
box-sizing: border-box;
|
|
16431
16526
|
overflow-inline: auto;
|
|
16432
|
-
-
|
|
16433
|
-
/* IE and Edge */
|
|
16434
|
-
scrollbar-width: none;
|
|
16435
|
-
/* Firefox */
|
|
16436
|
-
}
|
|
16437
|
-
.zen-filters-select-compact::-webkit-scrollbar {
|
|
16438
|
-
display: none;
|
|
16527
|
+
flex-shrink: 0;
|
|
16439
16528
|
}
|
|
16440
16529
|
.zen-filters-select-compact__list {
|
|
16441
16530
|
display: flex;
|
|
@@ -17561,7 +17650,7 @@ html:lang(ar) .zen-mobile-filter-control__counter {
|
|
|
17561
17650
|
}
|
|
17562
17651
|
.zen-page-header-component__actions--mobile-portal {
|
|
17563
17652
|
position: fixed;
|
|
17564
|
-
inset-block-end:
|
|
17653
|
+
inset-block-end: 4rem;
|
|
17565
17654
|
inset-inline-start: 50%;
|
|
17566
17655
|
transform: translateX(-50%);
|
|
17567
17656
|
border-radius: 8px;
|
|
@@ -26,8 +26,9 @@ export interface IInputAdornments {
|
|
|
26
26
|
ariaControls?: string;
|
|
27
27
|
ariaHaspopup?: boolean | "dialog" | "menu" | "grid" | "true" | "false" | "listbox" | "tree";
|
|
28
28
|
ariaExpanded?: boolean | "true" | "false";
|
|
29
|
+
autocomplete?: string;
|
|
29
30
|
}
|
|
30
31
|
export declare const InputAdornments: {
|
|
31
|
-
({ id, value, className, disabled, isError, maxLength, onChange, onKeyDown, onFocus, startAdornment, endAdornment, placeholder, inputType, autoFocus, name, onBlur, ref, ariaLabel, ariaDescribedby, role, ariaAutocomplete, ariaControls, ariaHaspopup, ariaExpanded }: IInputAdornments): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
({ id, value, className, disabled, isError, maxLength, onChange, onKeyDown, onFocus, startAdornment, endAdornment, placeholder, inputType, autoFocus, name, onBlur, ref, ariaLabel, ariaDescribedby, role, ariaAutocomplete, ariaControls, ariaHaspopup, ariaExpanded, autocomplete }: IInputAdornments): import("react/jsx-runtime").JSX.Element;
|
|
32
33
|
displayName: string;
|
|
33
34
|
};
|
|
@@ -7,7 +7,7 @@ const classNames_1 = require("../commonHelpers/classNames/classNames");
|
|
|
7
7
|
const textInputRaw_1 = require("../textInputRaw/textInputRaw");
|
|
8
8
|
const useDriveClassName_1 = require("../utils/theme/useDriveClassName");
|
|
9
9
|
const useMobileClassName_1 = require("../utils/theme/useMobileClassName");
|
|
10
|
-
const InputAdornments = ({ id, value, className = "", disabled, isError, maxLength, onChange, onKeyDown, onFocus, startAdornment, endAdornment, placeholder, inputType = "text", autoFocus, name, onBlur, ref, ariaLabel, ariaDescribedby, role, ariaAutocomplete, ariaControls, ariaHaspopup, ariaExpanded }) => {
|
|
10
|
+
const InputAdornments = ({ id, value, className = "", disabled, isError, maxLength, onChange, onKeyDown, onFocus, startAdornment, endAdornment, placeholder, inputType = "text", autoFocus, name, onBlur, ref, ariaLabel, ariaDescribedby, role, ariaAutocomplete, ariaControls, ariaHaspopup, ariaExpanded, autocomplete }) => {
|
|
11
11
|
const disabledClassName = disabled ? "zen-input-adornments--disabled" : "";
|
|
12
12
|
const driveComponentClass = (0, useDriveClassName_1.useDriveClassName)("zen-input-adornments");
|
|
13
13
|
const mobileComponentClass = (0, useMobileClassName_1.useMobileClassName)("zen-input-adornments");
|
|
@@ -25,7 +25,7 @@ const InputAdornments = ({ id, value, className = "", disabled, isError, maxLeng
|
|
|
25
25
|
!value ? "zen-input-adornments__wrapper--empty" : "",
|
|
26
26
|
className
|
|
27
27
|
]), [className, endAdornment, value]);
|
|
28
|
-
return ((0, jsx_runtime_1.jsxs)("div", { className: classes, children: [!!startAdornment && (0, jsx_runtime_1.jsx)("div", { className: "zen-input-adornments__adornment zen-input-adornments__adornment--start", children: startAdornment }), (0, jsx_runtime_1.jsx)("div", { className: wrapperClasses, children: (0, jsx_runtime_1.jsx)(textInputRaw_1.TextInputRaw, { name: name, onBlur: onBlur, ref: ref, id: id, value: value, maxLength: maxLength, isError: isError, placeholder: placeholder, onChange: onChange, onKeyDown: onKeyDown, onFocus: onFocus, disabled: disabled, type: inputType, autoFocus: autoFocus, ariaLabel: ariaLabel, ariaDescribedby: ariaDescribedby, role: role, ariaAutocomplete: ariaAutocomplete, ariaControls: ariaControls, ariaHaspopup: ariaHaspopup, ariaExpanded: ariaExpanded === undefined ? undefined : ariaExpanded === "true" || ariaExpanded === true, className: "zen-input-adornments__input zen-input-adornments__input--border-none" }) }), !!endAdornment && (0, jsx_runtime_1.jsx)("div", { className: "zen-input-adornments__adornment zen-input-adornments__adornment--end", children: endAdornment })] }));
|
|
28
|
+
return ((0, jsx_runtime_1.jsxs)("div", { className: classes, children: [!!startAdornment && (0, jsx_runtime_1.jsx)("div", { className: "zen-input-adornments__adornment zen-input-adornments__adornment--start", children: startAdornment }), (0, jsx_runtime_1.jsx)("div", { className: wrapperClasses, children: (0, jsx_runtime_1.jsx)(textInputRaw_1.TextInputRaw, { name: name, onBlur: onBlur, ref: ref, id: id, value: value, maxLength: maxLength, isError: isError, placeholder: placeholder, onChange: onChange, onKeyDown: onKeyDown, onFocus: onFocus, disabled: disabled, type: inputType, autoFocus: autoFocus, ariaLabel: ariaLabel, ariaDescribedby: ariaDescribedby, role: role, ariaAutocomplete: ariaAutocomplete, ariaControls: ariaControls, ariaHaspopup: ariaHaspopup, ariaExpanded: ariaExpanded === undefined ? undefined : ariaExpanded === "true" || ariaExpanded === true, autocomplete: autocomplete, className: "zen-input-adornments__input zen-input-adornments__input--border-none" }) }), !!endAdornment && (0, jsx_runtime_1.jsx)("div", { className: "zen-input-adornments__adornment zen-input-adornments__adornment--end", children: endAdornment })] }));
|
|
29
29
|
};
|
|
30
30
|
exports.InputAdornments = InputAdornments;
|
|
31
31
|
exports.InputAdornments.displayName = "InputAdornments";
|
|
@@ -120,12 +120,14 @@ const SearchInputRaw = props => {
|
|
|
120
120
|
autoFocus,
|
|
121
121
|
id,
|
|
122
122
|
onFocus,
|
|
123
|
+
onClear,
|
|
123
124
|
ref,
|
|
124
125
|
role,
|
|
125
126
|
ariaAutocomplete,
|
|
126
127
|
ariaControls,
|
|
127
128
|
ariaHaspopup,
|
|
128
|
-
ariaExpanded
|
|
129
|
+
ariaExpanded,
|
|
130
|
+
autocomplete = "off"
|
|
129
131
|
} = props;
|
|
130
132
|
const {
|
|
131
133
|
name,
|
|
@@ -159,6 +161,7 @@ const SearchInputRaw = props => {
|
|
|
159
161
|
const onClick = () => {
|
|
160
162
|
var _a;
|
|
161
163
|
onChange === null || onChange === void 0 ? void 0 : onChange("");
|
|
164
|
+
onClear === null || onClear === void 0 ? void 0 : onClear();
|
|
162
165
|
// Return focus to the input after clearing so keyboard users don't lose their place (WCAG 2.1 SC 2.1.1)
|
|
163
166
|
(_a = ref ? ref.current : innerRef.current) === null || _a === void 0 ? void 0 : _a.focus();
|
|
164
167
|
};
|
|
@@ -217,7 +220,8 @@ const SearchInputRaw = props => {
|
|
|
217
220
|
ariaAutocomplete: ariaAutocomplete,
|
|
218
221
|
ariaControls: ariaControls,
|
|
219
222
|
ariaHaspopup: ariaHaspopup,
|
|
220
|
-
ariaExpanded: ariaExpanded === undefined ? undefined : ariaExpanded === "true" || ariaExpanded === true
|
|
223
|
+
ariaExpanded: ariaExpanded === undefined ? undefined : ariaExpanded === "true" || ariaExpanded === true,
|
|
224
|
+
autocomplete: autocomplete
|
|
221
225
|
})
|
|
222
226
|
}));
|
|
223
227
|
};
|
|
@@ -8,6 +8,8 @@ export interface ISearchInputRawBase {
|
|
|
8
8
|
placeholder?: string;
|
|
9
9
|
ariaLabel?: string;
|
|
10
10
|
closeButtonTitle?: string;
|
|
11
|
+
/** Called when the clear (X) button is clicked, in addition to clearing the value via onChange */
|
|
12
|
+
onClear?: () => void;
|
|
11
13
|
isError?: boolean;
|
|
12
14
|
isReadOnly?: boolean;
|
|
13
15
|
maxLength?: number;
|
|
@@ -26,6 +28,8 @@ export interface ISearchInputRawBase {
|
|
|
26
28
|
ariaControls?: string;
|
|
27
29
|
ariaHaspopup?: boolean | "dialog" | "menu" | "grid" | "true" | "false" | "listbox" | "tree";
|
|
28
30
|
ariaExpanded?: boolean | "true" | "false";
|
|
31
|
+
/** HTML autocomplete attribute for the underlying input. Defaults to "off" to suppress browser autofill. */
|
|
32
|
+
autocomplete?: string;
|
|
29
33
|
}
|
|
30
34
|
export interface ISearchInputRawDefault extends ISearchInputRawBase {
|
|
31
35
|
value: string;
|
|
@@ -252,6 +252,7 @@
|
|
|
252
252
|
"value changes in the range from {MIN} to {MAX}.": "value changes in the range from {MIN} to {MAX}.",
|
|
253
253
|
"Error generating chart narrative for dataset": "Error generating chart narrative for dataset",
|
|
254
254
|
"Chart data table and visualization": "Chart data table and visualization",
|
|
255
|
+
"Find in page": "Find in page",
|
|
255
256
|
"Search page": "Search page",
|
|
256
257
|
"Search by": "Search by",
|
|
257
258
|
"Save": "Save",
|
|
@@ -93,7 +93,9 @@ const calculatePosition = (triggerRef, popupRef, paddingX, paddingY, inline, ali
|
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
}
|
|
96
|
-
else if (!isTopsideAlignment &&
|
|
96
|
+
else if (!isTopsideAlignment &&
|
|
97
|
+
triggerRect.y + triggerRect.height + popupRect.height > (zen_1.zen.innerHeight || 0) &&
|
|
98
|
+
position.height === undefined) {
|
|
97
99
|
const newTopPosition = (zen_1.zen.innerHeight || 0) + scrollTop - popupRect.height;
|
|
98
100
|
position.top = newTopPosition < 0 ? 0 : newTopPosition;
|
|
99
101
|
}
|
|
@@ -46,6 +46,11 @@ const getFormatFromDateRange = (minDate, maxDate, ticks) => {
|
|
|
46
46
|
};
|
|
47
47
|
export const getDefaultOptions = (yAxis, xAxis, isTimedData, ticks, isDark, translate, isRtl = false) => {
|
|
48
48
|
const time = getFormatFromDateRange(xAxis.minDate, xAxis.maxDate, ticks);
|
|
49
|
+
// Empty data yields inverted sentinel bounds (min > max); pinning those would make chart.js
|
|
50
|
+
// span ~8.6e15 ms and crash. Only pin a valid range, else let it auto-scale.
|
|
51
|
+
const xMin = Date.parse(xAxis.minDate);
|
|
52
|
+
const xMax = Date.parse(xAxis.maxDate);
|
|
53
|
+
const hasValidTimeRange = isTimedData && Number.isFinite(xMin) && Number.isFinite(xMax) && xMin <= xMax;
|
|
49
54
|
const textColor = isDark ? "#C0CCD8" : "#4E677E";
|
|
50
55
|
const primaryYPosition = isRtl ? "right" : "left";
|
|
51
56
|
const secondaryYPosition = isRtl ? "left" : "right";
|
|
@@ -67,8 +72,8 @@ export const getDefaultOptions = (yAxis, xAxis, isTimedData, ticks, isDark, tran
|
|
|
67
72
|
}
|
|
68
73
|
}
|
|
69
74
|
: undefined,
|
|
70
|
-
min:
|
|
71
|
-
max:
|
|
75
|
+
min: hasValidTimeRange ? xMin : undefined,
|
|
76
|
+
max: hasValidTimeRange ? xMax : undefined,
|
|
72
77
|
ticks: isTimedData
|
|
73
78
|
? {
|
|
74
79
|
autoSkip: false,
|
|
@@ -49,7 +49,7 @@ export const usePillSize = ({ size, iconPosition, onClose, hasContent, initialTi
|
|
|
49
49
|
}
|
|
50
50
|
}, []);
|
|
51
51
|
useResize(() => {
|
|
52
|
-
if (isFixedSize ||
|
|
52
|
+
if (isFixedSize || !hasIcon || !isClosable) {
|
|
53
53
|
return;
|
|
54
54
|
}
|
|
55
55
|
hidePillContent();
|
|
@@ -58,7 +58,7 @@ export const usePillSize = ({ size, iconPosition, onClose, hasContent, initialTi
|
|
|
58
58
|
if (initialTitle) {
|
|
59
59
|
return;
|
|
60
60
|
}
|
|
61
|
-
if (
|
|
61
|
+
if (!hasIcon || !isClosable) {
|
|
62
62
|
return;
|
|
63
63
|
}
|
|
64
64
|
hidePillContent();
|
|
@@ -3,6 +3,7 @@ import { TTrapFocus } from "../absolute/absolute";
|
|
|
3
3
|
import "./controlledPopup.less";
|
|
4
4
|
import { IZenComponentProps } from "../commonHelpers/zenComponent";
|
|
5
5
|
import { TAlignment as TAlignmentAbsolute } from "../absolute/absolute";
|
|
6
|
+
import { IAlignment } from "../utils/positioningUtils/alignments";
|
|
6
7
|
/**
|
|
7
8
|
* @deprecated - please use {@link TAlignmentAbsolute|TAlignment} interface from the absolute component
|
|
8
9
|
*/
|
|
@@ -28,5 +29,7 @@ export interface IControlledPopup extends IZenComponentProps {
|
|
|
28
29
|
preventAttributesAutoSet?: boolean;
|
|
29
30
|
/** Whether to focus the first focusable element when popup opens. Default: true */
|
|
30
31
|
focusOnOpen?: boolean;
|
|
32
|
+
/** Override the default alignment calculation functions. */
|
|
33
|
+
alignmentsFn?: IAlignment;
|
|
31
34
|
}
|
|
32
|
-
export declare const ControlledPopup: ({ isOpen, id, paddingX, paddingY, triggerRef, className, children, alignment, inline, onOpenChange, useTrapFocusWithTrigger, shouldHoldScroll, ariaLabel, ariaLabelledby, recalculateOnScroll, closeOnScroll, preventAttributesAutoSet, focusOnOpen, role }: IControlledPopup) => import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
export declare const ControlledPopup: ({ isOpen, id, paddingX, paddingY, triggerRef, className, children, alignment, inline, onOpenChange, useTrapFocusWithTrigger, shouldHoldScroll, ariaLabel, ariaLabelledby, recalculateOnScroll, closeOnScroll, preventAttributesAutoSet, focusOnOpen, alignmentsFn, role }: IControlledPopup) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -4,7 +4,7 @@ import { Absolute } from "../absolute/absolute";
|
|
|
4
4
|
import { classNames } from "../commonHelpers/classNames/classNames";
|
|
5
5
|
import { useClientReady } from "../commonHelpers/hooks/useClientReady";
|
|
6
6
|
import { useRTLAlignment } from "../utils/localization/useRTLAlignment";
|
|
7
|
-
export const ControlledPopup = ({ isOpen, id, paddingX, paddingY, triggerRef, className, children, alignment, inline, onOpenChange, useTrapFocusWithTrigger, shouldHoldScroll, ariaLabel, ariaLabelledby, recalculateOnScroll, closeOnScroll, preventAttributesAutoSet, focusOnOpen, role = "dialog" }) => {
|
|
7
|
+
export const ControlledPopup = ({ isOpen, id, paddingX, paddingY, triggerRef, className, children, alignment, inline, onOpenChange, useTrapFocusWithTrigger, shouldHoldScroll, ariaLabel, ariaLabelledby, recalculateOnScroll, closeOnScroll, preventAttributesAutoSet, focusOnOpen, alignmentsFn, role = "dialog" }) => {
|
|
8
8
|
const autoId = useId();
|
|
9
9
|
const popupId = id || autoId;
|
|
10
10
|
const isClientReady = useClientReady();
|
|
@@ -23,5 +23,5 @@ export const ControlledPopup = ({ isOpen, id, paddingX, paddingY, triggerRef, cl
|
|
|
23
23
|
triggerRef.current.setAttribute("aria-expanded", isOpen ? "true" : "false");
|
|
24
24
|
triggerRef.current.setAttribute("aria-controls", popupId);
|
|
25
25
|
}, [triggerRef, isOpen, popupId, preventAttributesAutoSet, isClientReady]);
|
|
26
|
-
return (_jsx(Absolute, Object.assign({ triggerRef: triggerRef, alignment: rtlAlignment, id: popupId, isOpen: isOpen, className: classNames(["zen-popup", className ? className : ""]), paddingX: paddingX, paddingY: paddingY, inline: inline, onOpenChange: onOpenChange, useTrapFocusWithTrigger: useTrapFocusWithTrigger, shouldHoldScroll: shouldHoldScroll }, (role !== false && typeof role === "string" ? { role } : {}), (role !== false && ariaLabel ? { ariaLabel } : {}), (role !== false && ariaLabelledby ? { ariaLabelledby } : {}), { recalculateOnScroll: recalculateOnScroll, closeOnScroll: closeOnScroll, focusOnOpen: focusOnOpen, children: children })));
|
|
26
|
+
return (_jsx(Absolute, Object.assign({ triggerRef: triggerRef, alignment: rtlAlignment, id: popupId, isOpen: isOpen, className: classNames(["zen-popup", className ? className : ""]), paddingX: paddingX, paddingY: paddingY, inline: inline, onOpenChange: onOpenChange, useTrapFocusWithTrigger: useTrapFocusWithTrigger, shouldHoldScroll: shouldHoldScroll }, (role !== false && typeof role === "string" ? { role } : {}), (role !== false && ariaLabel ? { ariaLabel } : {}), (role !== false && ariaLabelledby ? { ariaLabelledby } : {}), { recalculateOnScroll: recalculateOnScroll, closeOnScroll: closeOnScroll, focusOnOpen: focusOnOpen, alignmentsFn: alignmentsFn, children: children })));
|
|
27
27
|
};
|