Update
This commit is contained in:
File diff suppressed because one or more lines are too long
+122
-32
@@ -1,6 +1,11 @@
|
||||
.ui-access-rights-v2 {
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section:last-child .ui-access-rights-v2-section-container {
|
||||
border-bottom-left-radius: var(--ui-border-radius-xl);
|
||||
border-bottom-right-radius: var(--ui-border-radius-xl);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-block {
|
||||
position: relative;
|
||||
pointer-events: none;
|
||||
@@ -30,6 +35,14 @@
|
||||
font-size: var(--ui-font-size-lg);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2--head-section::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
background: var(--ui-color-gray-05) ;
|
||||
z-index: -1;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2--head-section .ui-access-rights-v2-column-item-text {
|
||||
font-size: var(--ui-font-size-lg);
|
||||
}
|
||||
@@ -45,8 +58,8 @@
|
||||
|
||||
.ui-access-rights-v2--head-section .ui-access-rights-v2-section-container {
|
||||
height: 82px;
|
||||
border-top-right-radius: var(--ui-border-radius-xs);
|
||||
border-top-left-radius: var(--ui-border-radius-xs);
|
||||
border-top-right-radius: var(--ui-border-radius-xl);
|
||||
border-top-left-radius: var(--ui-border-radius-xl);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-head {
|
||||
@@ -174,7 +187,7 @@
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
font-size: var(--ui-font-size-sm);
|
||||
color: var(--ui-color-palette-black-base);
|
||||
color: var(--ui-color-base-90);
|
||||
line-height: var(--ui-font-line-height-2xs);
|
||||
cursor: default;
|
||||
}
|
||||
@@ -188,6 +201,8 @@
|
||||
.ui-access-rights-v2-column-item-title-block {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title-icon {
|
||||
@@ -206,8 +221,8 @@
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .--plus-in-circle, .ui-access-rights-v2-column-item-title .--minus-in-circle {
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-gray-50);
|
||||
.ui-access-rights-v2-column-item-title .--o-circle-plus, .ui-access-rights-v2-column-item-title .--o-circle-minus {
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-gray-30);
|
||||
--ui-icon-set__icon-size: 18px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
@@ -217,14 +232,25 @@
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .ui-access-rights-v2-hint-container {
|
||||
display: inline;
|
||||
vertical-align: middle;
|
||||
position: relative;
|
||||
top: 2px;
|
||||
top: 1px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-hint-container::before {
|
||||
content: "\00a0";
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .ui-hint {
|
||||
line-height: normal;
|
||||
width: 13px;
|
||||
height: 13px;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-hint-container .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 16px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .ui-hint-icon {
|
||||
@@ -249,7 +275,7 @@
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-role-cell {
|
||||
padding: 10px;
|
||||
padding: 16px 10px 10px 10px;
|
||||
height: calc(100% - 20px);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
@@ -269,13 +295,15 @@
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-right: -16px; /* because of menu */
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-role-input,
|
||||
.ui-access-rights-v2-role-value {
|
||||
font-size: var(--ui-font-size-lg);
|
||||
line-height: var(--ui-font-line-height-3xs);
|
||||
color: var(--ui-color-gray-90);
|
||||
font-weight: var(--ui-font-weight-normal);
|
||||
line-height: 20px;
|
||||
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
@@ -306,11 +334,14 @@
|
||||
.ui-access-rights-v2-members {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
border: var(--ui-border-width-thin) solid #525C6929;
|
||||
border-radius: var(--ui-border-radius-pill);
|
||||
padding: 4px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-air-template {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item {
|
||||
display: inline-block;
|
||||
margin-left: -9px;
|
||||
@@ -328,15 +359,18 @@
|
||||
.ui-access-rights-v2-members-item-add {
|
||||
height: 24px;
|
||||
width: 24px;
|
||||
border: none;
|
||||
background: #fff;
|
||||
box-shadow: 0 2px 4px 0 rgba(0,0,0,.14);
|
||||
border-radius: 100%;
|
||||
cursor: pointer;
|
||||
border: 1px solid var(--ui-color-base-7)
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item-add:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item-add .ui-icon-set {
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-blue-50);
|
||||
--ui-icon-set__icon-color: var(--ui-color-accent-main-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item-add:hover .ui-icon-set {
|
||||
@@ -438,6 +472,12 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
overflow: visible;
|
||||
text-overflow: clip;
|
||||
word-break: break-word;
|
||||
|
||||
width: 100%;
|
||||
justify-content: space-between;
|
||||
|
||||
font-weight: 400;
|
||||
font-size: var(--ui-font-size-sm);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-text-center {
|
||||
@@ -456,13 +496,23 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
|
||||
.ui-access-rights-v2-icon-more {
|
||||
--ui-icon-set__icon-size: 16px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-base-5);
|
||||
opacity: var(--ui-opacity-40);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search {
|
||||
max-width: 290px;
|
||||
--ui-field-size: 34px
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search-input {
|
||||
background-color: #F6F7F9;
|
||||
border: none;
|
||||
border-radius: var(--ui-border-radius-sm);
|
||||
border: 1px solid var(--ui-color-bg-content-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search .ui-ctl-element:hover, .ui-access-rights-v2-search .ui-ctl-element:focus {
|
||||
border-color: var(--ui-color-bg-content-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search-input:focus {
|
||||
@@ -486,8 +536,7 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-role-add .ui-btn:hover:not(.ui-btn-disabled) {
|
||||
border-color: var(--ui-color-palette-blue-30);
|
||||
background: unset;
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-role-add .ui-btn.ui-btn-disabled {
|
||||
@@ -497,6 +546,19 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
.ui-access-rights-v2-header-role-add .ui-icon-set {
|
||||
--ui-icon-set__icon-color: var(--ui-color-base-50);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search-icon {
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
display: block;
|
||||
width: 22px;
|
||||
height: calc(var(--ui-field-size) - 2px);
|
||||
right: 12px;
|
||||
cursor: pointer;
|
||||
|
||||
--ui-icon-set__icon-size: 20px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-base-5);
|
||||
}
|
||||
.ui-access-rights-v2-column-item.ui-access-rights-v2-header-roles-control {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
@@ -523,10 +585,18 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
align-items: center;
|
||||
cursor: pointer;
|
||||
font-size: var(--ui-font-size-sm);
|
||||
border: 1px solid var(--design-outline-default-design-outline-stroke, var(--ui-color-base-7));
|
||||
border-radius: var(--ui-border-radius-pill);
|
||||
box-shadow: var(--ui-shadow-bottom-s);
|
||||
padding: 5px 10px 5px 10px;
|
||||
border: var(--ui-border-width-thin) solid rgba(var(--ui-color-palette-black-solid-rgb), 0.07)
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-counter:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-counter .ui-icon-set {
|
||||
--ui-icon-set__icon-color: var(--ui-color-accent-main-primary);
|
||||
margin-right: 2px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-chevron {
|
||||
@@ -546,6 +616,27 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-expander-button {
|
||||
height: 24px;
|
||||
width: 24px;
|
||||
border: 1px solid var(--design-outline-default-design-outline-stroke, var(--ui-color-base-7));
|
||||
border-radius: var(--ui-border-radius-xs);
|
||||
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
margin-left: 4px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-expander-button:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-expander-button .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 18px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -570,23 +661,22 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
.ui-access-rights-v2-section-header-expander {
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
background-color: var(--ui-color-palette-white-base);
|
||||
border: 1px solid var(--ui-color-base-7);
|
||||
border-radius: var(--ui-border-radius-circle);
|
||||
box-shadow: var(--ui-shadow-bottom-s);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin-right: 9px;
|
||||
background-color: var(--ui-color-bg-content-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header-expander:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header-expander .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 12px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-gray-40);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header.--expanded .ui-access-rights-v2-section-header-expander .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 12px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-black-base);
|
||||
--ui-icon-set__icon-color: var(--ui-color-accent-main-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header-icon {
|
||||
@@ -603,16 +693,16 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-title {
|
||||
color: var(--ui-color-palette-gray-80);
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
max-width: 70%;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header.--expanded .ui-access-rights-v2-section-title {
|
||||
color: var(--ui-color-palette-black-base);
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-subtitle {
|
||||
color: var(--ui-color-palette-gray-70);
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
margin-left: 3px;
|
||||
max-width: 200px;
|
||||
}
|
||||
|
||||
+97
-66
@@ -96,6 +96,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
return babelHelpers.classPrivateFieldLooseBase(this, _cache)[_cache].remember(`hint-${appGuid}`, () => {
|
||||
return BX.UI.Hint.createInstance({
|
||||
id: `ui-access-rights-v2-hint-${appGuid}`,
|
||||
classNameIcon: 'ui-icon-set --o-question',
|
||||
popupParameters: {
|
||||
className: 'ui-access-rights-v2-popup-pointer-events ui-hint-popup',
|
||||
autoHide: true,
|
||||
@@ -173,7 +174,8 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
options: state => state.application.options,
|
||||
addUserGroupsProviderTab: state => state.application.options.additionalMembersParams.addUserGroupsProviderTab,
|
||||
addProjectsProviderTab: state => state.application.options.additionalMembersParams.addProjectsProviderTab,
|
||||
addStructureTeamsProviderTab: state => state.application.options.additionalMembersParams.addStructureTeamsProviderTab
|
||||
addStructureTeamsProviderTab: state => state.application.options.additionalMembersParams.addStructureTeamsProviderTab,
|
||||
addStructureRolesProviderTab: state => state.application.options.additionalMembersParams.addStructureRolesProviderTab
|
||||
})
|
||||
},
|
||||
mounted() {
|
||||
@@ -218,6 +220,9 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
const groupId = match ? match[1] : null;
|
||||
return ['site-groups', groupId];
|
||||
}
|
||||
if (/^(?:ATD|ATE|ATT|AD|AE|AT)[1-9]\d*$/.test(accessCode)) {
|
||||
return ['structure-role', accessCode];
|
||||
}
|
||||
if (accessCode.at(0) === 'A') {
|
||||
return ['user-groups', accessCode];
|
||||
}
|
||||
@@ -294,6 +299,9 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
if (entityId === 'user-groups') {
|
||||
return item.id;
|
||||
}
|
||||
if (entityId === 'structure-role') {
|
||||
return item.id;
|
||||
}
|
||||
if (entityId === 'project-access-codes') {
|
||||
return item.id;
|
||||
}
|
||||
@@ -315,6 +323,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
return 'structureteams';
|
||||
case 'site-groups':
|
||||
case 'user-groups':
|
||||
case 'structure-role':
|
||||
return 'usergroups';
|
||||
default:
|
||||
return '';
|
||||
@@ -341,14 +350,24 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
dynamicLoad: true,
|
||||
dynamicSearch: true
|
||||
}];
|
||||
if (this.addStructureRolesProviderTab) {
|
||||
entities.push({
|
||||
id: 'structure-role',
|
||||
options: {
|
||||
includedNodeEntityTypes: ['team', 'department']
|
||||
},
|
||||
dynamicLoad: true,
|
||||
dynamicSearch: true
|
||||
});
|
||||
}
|
||||
if (this.addStructureTeamsProviderTab) {
|
||||
entities.push({
|
||||
id: 'structure-node',
|
||||
options: {
|
||||
selectMode: 'usersAndDepartments',
|
||||
includedNodeEntityTypes: ['team'],
|
||||
allowSelectRootDepartment: true,
|
||||
allowFlatDepartments: true,
|
||||
includedNodeEntityTypes: ['team'],
|
||||
useMultipleTabs: true,
|
||||
visual: {
|
||||
avatarMode: 'node',
|
||||
@@ -472,7 +491,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
'--has-siblings': userGroup.members.size > 0,
|
||||
}"
|
||||
>
|
||||
<div class="ui-icon-set --plus-30"></div>
|
||||
<div class="ui-icon-set --plus-m"></div>
|
||||
</div>
|
||||
<Selector
|
||||
v-if="isSelectorShown"
|
||||
@@ -506,7 +525,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
computed: {
|
||||
RichMenuItemIcon: () => ui_vue3_components_richMenu.RichMenuItemIcon,
|
||||
...ui_vue3_vuex.mapState({
|
||||
isSaving: state => state.application.isSaving,
|
||||
isProgress: state => state.application.isProgress,
|
||||
guid: state => state.application.guid,
|
||||
maxVisibleUserGroups: state => state.application.options.maxVisibleUserGroups
|
||||
}),
|
||||
@@ -594,6 +613,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
}
|
||||
}
|
||||
}), new ui_buttons.CancelButton({
|
||||
text: this.$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_CANCEL'),
|
||||
size: ui_buttons.ButtonSize.SMALL,
|
||||
events: {
|
||||
click: () => {
|
||||
@@ -605,7 +625,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
popup.show();
|
||||
},
|
||||
showActionsMenu() {
|
||||
if (!this.isSaving) {
|
||||
if (!this.isProgress) {
|
||||
this.isPopupShown = true;
|
||||
}
|
||||
},
|
||||
@@ -643,7 +663,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
<div ref="container" class='ui-access-rights-v2-role'>
|
||||
<div class="ui-access-rights-v2-role-value-container">
|
||||
<input
|
||||
v-if="isEdit && !isSaving"
|
||||
v-if="isEdit && !isProgress"
|
||||
ref="input"
|
||||
type='text'
|
||||
class='ui-access-rights-v2-role-input'
|
||||
@@ -655,7 +675,8 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
</div>
|
||||
<div
|
||||
ref="menu"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more"
|
||||
style="position: absolute; right: 11px; top: 5px;"
|
||||
@click="showActionsMenu"
|
||||
>
|
||||
<RichMenuPopup v-if="isPopupShown" @close="isPopupShown = false" :popup-options="{bindElement: $refs.menu}">
|
||||
@@ -898,7 +919,8 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
<div>{{ $Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_ROLES') }}</div>
|
||||
<div
|
||||
ref="configure"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more"
|
||||
style="position: absolute; right: 11px; top: 5px;"
|
||||
@click="isPopupShown = true"
|
||||
>
|
||||
<RichMenuPopup v-if="isPopupShown" @close="isPopupShown = false" :popup-options="{bindElement: $refs.configure}">
|
||||
@@ -945,21 +967,25 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
class="ui-access-rights-v2-header-roles-control-counter"
|
||||
@click="toggleViewDialog($refs.counter)"
|
||||
>
|
||||
<div class="ui-icon-set --opened-eye" style="--ui-icon-set__icon-size: 15px;"></div>
|
||||
<div class="ui-icon-set --o-observer" style="--ui-icon-set__icon-size: 18px;"></div>
|
||||
<span v-html="shownGroupsCounter"></span>
|
||||
<div class="ui-icon-set --chevron-down ui-access-rights-v2-header-roles-control-chevron"></div>
|
||||
</div>
|
||||
<div class="ui-access-rights-v2-header-roles-control-expander">
|
||||
<div
|
||||
class="ui-icon-set --collapse"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/collapseAllSections')"
|
||||
></div>
|
||||
<div
|
||||
class="ui-icon-set --expand-1"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_EXPAND_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/expandAllSections')"
|
||||
></div>
|
||||
<div class="ui-access-rights-v2-header-roles-control-expander-button">
|
||||
<div
|
||||
class="ui-icon-set --collapse"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/collapseAllSections')"
|
||||
></div>
|
||||
</div>
|
||||
<div class="ui-access-rights-v2-header-roles-control-expander-button">
|
||||
<div
|
||||
class="ui-icon-set --expand-1"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_EXPAND_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/expandAllSections')"
|
||||
></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</CellLayout>
|
||||
@@ -1179,14 +1205,19 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
}
|
||||
},
|
||||
template: `
|
||||
<div class="ui-ctl ui-ctl-after-icon ui-ctl-w100 ui-access-rights-v2-search">
|
||||
<div
|
||||
class="ui-ctl ui-ctl-after-icon ui-access-rights-v2-search">
|
||||
<input
|
||||
type="text"
|
||||
class="ui-ctl-element ui-ctl-textbox ui-access-rights-v2-search-input"
|
||||
:placeholder="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_SEARCH_PLACEHOLDER')"
|
||||
v-model="searchQuery"
|
||||
ref="searchInput"
|
||||
>
|
||||
<a class="ui-ctl-after ui-ctl-icon-search ui-access-rights-v2-search-icon"></a>
|
||||
<a
|
||||
class="ui-icon-set --o-search ui-access-rights-v2-search-icon"
|
||||
@click="this.$refs.searchInput.focus()"
|
||||
></a>
|
||||
</div>
|
||||
`
|
||||
};
|
||||
@@ -2033,7 +2064,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
<CellLayout class="ui-access-rights-v2-menu-cell" style="cursor: pointer" @click="toggleMenu">
|
||||
<div
|
||||
ref="icon"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more"
|
||||
>
|
||||
<RichMenuPopup
|
||||
v-if="isMenuShown"
|
||||
@@ -2554,7 +2585,8 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
const cancelButton = new ui_buttons.CancelButton({
|
||||
onclick: () => {
|
||||
this.$emit('close');
|
||||
}
|
||||
},
|
||||
text: this.$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_CANCEL')
|
||||
});
|
||||
cancelButton.renderTo(this.$refs['button-container']);
|
||||
});
|
||||
@@ -3757,8 +3789,8 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
v-if="right.groupHead"
|
||||
class="ui-icon-set"
|
||||
:class="{
|
||||
'--minus-in-circle': right.isGroupExpanded,
|
||||
'--plus-in-circle': !right.isGroupExpanded,
|
||||
'--o-circle-minus': right.isGroupExpanded,
|
||||
'--o-circle-plus': !right.isGroupExpanded,
|
||||
}"
|
||||
></span>
|
||||
<div
|
||||
@@ -3772,15 +3804,13 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
class="ui-access-rights-v2-column-item-title-link ui-access-rights-v2-text-ellipsis"
|
||||
@click="onRightClick"
|
||||
>
|
||||
{{ right.title }}
|
||||
<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
{{ right.title }}<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
</span>
|
||||
<span
|
||||
v-else
|
||||
class="ui-access-rights-v2-text-wrap"
|
||||
>
|
||||
{{ right.title }}
|
||||
<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
{{ right.title }}<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
</span>
|
||||
<span
|
||||
v-if="right.subtitle"
|
||||
@@ -3790,7 +3820,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
</div>
|
||||
<div
|
||||
ref="icon"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more ui-access-rights-v2-title-column-menu"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more ui-access-rights-v2-title-column-menu"
|
||||
@click="toggleMenu"
|
||||
>
|
||||
<RichMenuPopup
|
||||
@@ -3959,7 +3989,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
loader: null,
|
||||
computed: {
|
||||
...ui_vue3_vuex.mapState({
|
||||
isSaving: state => state.application.isSaving,
|
||||
isProgress: state => state.application.isProgress,
|
||||
guid: state => state.application.guid,
|
||||
searchContainerSelector: state => state.application.options.searchContainerSelector
|
||||
}),
|
||||
@@ -4071,7 +4101,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
<SearchBox/>
|
||||
</Teleport>
|
||||
<div ref="container" class='ui-access-rights-v2' :class="{
|
||||
'ui-access-rights-v2-block': isSaving,
|
||||
'ui-access-rights-v2-block': isProgress,
|
||||
}">
|
||||
<Header :user-groups="shownUserGroups"/>
|
||||
<Section
|
||||
@@ -4153,25 +4183,6 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
// 'event' field is provided by AnalyticsManager
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _isEnabled)[_isEnabled] = Object.hasOwn(babelHelpers.classPrivateFieldLooseBase(this, _data)[_data], 'tool') && Object.hasOwn(babelHelpers.classPrivateFieldLooseBase(this, _data)[_data], 'category');
|
||||
}
|
||||
onSaveAttempt() {
|
||||
if (!babelHelpers.classPrivateFieldLooseBase(this, _isEnabled)[_isEnabled]) {
|
||||
return;
|
||||
}
|
||||
const {
|
||||
createdRoles,
|
||||
editedRoles,
|
||||
deletedRoles
|
||||
} = babelHelpers.classPrivateFieldLooseBase(this, _analyzeRoles)[_analyzeRoles]();
|
||||
for (let i = 0; i < createdRoles; i++) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _registerRoleCreateEvent)[_registerRoleCreateEvent]('attempt');
|
||||
}
|
||||
for (let i = 0; i < editedRoles; i++) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _registerRoleEditEvent)[_registerRoleEditEvent]('attempt');
|
||||
}
|
||||
for (let i = 0; i < deletedRoles; i++) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _registerRoleDeleteEvent)[_registerRoleDeleteEvent]('attempt');
|
||||
}
|
||||
}
|
||||
onSaveSuccess() {
|
||||
if (!babelHelpers.classPrivateFieldLooseBase(this, _isEnabled)[_isEnabled]) {
|
||||
return;
|
||||
@@ -4343,7 +4354,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
return {
|
||||
options: babelHelpers.classPrivateFieldLooseBase(this, _options)[_options],
|
||||
guid: babelHelpers.classPrivateFieldLooseBase(this, _guid)[_guid],
|
||||
isSaving: false
|
||||
isProgress: false
|
||||
};
|
||||
}
|
||||
getGetters() {
|
||||
@@ -4361,9 +4372,9 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
}
|
||||
getMutations() {
|
||||
return {
|
||||
setSaving: (state, isSaving) => {
|
||||
setProgress: (state, isProgress) => {
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
state.isSaving = Boolean(isSaving);
|
||||
state.isProgress = Boolean(isProgress);
|
||||
}
|
||||
};
|
||||
}
|
||||
@@ -5236,7 +5247,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
}
|
||||
// noinspection OverlyComplexFunctionJS
|
||||
transform(externalSource) {
|
||||
var _externalSource$addit, _externalSource$addit2, _externalSource$addit3, _externalSource$addit4, _externalSource$addit5, _externalSource$addit6;
|
||||
var _externalSource$addit, _externalSource$addit2, _externalSource$addit3, _externalSource$addit4, _externalSource$addit5, _externalSource$addit6, _externalSource$addit7, _externalSource$addit8;
|
||||
// freeze tells vue that we don't need reactivity on this state
|
||||
// and prevents accidental modification as well
|
||||
return babelHelpers.classPrivateFieldLooseBase(this, _deepFreeze)[_deepFreeze]({
|
||||
@@ -5251,11 +5262,13 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
additionalMembersParams: main_core.Type.isPlainObject(externalSource.additionalMembersParams) ? {
|
||||
addUserGroupsProviderTab: Boolean((_externalSource$addit = (_externalSource$addit2 = externalSource.additionalMembersParams) == null ? void 0 : _externalSource$addit2.addUserGroupsProviderTab) != null ? _externalSource$addit : false),
|
||||
addProjectsProviderTab: Boolean((_externalSource$addit3 = (_externalSource$addit4 = externalSource.additionalMembersParams) == null ? void 0 : _externalSource$addit4.addProjectsProviderTab) != null ? _externalSource$addit3 : true),
|
||||
addStructureTeamsProviderTab: Boolean((_externalSource$addit5 = (_externalSource$addit6 = externalSource.additionalMembersParams) == null ? void 0 : _externalSource$addit6.addStructureTeamsProviderTab) != null ? _externalSource$addit5 : false)
|
||||
addStructureTeamsProviderTab: Boolean((_externalSource$addit5 = (_externalSource$addit6 = externalSource.additionalMembersParams) == null ? void 0 : _externalSource$addit6.addStructureTeamsProviderTab) != null ? _externalSource$addit5 : false),
|
||||
addStructureRolesProviderTab: Boolean((_externalSource$addit7 = (_externalSource$addit8 = externalSource.additionalMembersParams) == null ? void 0 : _externalSource$addit8.addStructureRolesProviderTab) != null ? _externalSource$addit7 : false)
|
||||
} : {
|
||||
addUserGroupsProviderTab: false,
|
||||
addProjectsProviderTab: true,
|
||||
addStructureTeamsProviderTab: false
|
||||
addStructureTeamsProviderTab: false,
|
||||
addStructureRolesProviderTab: false
|
||||
},
|
||||
isSaveAccessRightsList: main_core.Type.isBoolean(externalSource.isSaveAccessRightsList) ? externalSource.isSaveAccessRightsList : false
|
||||
});
|
||||
@@ -5431,6 +5444,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
var _userGroupsModel = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("userGroupsModel");
|
||||
var _accessRightsModel = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("accessRightsModel");
|
||||
var _analyticsManager = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("analyticsManager");
|
||||
var _confirmationPopup = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("confirmationPopup");
|
||||
var _bindEvents = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("bindEvents");
|
||||
var _unbindEvents = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("unbindEvents");
|
||||
var _tryShowFeaturePromoter = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("tryShowFeaturePromoter");
|
||||
@@ -5516,6 +5530,10 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
writable: true,
|
||||
value: void 0
|
||||
});
|
||||
Object.defineProperty(this, _confirmationPopup, {
|
||||
writable: true,
|
||||
value: null
|
||||
});
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _options$1)[_options$1] = options || {};
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _renderTo)[_renderTo] = babelHelpers.classPrivateFieldLooseBase(this, _options$1)[_options$1].renderTo;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _buttonPanel)[_buttonPanel] = BX.UI.ButtonPanel || null;
|
||||
@@ -5548,12 +5566,11 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
}
|
||||
sendActionRequest() {
|
||||
return new Promise((resolve, reject) => {
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].state.application.isSaving || !babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].getters['application/isModified']) {
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].state.application.isProgress || !babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].getters['application/isModified']) {
|
||||
resolve();
|
||||
return;
|
||||
}
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].commit('application/setSaving', true);
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _analyticsManager)[_analyticsManager].onSaveAttempt();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].commit('application/setProgress', true);
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _runSaveAjaxRequest)[_runSaveAjaxRequest]().then(({
|
||||
userGroups,
|
||||
accessRights
|
||||
@@ -5590,7 +5607,7 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
var _babelHelpers$classPr;
|
||||
const waitContainer = (_babelHelpers$classPr = babelHelpers.classPrivateFieldLooseBase(this, _buttonPanel)[_buttonPanel]) == null ? void 0 : _babelHelpers$classPr.getContainer().querySelector('.ui-btn-wait');
|
||||
main_core.Dom.removeClass(waitContainer, 'ui-btn-wait');
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].commit('application/setSaving', false);
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].commit('application/setProgress', false);
|
||||
resolve();
|
||||
});
|
||||
});
|
||||
@@ -5636,6 +5653,11 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _buttonPanel)[_buttonPanel] = null;
|
||||
main_core.Dom.clean(babelHelpers.classPrivateFieldLooseBase(this, _renderTo)[_renderTo]);
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _renderTo)[_renderTo] = null;
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup]) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup].close();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup].getPopupWindow().destroy();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup] = null;
|
||||
}
|
||||
}
|
||||
hasUnsavedChanges() {
|
||||
return !(!babelHelpers.classPrivateFieldLooseBase(this, _store$1)[_store$1].getters['application/isModified'] || babelHelpers.classPrivateFieldLooseBase(this, _isUserConfirmedClose)[_isUserConfirmedClose]);
|
||||
@@ -5739,7 +5761,10 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
return;
|
||||
}
|
||||
sliderEvent.denyAction();
|
||||
const box = ui_dialogs_messagebox.MessageBox.create({
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup] && babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup].getPopupWindow().isShown()) {
|
||||
return;
|
||||
}
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup] = ui_dialogs_messagebox.MessageBox.create({
|
||||
mediumButtonSize: false,
|
||||
title: main_core.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_MODIFIED_CLOSE_WARNING_TITLE'),
|
||||
message: main_core.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_MODIFIED_CLOSE_WARNING'),
|
||||
@@ -5751,19 +5776,25 @@ this.BX.UI.AccessRights = this.BX.UI.AccessRights || {};
|
||||
onclick: () => {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _analyticsManager)[_analyticsManager].onCloseWithoutSave();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _isUserConfirmedClose)[_isUserConfirmedClose] = true;
|
||||
box.close();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup].close();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup] = null;
|
||||
setTimeout(() => {
|
||||
sliderEvent.getSlider().close();
|
||||
});
|
||||
}
|
||||
}), new ui_buttons.CancelButton({
|
||||
size: ui_buttons.ButtonSize.SMALL,
|
||||
text: main_core.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_CANCEL'),
|
||||
onclick: () => {
|
||||
box.close();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup].close();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup] = null;
|
||||
}
|
||||
})]
|
||||
})],
|
||||
popupOptions: {
|
||||
fixed: true
|
||||
}
|
||||
});
|
||||
box.show();
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _confirmationPopup)[_confirmationPopup].show();
|
||||
}
|
||||
|
||||
exports.App = App;
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
@@ -7,6 +7,7 @@ $MESS["JS_UI_ACCESSRIGHTS_V2_ALL_ROLES"] = "Alle Rollen";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ALL_SELECT_LABEL"] = "alle auswählen";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_APPLY_TO_ROLE"] = "In eine andere Rolle kopieren";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_APPLY_TO_ROLE_SUBTITLE"] = "Kopiert Zugriffsrechte von dieser Rolle in eine andere.";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_CANCEL"] = "Abbrechen";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS"] = "Alle Bereiche minimieren";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COPIED_ROLE_NAME"] = "Kopie von #ORIGINAL#";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COPY"] = "Kopieren";
|
||||
|
||||
@@ -7,6 +7,7 @@ $MESS["JS_UI_ACCESSRIGHTS_V2_ALL_ROLES"] = "All roles";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ALL_SELECT_LABEL"] = "select all";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_APPLY_TO_ROLE"] = "Copy to existing role";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_APPLY_TO_ROLE_SUBTITLE"] = "Copies access permissions from this role to another one.";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_CANCEL"] = "Cancel";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS"] = "Collapse all sections";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COPIED_ROLE_NAME"] = "Copy of #ORIGINAL#";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COPY"] = "Clone";
|
||||
|
||||
@@ -7,6 +7,7 @@ $MESS["JS_UI_ACCESSRIGHTS_V2_ALL_ROLES"] = "Барлық рөлдер";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ALL_SELECT_LABEL"] = "барлығын таңдаңыз";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_APPLY_TO_ROLE"] = "Басқа рөлге көшіру";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_APPLY_TO_ROLE_SUBTITLE"] = "Орнатылған қолжетімділік құқықтары басқа рөлге көшіріледі.";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_CANCEL"] = "Болдырмау";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS"] = "Барлық бөлімдерді орау";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COPIED_ROLE_NAME"] = "#ORIGINAL# көшірмесі";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_COPY"] = "Көшіру";
|
||||
@@ -40,10 +41,8 @@ $MESS["JS_UI_ACCESSRIGHTS_V2_ROLE_COUNTER"] = " #ALL_ROLES##GREY_FINISH# -дан
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ROLE_NAME"] = "Рөл атауы";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ROLE_SELECTOR_MAX_VISIBLE_WARNING"] = "Кіру құқығында бір уақытта #COUNT# рөл көрсетілуі мүмкін";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ROLE_VIEW"] = "Рөлдерді көрсету";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ROLE_VIEW_SUBTITLE"] = "Маңызды емес рөлдер жасырылады";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ROLE_VIEW_SUBTITLE_MSGVER_1"] = "Қандай рөлдерді көрсету немесе жасыру керектігін таңдаңыз.";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_SEARCH_PLACEHOLDER"] = "Іздеу";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_SEARCH_PLACEHOLDER_1"] = "элемент немесе ереже атауы бойынша іздеу";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_SELECTED_ITEMS_TITLE"] = "Таңдалған:";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_SETTINGS_HAVE_BEEN_SAVED"] = "Баптаулар сақталды";
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_SET_MAX_ACCESS_RIGHTS"] = "Барлығына қолжетімділікті ашыңыз";
|
||||
|
||||
@@ -56,3 +56,4 @@ $MESS["JS_UI_ACCESSRIGHTS_V2_SET_MIN_ACCESS_RIGHTS_ROW_SUBTITLE"] = "Досту
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_ACTIONS"] = "Действия";
|
||||
$MESS['JS_UI_ACCESSRIGHTS_V2_EXPAND_ALL_SECTIONS'] = 'Развернуть все разделы';
|
||||
$MESS['JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS'] = 'Свернуть все разделы';
|
||||
$MESS["JS_UI_ACCESSRIGHTS_V2_CANCEL"] = "Отмена";
|
||||
|
||||
@@ -8,6 +8,7 @@ import { Grid } from './components/grid';
|
||||
import 'ui.notification';
|
||||
import { AnalyticsManager } from './integration/analytics-manager';
|
||||
import { createStore } from './store/index';
|
||||
import type { AccessRightsModel } from './store/model/access-rights-model';
|
||||
import type { Options } from './store/model/application-model';
|
||||
import { AccessRightsExporter } from './store/model/transformation/backend-exporter/access-rights-exporter';
|
||||
import { AllUserGroupsExporter } from './store/model/transformation/backend-exporter/user-groups/all-user-groups-exporter';
|
||||
@@ -19,7 +20,6 @@ import type { ExternalUserGroup } from './store/model/transformation/internalize
|
||||
import { UserGroupsInternalizer } from './store/model/transformation/internalizer/user-groups-internalizer';
|
||||
import { ShownUserGroupsCopier } from './store/model/transformation/shown-user-groups-copier';
|
||||
import type { UserGroupsCollection, UserGroupsModel } from './store/model/user-groups-model';
|
||||
import type { AccessRightsModel } from './store/model/access-rights-model';
|
||||
|
||||
export type AppConstructOptions = Options & {
|
||||
renderTo: HTMLElement;
|
||||
@@ -51,6 +51,7 @@ export class App
|
||||
#userGroupsModel: UserGroupsModel;
|
||||
#accessRightsModel: AccessRightsModel;
|
||||
#analyticsManager: AnalyticsManager;
|
||||
#confirmationPopup: MessageBox | null = null;
|
||||
|
||||
constructor(options: AppConstructOptions)
|
||||
{
|
||||
@@ -155,16 +156,14 @@ export class App
|
||||
sendActionRequest(): Promise
|
||||
{
|
||||
return new Promise((resolve, reject) => {
|
||||
if (this.#store.state.application.isSaving || !this.#store.getters['application/isModified'])
|
||||
if (this.#store.state.application.isProgress || !this.#store.getters['application/isModified'])
|
||||
{
|
||||
resolve();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
this.#store.commit('application/setSaving', true);
|
||||
|
||||
this.#analyticsManager.onSaveAttempt();
|
||||
this.#store.commit('application/setProgress', true);
|
||||
|
||||
this.#runSaveAjaxRequest()
|
||||
.then(({ userGroups, accessRights }) => {
|
||||
@@ -203,7 +202,7 @@ export class App
|
||||
.finally(() => {
|
||||
const waitContainer = this.#buttonPanel?.getContainer().querySelector('.ui-btn-wait');
|
||||
Dom.removeClass(waitContainer, 'ui-btn-wait');
|
||||
this.#store.commit('application/setSaving', false);
|
||||
this.#store.commit('application/setProgress', false);
|
||||
|
||||
resolve();
|
||||
});
|
||||
@@ -287,7 +286,12 @@ export class App
|
||||
|
||||
sliderEvent.denyAction();
|
||||
|
||||
const box = MessageBox.create({
|
||||
if (this.#confirmationPopup && this.#confirmationPopup.getPopupWindow().isShown())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
this.#confirmationPopup = MessageBox.create({
|
||||
mediumButtonSize: false,
|
||||
title: Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_MODIFIED_CLOSE_WARNING_TITLE'),
|
||||
message: Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_MODIFIED_CLOSE_WARNING'),
|
||||
@@ -300,7 +304,8 @@ export class App
|
||||
onclick: () => {
|
||||
this.#analyticsManager.onCloseWithoutSave();
|
||||
this.#isUserConfirmedClose = true;
|
||||
box.close();
|
||||
this.#confirmationPopup.close();
|
||||
this.#confirmationPopup = null;
|
||||
|
||||
setTimeout(() => {
|
||||
sliderEvent.getSlider().close();
|
||||
@@ -309,14 +314,19 @@ export class App
|
||||
}),
|
||||
new CancelButton({
|
||||
size: ButtonSize.SMALL,
|
||||
text: Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_CANCEL'),
|
||||
onclick: () => {
|
||||
box.close();
|
||||
this.#confirmationPopup.close();
|
||||
this.#confirmationPopup = null;
|
||||
},
|
||||
}),
|
||||
],
|
||||
popupOptions: {
|
||||
fixed: true,
|
||||
},
|
||||
});
|
||||
|
||||
box.show();
|
||||
this.#confirmationPopup.show();
|
||||
}
|
||||
|
||||
draw(): void
|
||||
@@ -377,6 +387,13 @@ export class App
|
||||
|
||||
Dom.clean(this.#renderTo);
|
||||
this.#renderTo = null;
|
||||
|
||||
if (this.#confirmationPopup)
|
||||
{
|
||||
this.#confirmationPopup.close();
|
||||
this.#confirmationPopup.getPopupWindow().destroy();
|
||||
this.#confirmationPopup = null;
|
||||
}
|
||||
}
|
||||
|
||||
hasUnsavedChanges(): boolean
|
||||
|
||||
@@ -12,7 +12,7 @@ export const Grid = {
|
||||
loader: null,
|
||||
computed: {
|
||||
...mapState({
|
||||
isSaving: (state) => state.application.isSaving,
|
||||
isProgress: (state) => state.application.isProgress,
|
||||
guid: (state) => state.application.guid,
|
||||
searchContainerSelector: (state) => state.application.options.searchContainerSelector,
|
||||
}),
|
||||
@@ -109,7 +109,7 @@ export const Grid = {
|
||||
<SearchBox/>
|
||||
</Teleport>
|
||||
<div ref="container" class='ui-access-rights-v2' :class="{
|
||||
'ui-access-rights-v2-block': isSaving,
|
||||
'ui-access-rights-v2-block': isProgress,
|
||||
}">
|
||||
<Header :user-groups="shownUserGroups"/>
|
||||
<Section
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import { Extension } from 'main.core';
|
||||
import type { MemberCollection } from '../../store/model/user-groups-model';
|
||||
import { Selector } from './members/selector';
|
||||
import { SingleMember } from './members/single-member';
|
||||
@@ -62,7 +63,7 @@ export const Members = {
|
||||
'--has-siblings': userGroup.members.size > 0,
|
||||
}"
|
||||
>
|
||||
<div class="ui-icon-set --plus-30"></div>
|
||||
<div class="ui-icon-set --plus-m"></div>
|
||||
</div>
|
||||
<Selector
|
||||
v-if="isSelectorShown"
|
||||
|
||||
@@ -32,6 +32,7 @@ export const Selector = {
|
||||
addUserGroupsProviderTab: (state) => state.application.options.additionalMembersParams.addUserGroupsProviderTab,
|
||||
addProjectsProviderTab: (state) => state.application.options.additionalMembersParams.addProjectsProviderTab,
|
||||
addStructureTeamsProviderTab: (state) => state.application.options.additionalMembersParams.addStructureTeamsProviderTab,
|
||||
addStructureRolesProviderTab: (state) => state.application.options.additionalMembersParams.addStructureRolesProviderTab,
|
||||
}),
|
||||
},
|
||||
mounted()
|
||||
@@ -90,6 +91,11 @@ export const Selector = {
|
||||
return ['site-groups', groupId];
|
||||
}
|
||||
|
||||
if (/^(?:ATD|ATE|ATT|AD|AE|AT)[1-9]\d*$/.test(accessCode))
|
||||
{
|
||||
return ['structure-role', accessCode];
|
||||
}
|
||||
|
||||
if (accessCode.at(0) === 'A')
|
||||
{
|
||||
return ['user-groups', accessCode];
|
||||
@@ -192,6 +198,11 @@ export const Selector = {
|
||||
return item.id;
|
||||
}
|
||||
|
||||
if (entityId === 'structure-role')
|
||||
{
|
||||
return item.id;
|
||||
}
|
||||
|
||||
if (entityId === 'project-access-codes')
|
||||
{
|
||||
return item.id;
|
||||
@@ -216,6 +227,7 @@ export const Selector = {
|
||||
return 'structureteams';
|
||||
case 'site-groups':
|
||||
case 'user-groups':
|
||||
case 'structure-role':
|
||||
return 'usergroups';
|
||||
default:
|
||||
return '';
|
||||
@@ -247,15 +259,27 @@ export const Selector = {
|
||||
},
|
||||
];
|
||||
|
||||
if (this.addStructureRolesProviderTab)
|
||||
{
|
||||
entities.push({
|
||||
id: 'structure-role',
|
||||
options: {
|
||||
includedNodeEntityTypes: ['team', 'department'],
|
||||
},
|
||||
dynamicLoad: true,
|
||||
dynamicSearch: true,
|
||||
});
|
||||
}
|
||||
|
||||
if (this.addStructureTeamsProviderTab)
|
||||
{
|
||||
entities.push({
|
||||
id: 'structure-node',
|
||||
options: {
|
||||
selectMode: 'usersAndDepartments',
|
||||
includedNodeEntityTypes: ['team'],
|
||||
allowSelectRootDepartment: true,
|
||||
allowFlatDepartments: true,
|
||||
includedNodeEntityTypes: ['team'],
|
||||
useMultipleTabs: true,
|
||||
visual: {
|
||||
avatarMode: 'node',
|
||||
|
||||
@@ -23,7 +23,7 @@ export const RoleHeading = {
|
||||
computed: {
|
||||
RichMenuItemIcon: () => RichMenuItemIcon,
|
||||
...mapState({
|
||||
isSaving: (state) => state.application.isSaving,
|
||||
isProgress: (state) => state.application.isProgress,
|
||||
guid: (state) => state.application.guid,
|
||||
maxVisibleUserGroups: (state) => state.application.options.maxVisibleUserGroups,
|
||||
}),
|
||||
@@ -122,6 +122,7 @@ export const RoleHeading = {
|
||||
},
|
||||
}),
|
||||
new CancelButton({
|
||||
text: this.$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_CANCEL'),
|
||||
size: ButtonSize.SMALL,
|
||||
events: {
|
||||
click: () => {
|
||||
@@ -135,7 +136,7 @@ export const RoleHeading = {
|
||||
popup.show();
|
||||
},
|
||||
showActionsMenu(): void {
|
||||
if (!this.isSaving)
|
||||
if (!this.isProgress)
|
||||
{
|
||||
this.isPopupShown = true;
|
||||
}
|
||||
@@ -179,7 +180,7 @@ export const RoleHeading = {
|
||||
<div ref="container" class='ui-access-rights-v2-role'>
|
||||
<div class="ui-access-rights-v2-role-value-container">
|
||||
<input
|
||||
v-if="isEdit && !isSaving"
|
||||
v-if="isEdit && !isProgress"
|
||||
ref="input"
|
||||
type='text'
|
||||
class='ui-access-rights-v2-role-input'
|
||||
@@ -191,7 +192,8 @@ export const RoleHeading = {
|
||||
</div>
|
||||
<div
|
||||
ref="menu"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more"
|
||||
style="position: absolute; right: 11px; top: 5px;"
|
||||
@click="showActionsMenu"
|
||||
>
|
||||
<RichMenuPopup v-if="isPopupShown" @close="isPopupShown = false" :popup-options="{bindElement: $refs.menu}">
|
||||
|
||||
@@ -169,7 +169,8 @@ export const RolesControl = {
|
||||
<div>{{ $Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_ROLES') }}</div>
|
||||
<div
|
||||
ref="configure"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more"
|
||||
style="position: absolute; right: 11px; top: 5px;"
|
||||
@click="isPopupShown = true"
|
||||
>
|
||||
<RichMenuPopup v-if="isPopupShown" @close="isPopupShown = false" :popup-options="{bindElement: $refs.configure}">
|
||||
@@ -216,21 +217,25 @@ export const RolesControl = {
|
||||
class="ui-access-rights-v2-header-roles-control-counter"
|
||||
@click="toggleViewDialog($refs.counter)"
|
||||
>
|
||||
<div class="ui-icon-set --opened-eye" style="--ui-icon-set__icon-size: 15px;"></div>
|
||||
<div class="ui-icon-set --o-observer" style="--ui-icon-set__icon-size: 18px;"></div>
|
||||
<span v-html="shownGroupsCounter"></span>
|
||||
<div class="ui-icon-set --chevron-down ui-access-rights-v2-header-roles-control-chevron"></div>
|
||||
</div>
|
||||
<div class="ui-access-rights-v2-header-roles-control-expander">
|
||||
<div
|
||||
class="ui-icon-set --collapse"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/collapseAllSections')"
|
||||
></div>
|
||||
<div
|
||||
class="ui-icon-set --expand-1"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_EXPAND_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/expandAllSections')"
|
||||
></div>
|
||||
<div class="ui-access-rights-v2-header-roles-control-expander-button">
|
||||
<div
|
||||
class="ui-icon-set --collapse"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_COLLAPSE_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/collapseAllSections')"
|
||||
></div>
|
||||
</div>
|
||||
<div class="ui-access-rights-v2-header-roles-control-expander-button">
|
||||
<div
|
||||
class="ui-icon-set --expand-1"
|
||||
:title="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_EXPAND_ALL_SECTIONS')"
|
||||
@click="$store.dispatch('accessRights/expandAllSections')"
|
||||
></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</CellLayout>
|
||||
|
||||
@@ -22,14 +22,19 @@ export const SearchBox = {
|
||||
},
|
||||
},
|
||||
template: `
|
||||
<div class="ui-ctl ui-ctl-after-icon ui-ctl-w100 ui-access-rights-v2-search">
|
||||
<div
|
||||
class="ui-ctl ui-ctl-after-icon ui-access-rights-v2-search">
|
||||
<input
|
||||
type="text"
|
||||
class="ui-ctl-element ui-ctl-textbox ui-access-rights-v2-search-input"
|
||||
:placeholder="$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_SEARCH_PLACEHOLDER')"
|
||||
v-model="searchQuery"
|
||||
ref="searchInput"
|
||||
>
|
||||
<a class="ui-ctl-after ui-ctl-icon-search ui-access-rights-v2-search-icon"></a>
|
||||
<a
|
||||
class="ui-icon-set --o-search ui-access-rights-v2-search-icon"
|
||||
@click="this.$refs.searchInput.focus()"
|
||||
></a>
|
||||
</div>
|
||||
`,
|
||||
};
|
||||
|
||||
@@ -106,7 +106,7 @@ export const MenuCell = {
|
||||
<CellLayout class="ui-access-rights-v2-menu-cell" style="cursor: pointer" @click="toggleMenu">
|
||||
<div
|
||||
ref="icon"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more"
|
||||
>
|
||||
<RichMenuPopup
|
||||
v-if="isMenuShown"
|
||||
|
||||
@@ -129,8 +129,8 @@ export const TitleCell = {
|
||||
v-if="right.groupHead"
|
||||
class="ui-icon-set"
|
||||
:class="{
|
||||
'--minus-in-circle': right.isGroupExpanded,
|
||||
'--plus-in-circle': !right.isGroupExpanded,
|
||||
'--o-circle-minus': right.isGroupExpanded,
|
||||
'--o-circle-plus': !right.isGroupExpanded,
|
||||
}"
|
||||
></span>
|
||||
<div
|
||||
@@ -144,15 +144,13 @@ export const TitleCell = {
|
||||
class="ui-access-rights-v2-column-item-title-link ui-access-rights-v2-text-ellipsis"
|
||||
@click="onRightClick"
|
||||
>
|
||||
{{ right.title }}
|
||||
<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
{{ right.title }}<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
</span>
|
||||
<span
|
||||
v-else
|
||||
class="ui-access-rights-v2-text-wrap"
|
||||
>
|
||||
{{ right.title }}
|
||||
<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
{{ right.title }}<Hint v-once v-if="right.hint" :html="right.hint"/>
|
||||
</span>
|
||||
<span
|
||||
v-if="right.subtitle"
|
||||
@@ -162,7 +160,7 @@ export const TitleCell = {
|
||||
</div>
|
||||
<div
|
||||
ref="icon"
|
||||
class="ui-icon-set --more ui-access-rights-v2-icon-more ui-access-rights-v2-title-column-menu"
|
||||
class="ui-icon-set --more-l ui-access-rights-v2-icon-more ui-access-rights-v2-title-column-menu"
|
||||
@click="toggleMenu"
|
||||
>
|
||||
<RichMenuPopup
|
||||
|
||||
@@ -47,6 +47,7 @@ export const ValuePopup = {
|
||||
onclick: () => {
|
||||
this.$emit('close');
|
||||
},
|
||||
text: this.$Bitrix.Loc.getMessage('JS_UI_ACCESSRIGHTS_V2_CANCEL'),
|
||||
});
|
||||
cancelButton.renderTo(this.$refs['button-container']);
|
||||
});
|
||||
|
||||
@@ -24,10 +24,18 @@
|
||||
align-items: center;
|
||||
cursor: pointer;
|
||||
font-size: var(--ui-font-size-sm);
|
||||
border: 1px solid var(--design-outline-default-design-outline-stroke, var(--ui-color-base-7));
|
||||
border-radius: var(--ui-border-radius-pill);
|
||||
box-shadow: var(--ui-shadow-bottom-s);
|
||||
padding: 5px 10px 5px 10px;
|
||||
border: var(--ui-border-width-thin) solid rgba(var(--ui-color-palette-black-solid-rgb), 0.07)
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-counter:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-counter .ui-icon-set {
|
||||
--ui-icon-set__icon-color: var(--ui-color-accent-main-primary);
|
||||
margin-right: 2px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-chevron {
|
||||
@@ -46,3 +54,24 @@
|
||||
opacity: var(--ui-opacity-60);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-expander-button {
|
||||
height: 24px;
|
||||
width: 24px;
|
||||
border: 1px solid var(--design-outline-default-design-outline-stroke, var(--ui-color-base-7));
|
||||
border-radius: var(--ui-border-radius-xs);
|
||||
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
margin-left: 4px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-expander-button:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-roles-control-expander-button .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 18px;
|
||||
}
|
||||
|
||||
@@ -22,23 +22,22 @@
|
||||
.ui-access-rights-v2-section-header-expander {
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
background-color: var(--ui-color-palette-white-base);
|
||||
border: 1px solid var(--ui-color-base-7);
|
||||
border-radius: var(--ui-border-radius-circle);
|
||||
box-shadow: var(--ui-shadow-bottom-s);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin-right: 9px;
|
||||
background-color: var(--ui-color-bg-content-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header-expander:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header-expander .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 12px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-gray-40);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header.--expanded .ui-access-rights-v2-section-header-expander .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 12px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-black-base);
|
||||
--ui-icon-set__icon-color: var(--ui-color-accent-main-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header-icon {
|
||||
@@ -55,16 +54,16 @@
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-title {
|
||||
color: var(--ui-color-palette-gray-80);
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
max-width: 70%;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-header.--expanded .ui-access-rights-v2-section-title {
|
||||
color: var(--ui-color-palette-black-base);
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-subtitle {
|
||||
color: var(--ui-color-palette-gray-70);
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
margin-left: 3px;
|
||||
max-width: 200px;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
.ui-access-rights-v2 {
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section:last-child .ui-access-rights-v2-section-container {
|
||||
border-bottom-left-radius: var(--ui-border-radius-xl);
|
||||
border-bottom-right-radius: var(--ui-border-radius-xl);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-block {
|
||||
position: relative;
|
||||
pointer-events: none;
|
||||
@@ -29,6 +34,14 @@
|
||||
font-size: var(--ui-font-size-lg);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2--head-section::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
background: var(--ui-color-gray-05) ;
|
||||
z-index: -1;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2--head-section .ui-access-rights-v2-column-item-text {
|
||||
font-size: var(--ui-font-size-lg);
|
||||
}
|
||||
@@ -44,8 +57,8 @@
|
||||
|
||||
.ui-access-rights-v2--head-section .ui-access-rights-v2-section-container {
|
||||
height: 82px;
|
||||
border-top-right-radius: var(--ui-border-radius-xs);
|
||||
border-top-left-radius: var(--ui-border-radius-xs);
|
||||
border-top-right-radius: var(--ui-border-radius-xl);
|
||||
border-top-left-radius: var(--ui-border-radius-xl);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-section-head {
|
||||
@@ -173,7 +186,7 @@
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
font-size: var(--ui-font-size-sm);
|
||||
color: var(--ui-color-palette-black-base);
|
||||
color: var(--ui-color-base-90);
|
||||
line-height: var(--ui-font-line-height-2xs);
|
||||
cursor: default;
|
||||
}
|
||||
@@ -187,6 +200,8 @@
|
||||
.ui-access-rights-v2-column-item-title-block {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title-icon {
|
||||
@@ -205,8 +220,8 @@
|
||||
color: var(--ui-color-palette-gray-90);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .--plus-in-circle, .ui-access-rights-v2-column-item-title .--minus-in-circle {
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-gray-50);
|
||||
.ui-access-rights-v2-column-item-title .--o-circle-plus, .ui-access-rights-v2-column-item-title .--o-circle-minus {
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-gray-30);
|
||||
--ui-icon-set__icon-size: 18px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
@@ -216,14 +231,25 @@
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .ui-access-rights-v2-hint-container {
|
||||
display: inline;
|
||||
vertical-align: middle;
|
||||
position: relative;
|
||||
top: 2px;
|
||||
top: 1px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-hint-container::before {
|
||||
content: "\00a0";
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .ui-hint {
|
||||
line-height: normal;
|
||||
width: 13px;
|
||||
height: 13px;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-hint-container .ui-icon-set {
|
||||
--ui-icon-set__icon-size: 16px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-column-item-title .ui-hint-icon {
|
||||
@@ -248,7 +274,7 @@
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-role-cell {
|
||||
padding: 10px;
|
||||
padding: 16px 10px 10px 10px;
|
||||
height: calc(100% - 20px);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
@@ -268,13 +294,15 @@
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-right: -16px; /* because of menu */
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-role-input,
|
||||
.ui-access-rights-v2-role-value {
|
||||
font-size: var(--ui-font-size-lg);
|
||||
line-height: var(--ui-font-line-height-3xs);
|
||||
color: var(--ui-color-gray-90);
|
||||
font-weight: var(--ui-font-weight-normal);
|
||||
line-height: 20px;
|
||||
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
@@ -305,11 +333,14 @@
|
||||
.ui-access-rights-v2-members {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
border: var(--ui-border-width-thin) solid #525C6929;
|
||||
border-radius: var(--ui-border-radius-pill);
|
||||
padding: 4px;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-air-template {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item {
|
||||
display: inline-block;
|
||||
margin-left: -9px;
|
||||
@@ -327,15 +358,18 @@
|
||||
.ui-access-rights-v2-members-item-add {
|
||||
height: 24px;
|
||||
width: 24px;
|
||||
border: none;
|
||||
background: #fff;
|
||||
box-shadow: 0 2px 4px 0 rgba(0,0,0,.14);
|
||||
border-radius: 100%;
|
||||
cursor: pointer;
|
||||
border: 1px solid var(--ui-color-base-7)
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item-add:hover {
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item-add .ui-icon-set {
|
||||
--ui-icon-set__icon-color: var(--ui-color-palette-blue-50);
|
||||
--ui-icon-set__icon-color: var(--ui-color-accent-main-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-members-item-add:hover .ui-icon-set {
|
||||
@@ -437,6 +471,12 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
overflow: visible;
|
||||
text-overflow: clip;
|
||||
word-break: break-word;
|
||||
|
||||
width: 100%;
|
||||
justify-content: space-between;
|
||||
|
||||
font-weight: 400;
|
||||
font-size: var(--ui-font-size-sm);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-text-center {
|
||||
@@ -455,13 +495,23 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
|
||||
.ui-access-rights-v2-icon-more {
|
||||
--ui-icon-set__icon-size: 16px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-base-5);
|
||||
opacity: var(--ui-opacity-40);
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search {
|
||||
max-width: 290px;
|
||||
--ui-field-size: 34px
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search-input {
|
||||
background-color: #F6F7F9;
|
||||
border: none;
|
||||
border-radius: var(--ui-border-radius-sm);
|
||||
border: 1px solid var(--ui-color-bg-content-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search .ui-ctl-element:hover, .ui-access-rights-v2-search .ui-ctl-element:focus {
|
||||
border-color: var(--ui-color-bg-content-primary);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search-input:focus {
|
||||
@@ -485,8 +535,7 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-role-add .ui-btn:hover:not(.ui-btn-disabled) {
|
||||
border-color: var(--ui-color-palette-blue-30);
|
||||
background: unset;
|
||||
background-color: var(--ui-color-base-7);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-header-role-add .ui-btn.ui-btn-disabled {
|
||||
@@ -495,4 +544,17 @@ div.ui-access-rights-v2-members-item-new:last-of-type {
|
||||
|
||||
.ui-access-rights-v2-header-role-add .ui-icon-set {
|
||||
--ui-icon-set__icon-color: var(--ui-color-base-50);
|
||||
}
|
||||
|
||||
.ui-access-rights-v2-search-icon {
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
display: block;
|
||||
width: 22px;
|
||||
height: calc(var(--ui-field-size) - 2px);
|
||||
right: 12px;
|
||||
cursor: pointer;
|
||||
|
||||
--ui-icon-set__icon-size: 20px;
|
||||
--ui-icon-set__icon-color: var(--ui-color-base-5);
|
||||
}
|
||||
@@ -21,31 +21,6 @@ export class AnalyticsManager
|
||||
this.#isEnabled = Object.hasOwn(this.#data, 'tool') && Object.hasOwn(this.#data, 'category');
|
||||
}
|
||||
|
||||
onSaveAttempt(): void
|
||||
{
|
||||
if (!this.#isEnabled)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
const { createdRoles, editedRoles, deletedRoles } = this.#analyzeRoles();
|
||||
|
||||
for (let i = 0; i < createdRoles; i++)
|
||||
{
|
||||
this.#registerRoleCreateEvent('attempt');
|
||||
}
|
||||
|
||||
for (let i = 0; i < editedRoles; i++)
|
||||
{
|
||||
this.#registerRoleEditEvent('attempt');
|
||||
}
|
||||
|
||||
for (let i = 0; i < deletedRoles; i++)
|
||||
{
|
||||
this.#registerRoleDeleteEvent('attempt');
|
||||
}
|
||||
}
|
||||
|
||||
onSaveSuccess(): void
|
||||
{
|
||||
if (!this.#isEnabled)
|
||||
|
||||
@@ -20,6 +20,7 @@ export class ServiceLocator
|
||||
return this.#cache.remember(`hint-${appGuid}`, () => {
|
||||
return BX.UI.Hint.createInstance({
|
||||
id: `ui-access-rights-v2-hint-${appGuid}`,
|
||||
classNameIcon: 'ui-icon-set --o-question',
|
||||
popupParameters: {
|
||||
className: 'ui-access-rights-v2-popup-pointer-events ui-hint-popup',
|
||||
autoHide: true,
|
||||
|
||||
@@ -3,7 +3,7 @@ import { BuilderModel, type GetterTree, type MutationTree } from 'ui.vue3.vuex';
|
||||
export type ApplicationState = {
|
||||
options: Readonly<Options>,
|
||||
guid: string,
|
||||
isSaving: boolean,
|
||||
isProgress: boolean,
|
||||
}
|
||||
|
||||
export type Options = {
|
||||
@@ -58,7 +58,7 @@ export class ApplicationModel extends BuilderModel
|
||||
return {
|
||||
options: this.#options,
|
||||
guid: this.#guid,
|
||||
isSaving: false,
|
||||
isProgress: false,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -80,9 +80,9 @@ export class ApplicationModel extends BuilderModel
|
||||
getMutations(): MutationTree<ApplicationState>
|
||||
{
|
||||
return {
|
||||
setSaving: (state, isSaving: boolean): void => {
|
||||
setProgress: (state, isProgress: boolean): void => {
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
state.isSaving = Boolean(isSaving);
|
||||
state.isProgress = Boolean(isProgress);
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
+2
@@ -31,11 +31,13 @@ export class ApplicationInternalizer implements Transformer<Options, Readonly<Op
|
||||
addUserGroupsProviderTab: Boolean(externalSource.additionalMembersParams?.addUserGroupsProviderTab ?? false),
|
||||
addProjectsProviderTab: Boolean(externalSource.additionalMembersParams?.addProjectsProviderTab ?? true),
|
||||
addStructureTeamsProviderTab: Boolean(externalSource.additionalMembersParams?.addStructureTeamsProviderTab ?? false),
|
||||
addStructureRolesProviderTab: Boolean(externalSource.additionalMembersParams?.addStructureRolesProviderTab ?? false),
|
||||
}
|
||||
: {
|
||||
addUserGroupsProviderTab: false,
|
||||
addProjectsProviderTab: true,
|
||||
addStructureTeamsProviderTab: false,
|
||||
addStructureRolesProviderTab: false,
|
||||
},
|
||||
isSaveAccessRightsList: Type.isBoolean(externalSource.isSaveAccessRightsList)
|
||||
? externalSource.isSaveAccessRightsList
|
||||
|
||||
+1
-1
@@ -51,7 +51,7 @@
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.ui-avatar svg {
|
||||
.ui-avatar > svg {
|
||||
width: var(--ui-avatar-size);
|
||||
height: var(--ui-avatar-size)
|
||||
}
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -40,7 +40,7 @@
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.ui-avatar svg {
|
||||
.ui-avatar > svg {
|
||||
width: var(--ui-avatar-size);
|
||||
height: var(--ui-avatar-size)
|
||||
}
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
this.BX=this.BX||{},function(e,s,a){"use strict";var t=babelHelpers.classPrivateFieldLooseKey("priority"),i=babelHelpers.classPrivateFieldLooseKey("delay"),r=babelHelpers.classPrivateFieldLooseKey("itemList"),l=babelHelpers.classPrivateFieldLooseKey("enough"),o=babelHelpers.classPrivateFieldLooseKey("launchPerHit");class c{constructor(e,s,a=!1){Object.defineProperty(this,t,{writable:!0,value:void 0}),Object.defineProperty(this,i,{writable:!0,value:void 0}),Object.defineProperty(this,r,{writable:!0,value:{}}),Object.defineProperty(this,l,{writable:!0,value:!1}),Object.defineProperty(this,o,{writable:!0,value:!1}),babelHelpers.classPrivateFieldLooseBase(this,i)[i]=1e3*parseInt(s,10),babelHelpers.classPrivateFieldLooseBase(this,t)[t]=e,babelHelpers.classPrivateFieldLooseBase(this,o)[o]=a}add(e,c={}){if(babelHelpers.classPrivateFieldLooseBase(this,l)[l])return;if(!a.Type.isFunction(e))throw new TypeError('Unexpected type "promise" argument, expected Promise or callback');const h=!(babelHelpers.classPrivateFieldLooseBase(this,o)[o]&&Object.values(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).length>0),n=a.Type.isStringFilled(c.id)?c.id:a.Text.getRandom();babelHelpers.classPrivateFieldLooseBase(this,r)[r][n]=e,s.AutoLauncher.register(e,{...c,delay:babelHelpers.classPrivateFieldLooseBase(this,i)[i],priority:babelHelpers.classPrivateFieldLooseBase(this,t)[t],allowLaunchAfterOthers:h,id:n})}getItems(){return babelHelpers.classPrivateFieldLooseBase(this,r)[r]}clean(){Object.keys(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).forEach(e=>{this.remove(e)})}enough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!0}notEnough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!1}stop(){this.clean(),this.enough()}remove(e){s.AutoLauncher.unregister(e)}}const h=new c(s.LaunchPriority.CRITICAL,0),n=new c(s.LaunchPriority.HIGH,1),b=new c(s.LaunchPriority.NORMAL,1,!0),u=new c(s.LaunchPriority.LOW,5,!0),d={critical:{toQueue:(e,s={})=>{h.add(e,{allowLaunchAfterOthers:!0,forceShowOnTop:!0,...s})}},high:{toQueue:(e,s={})=>{n.add(e,{allowLaunchAfterOthers:!0,...s})}},normal:{toQueue:(e,s={})=>{b.add(e,s)}},low:{toQueue:(e,s={})=>{u.add(e,s)}},toQueue:(e,s={})=>{b.add(e,s)},only(e){Object.values(s.LaunchPriority).forEach(a=>{if(!e.includes(a))switch(a){case s.LaunchPriority.CRITICAL:h.stop();break;case s.LaunchPriority.HIGH:n.stop();break;case s.LaunchPriority.NORMAL:b.stop();break;case s.LaunchPriority.LOW:u.stop()}})}};e.BannerDispatcher=d}(this.BX.UI=this.BX.UI||{},BX.UI.AutoLaunch,BX);
|
||||
this.BX=this.BX||{},function(e,s,a){"use strict";var i=babelHelpers.classPrivateFieldLooseKey("priority"),t=babelHelpers.classPrivateFieldLooseKey("delay"),r=babelHelpers.classPrivateFieldLooseKey("itemList"),l=babelHelpers.classPrivateFieldLooseKey("enough"),o=babelHelpers.classPrivateFieldLooseKey("launchPerHit");class c{constructor(e,s,a=!1){Object.defineProperty(this,i,{writable:!0,value:void 0}),Object.defineProperty(this,t,{writable:!0,value:void 0}),Object.defineProperty(this,r,{writable:!0,value:{}}),Object.defineProperty(this,l,{writable:!0,value:!1}),Object.defineProperty(this,o,{writable:!0,value:!1}),babelHelpers.classPrivateFieldLooseBase(this,t)[t]=1e3*parseInt(s,10),babelHelpers.classPrivateFieldLooseBase(this,i)[i]=e,babelHelpers.classPrivateFieldLooseBase(this,o)[o]=a}add(e,c={}){if(babelHelpers.classPrivateFieldLooseBase(this,l)[l])return;if(!a.Type.isFunction(e))throw new TypeError('Unexpected type "promise" argument, expected Promise or callback');const h=!(babelHelpers.classPrivateFieldLooseBase(this,o)[o]&&Object.values(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).length>0),n=a.Type.isStringFilled(c.id)?c.id:a.Text.getRandom();babelHelpers.classPrivateFieldLooseBase(this,r)[r][n]=e,s.AutoLauncher.register(e,{...c,delay:babelHelpers.classPrivateFieldLooseBase(this,t)[t],priority:babelHelpers.classPrivateFieldLooseBase(this,i)[i],allowLaunchAfterOthers:h,id:n})}getItems(){return babelHelpers.classPrivateFieldLooseBase(this,r)[r]}clean(){Object.keys(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).forEach(e=>{this.remove(e)})}enough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!0}notEnough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!1}stop(){this.clean(),this.enough()}remove(e){s.AutoLauncher.unregister(e)}}const h=new c(s.LaunchPriority.CRITICAL,0),n=new c(s.LaunchPriority.HIGH,1),b=new c(s.LaunchPriority.NORMAL,1,!0),u=new c(s.LaunchPriority.LOW,5,!0),d={critical:{toQueue:(e,s={})=>{h.add(e,{allowLaunchAfterOthers:!0,forceShowOnTop:!0,...s})}},high:{toQueue:(e,s={})=>{n.add(e,{allowLaunchAfterOthers:!0,...s})}},normal:{toQueue:(e,s={})=>{b.add(e,s)}},low:{toQueue:(e,s={})=>{u.add(e,s)}},toQueue:(e,s={})=>{b.add(e,s)},only(e){Object.values(s.LaunchPriority).forEach(a=>{if(!e.includes(a))switch(a){case s.LaunchPriority.CRITICAL:h.stop();break;case s.LaunchPriority.HIGH:n.stop();break;case s.LaunchPriority.NORMAL:b.stop();break;case s.LaunchPriority.LOW:u.stop()}})},isEnabled:()=>s.AutoLauncher.isEnabled()};e.BannerDispatcher=d}(this.BX.UI=this.BX.UI||{},BX.UI.AutoLaunch,BX);
|
||||
//# sourceMappingURL=banner-dispatcher.bundle.js.map
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
|
||||
{"version":3,"file":"banner-dispatcher.bundle.map.js","names":["this","BX","e","s","a","t","babelHelpers","classPrivateFieldLooseKey","i","r","l","o","c","constructor","Object","defineProperty","writable","value","classPrivateFieldLooseBase","parseInt","add","Type","isFunction","TypeError","h","values","length","n","isStringFilled","id","Text","getRandom","AutoLauncher","register","delay","priority","allowLaunchAfterOthers","getItems","clean","keys","forEach","remove","enough","notEnough","stop","unregister","LaunchPriority","CRITICAL","HIGH","b","NORMAL","u","LOW","d","critical","toQueue","forceShowOnTop","high","normal","low","only","includes","BannerDispatcher","UI","AutoLaunch"],"sources":["banner-dispatcher.bundle.js"],"mappings":"AAAAA,KAAKC,GAAGD,KAAKC,IAAI,CAAC,EAAE,SAASC,EAAEC,EAAEC,GAAG,aAAa,IAAIC,EAAEC,aAAaC,0BAA0B,YAAYC,EAAEF,aAAaC,0BAA0B,SAASE,EAAEH,aAAaC,0BAA0B,YAAYG,EAAEJ,aAAaC,0BAA0B,UAAUI,EAAEL,aAAaC,0BAA0B,gBAAgB,MAAMK,EAAEC,YAAYX,EAAEC,EAAEC,GAAG,GAAGU,OAAOC,eAAef,KAAKK,EAAE,CAACW,UAAU,EAAEC,WAAW,IAAIH,OAAOC,eAAef,KAAKQ,EAAE,CAACQ,UAAU,EAAEC,WAAW,IAAIH,OAAOC,eAAef,KAAKS,EAAE,CAACO,UAAU,EAAEC,MAAM,CAAC,IAAIH,OAAOC,eAAef,KAAKU,EAAE,CAACM,UAAU,EAAEC,OAAO,IAAIH,OAAOC,eAAef,KAAKW,EAAE,CAACK,UAAU,EAAEC,OAAO,IAAIX,aAAaY,2BAA2BlB,KAAKQ,GAAGA,GAAG,IAAIW,SAAShB,EAAE,IAAIG,aAAaY,2BAA2BlB,KAAKK,GAAGA,GAAGH,EAAEI,aAAaY,2BAA2BlB,KAAKW,GAAGA,GAAGP,CAAC,CAACgB,IAAIlB,EAAEU,EAAE,CAAC,GAAG,GAAGN,aAAaY,2BAA2BlB,KAAKU,GAAGA,GAAG,OAAO,IAAIN,EAAEiB,KAAKC,WAAWpB,GAAG,MAAM,IAAIqB,UAAU,oEAAoE,MAAMC,IAAIlB,aAAaY,2BAA2BlB,KAAKW,GAAGA,IAAIG,OAAOW,OAAOnB,aAAaY,2BAA2BlB,KAAKS,GAAGA,IAAIiB,OAAO,GAAGC,EAAEvB,EAAEiB,KAAKO,eAAehB,EAAEiB,IAAIjB,EAAEiB,GAAGzB,EAAE0B,KAAKC,YAAYzB,aAAaY,2BAA2BlB,KAAKS,GAAGA,GAAGkB,GAAGzB,EAAEC,EAAE6B,aAAaC,SAAS/B,EAAE,IAAIU,EAAEsB,MAAM5B,aAAaY,2BAA2BlB,KAAKQ,GAAGA,GAAG2B,SAAS7B,aAAaY,2BAA2BlB,KAAKK,GAAGA,GAAG+B,uBAAuBZ,EAAEK,GAAGF,GAAG,CAACU,WAAW,OAAO/B,aAAaY,2BAA2BlB,KAAKS,GAAGA,EAAE,CAAC6B,QAAQxB,OAAOyB,KAAKjC,aAAaY,2BAA2BlB,KAAKS,GAAGA,IAAI+B,SAAQtC,IAAIF,KAAKyC,OAAOvC,EAAC,GAAG,CAACwC,SAASpC,aAAaY,2BAA2BlB,KAAKU,GAAGA,IAAI,CAAC,CAACiC,YAAYrC,aAAaY,2BAA2BlB,KAAKU,GAAGA,IAAI,CAAC,CAACkC,OAAO5C,KAAKsC,QAAQtC,KAAK0C,QAAQ,CAACD,OAAOvC,GAAGC,EAAE6B,aAAaa,WAAW3C,EAAE,EAAE,MAAMsB,EAAE,IAAIZ,EAAET,EAAE2C,eAAeC,SAAS,GAAGpB,EAAE,IAAIf,EAAET,EAAE2C,eAAeE,KAAK,GAAGC,EAAE,IAAIrC,EAAET,EAAE2C,eAAeI,OAAO,GAAG,GAAGC,EAAE,IAAIvC,EAAET,EAAE2C,eAAeM,IAAI,GAAG,GAAGC,EAAE,CAACC,SAAS,CAACC,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAKqB,EAAEJ,IAAIlB,EAAE,CAACkC,wBAAwB,EAAEoB,gBAAgB,KAAKrD,GAAE,GAAIsD,KAAK,CAACF,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAKwB,EAAEP,IAAIlB,EAAE,CAACkC,wBAAwB,KAAKjC,GAAE,GAAIuD,OAAO,CAACH,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAK8C,EAAE7B,IAAIlB,EAAEC,EAAC,GAAIwD,IAAI,CAACJ,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAKgD,EAAE/B,IAAIlB,EAAEC,EAAC,GAAIoD,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAK8C,EAAE7B,IAAIlB,EAAEC,EAAC,EAAGyD,KAAK1D,GAAGY,OAAOW,OAAOtB,EAAE2C,gBAAgBN,SAAQpC,IAAI,IAAIF,EAAE2D,SAASzD,GAAG,OAAOA,GAAG,KAAKD,EAAE2C,eAAeC,SAASvB,EAAEoB,OAAO,MAAM,KAAKzC,EAAE2C,eAAeE,KAAKrB,EAAEiB,OAAO,MAAM,KAAKzC,EAAE2C,eAAeI,OAAOD,EAAEL,OAAO,MAAM,KAAKzC,EAAE2C,eAAeM,IAAID,EAAEP,OAAM,GAAG,GAAG1C,EAAE4D,iBAAiBT,CAAC,CAAx5E,CAA05ErD,KAAKC,GAAG8D,GAAG/D,KAAKC,GAAG8D,IAAI,CAAC,EAAE9D,GAAG8D,GAAGC,WAAW/D"}
|
||||
{"version":3,"file":"banner-dispatcher.bundle.map.js","names":["this","BX","e","s","a","i","babelHelpers","classPrivateFieldLooseKey","t","r","l","o","c","constructor","Object","defineProperty","writable","value","classPrivateFieldLooseBase","parseInt","add","Type","isFunction","TypeError","h","values","length","n","isStringFilled","id","Text","getRandom","AutoLauncher","register","delay","priority","allowLaunchAfterOthers","getItems","clean","keys","forEach","remove","enough","notEnough","stop","unregister","LaunchPriority","CRITICAL","HIGH","b","NORMAL","u","LOW","d","critical","toQueue","forceShowOnTop","high","normal","low","only","includes","isEnabled","BannerDispatcher","UI","AutoLaunch"],"sources":["banner-dispatcher.bundle.js"],"mappings":"AAAAA,KAAKC,GAAGD,KAAKC,IAAI,CAAC,EAAE,SAASC,EAAEC,EAAEC,GAAG,aAAa,IAAIC,EAAEC,aAAaC,0BAA0B,YAAYC,EAAEF,aAAaC,0BAA0B,SAASE,EAAEH,aAAaC,0BAA0B,YAAYG,EAAEJ,aAAaC,0BAA0B,UAAUI,EAAEL,aAAaC,0BAA0B,gBAAgB,MAAMK,EAAE,WAAAC,CAAYX,EAAEC,EAAEC,GAAG,GAAGU,OAAOC,eAAef,KAAKK,EAAE,CAACW,UAAU,EAAEC,WAAW,IAAIH,OAAOC,eAAef,KAAKQ,EAAE,CAACQ,UAAU,EAAEC,WAAW,IAAIH,OAAOC,eAAef,KAAKS,EAAE,CAACO,UAAU,EAAEC,MAAM,CAAC,IAAIH,OAAOC,eAAef,KAAKU,EAAE,CAACM,UAAU,EAAEC,OAAO,IAAIH,OAAOC,eAAef,KAAKW,EAAE,CAACK,UAAU,EAAEC,OAAO,IAAIX,aAAaY,2BAA2BlB,KAAKQ,GAAGA,GAAG,IAAIW,SAAShB,EAAE,IAAIG,aAAaY,2BAA2BlB,KAAKK,GAAGA,GAAGH,EAAEI,aAAaY,2BAA2BlB,KAAKW,GAAGA,GAAGP,CAAC,CAAC,GAAAgB,CAAIlB,EAAEU,EAAE,CAAC,GAAG,GAAGN,aAAaY,2BAA2BlB,KAAKU,GAAGA,GAAG,OAAO,IAAIN,EAAEiB,KAAKC,WAAWpB,GAAG,MAAM,IAAIqB,UAAU,oEAAoE,MAAMC,IAAIlB,aAAaY,2BAA2BlB,KAAKW,GAAGA,IAAIG,OAAOW,OAAOnB,aAAaY,2BAA2BlB,KAAKS,GAAGA,IAAIiB,OAAO,GAAGC,EAAEvB,EAAEiB,KAAKO,eAAehB,EAAEiB,IAAIjB,EAAEiB,GAAGzB,EAAE0B,KAAKC,YAAYzB,aAAaY,2BAA2BlB,KAAKS,GAAGA,GAAGkB,GAAGzB,EAAEC,EAAE6B,aAAaC,SAAS/B,EAAE,IAAIU,EAAEsB,MAAM5B,aAAaY,2BAA2BlB,KAAKQ,GAAGA,GAAG2B,SAAS7B,aAAaY,2BAA2BlB,KAAKK,GAAGA,GAAG+B,uBAAuBZ,EAAEK,GAAGF,GAAG,CAAC,QAAAU,GAAW,OAAO/B,aAAaY,2BAA2BlB,KAAKS,GAAGA,EAAE,CAAC,KAAA6B,GAAQxB,OAAOyB,KAAKjC,aAAaY,2BAA2BlB,KAAKS,GAAGA,IAAI+B,SAAQtC,IAAIF,KAAKyC,OAAOvC,EAAC,GAAG,CAAC,MAAAwC,GAASpC,aAAaY,2BAA2BlB,KAAKU,GAAGA,IAAI,CAAC,CAAC,SAAAiC,GAAYrC,aAAaY,2BAA2BlB,KAAKU,GAAGA,IAAI,CAAC,CAAC,IAAAkC,GAAO5C,KAAKsC,QAAQtC,KAAK0C,QAAQ,CAAC,MAAAD,CAAOvC,GAAGC,EAAE6B,aAAaa,WAAW3C,EAAE,EAAE,MAAMsB,EAAE,IAAIZ,EAAET,EAAE2C,eAAeC,SAAS,GAAGpB,EAAE,IAAIf,EAAET,EAAE2C,eAAeE,KAAK,GAAGC,EAAE,IAAIrC,EAAET,EAAE2C,eAAeI,OAAO,GAAG,GAAGC,EAAE,IAAIvC,EAAET,EAAE2C,eAAeM,IAAI,GAAG,GAAGC,EAAE,CAACC,SAAS,CAACC,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAKqB,EAAEJ,IAAIlB,EAAE,CAACkC,wBAAwB,EAAEoB,gBAAgB,KAAKrD,GAAE,GAAIsD,KAAK,CAACF,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAKwB,EAAEP,IAAIlB,EAAE,CAACkC,wBAAwB,KAAKjC,GAAE,GAAIuD,OAAO,CAACH,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAK8C,EAAE7B,IAAIlB,EAAEC,EAAC,GAAIwD,IAAI,CAACJ,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAKgD,EAAE/B,IAAIlB,EAAEC,EAAC,GAAIoD,QAAQ,CAACrD,EAAEC,EAAE,CAAC,KAAK8C,EAAE7B,IAAIlB,EAAEC,EAAC,EAAG,IAAAyD,CAAK1D,GAAGY,OAAOW,OAAOtB,EAAE2C,gBAAgBN,SAAQpC,IAAI,IAAIF,EAAE2D,SAASzD,GAAG,OAAOA,GAAG,KAAKD,EAAE2C,eAAeC,SAASvB,EAAEoB,OAAO,MAAM,KAAKzC,EAAE2C,eAAeE,KAAKrB,EAAEiB,OAAO,MAAM,KAAKzC,EAAE2C,eAAeI,OAAOD,EAAEL,OAAO,MAAM,KAAKzC,EAAE2C,eAAeM,IAAID,EAAEP,OAAM,GAAG,EAAEkB,UAAU,IAAI3D,EAAE6B,aAAa8B,aAAa5D,EAAE6D,iBAAiBV,CAAC,CAAj8E,CAAm8ErD,KAAKC,GAAG+D,GAAGhE,KAAKC,GAAG+D,IAAI,CAAC,EAAE/D,GAAG+D,GAAGC,WAAWhE","ignoreList":[]}
|
||||
@@ -1,2 +1,2 @@
|
||||
this.BX=this.BX||{},function(e,s,a){"use strict";var t=babelHelpers.classPrivateFieldLooseKey("priority"),i=babelHelpers.classPrivateFieldLooseKey("delay"),r=babelHelpers.classPrivateFieldLooseKey("itemList"),l=babelHelpers.classPrivateFieldLooseKey("enough"),o=babelHelpers.classPrivateFieldLooseKey("launchPerHit");class c{constructor(e,s,a=!1){Object.defineProperty(this,t,{writable:!0,value:void 0}),Object.defineProperty(this,i,{writable:!0,value:void 0}),Object.defineProperty(this,r,{writable:!0,value:{}}),Object.defineProperty(this,l,{writable:!0,value:!1}),Object.defineProperty(this,o,{writable:!0,value:!1}),babelHelpers.classPrivateFieldLooseBase(this,i)[i]=1e3*parseInt(s,10),babelHelpers.classPrivateFieldLooseBase(this,t)[t]=e,babelHelpers.classPrivateFieldLooseBase(this,o)[o]=a}add(e,c={}){if(babelHelpers.classPrivateFieldLooseBase(this,l)[l])return;if(!a.Type.isFunction(e))throw new TypeError('Unexpected type "promise" argument, expected Promise or callback');const h=!(babelHelpers.classPrivateFieldLooseBase(this,o)[o]&&Object.values(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).length>0),n=a.Type.isStringFilled(c.id)?c.id:a.Text.getRandom();babelHelpers.classPrivateFieldLooseBase(this,r)[r][n]=e,s.AutoLauncher.register(e,{...c,delay:babelHelpers.classPrivateFieldLooseBase(this,i)[i],priority:babelHelpers.classPrivateFieldLooseBase(this,t)[t],allowLaunchAfterOthers:h,id:n})}getItems(){return babelHelpers.classPrivateFieldLooseBase(this,r)[r]}clean(){Object.keys(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).forEach((e=>{this.remove(e)}))}enough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!0}notEnough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!1}stop(){this.clean(),this.enough()}remove(e){s.AutoLauncher.unregister(e)}}const h=new c(s.LaunchPriority.CRITICAL,0),n=new c(s.LaunchPriority.HIGH,1),b=new c(s.LaunchPriority.NORMAL,1,!0),u=new c(s.LaunchPriority.LOW,5,!0),d={critical:{toQueue:(e,s={})=>{h.add(e,{allowLaunchAfterOthers:!0,forceShowOnTop:!0,...s})}},high:{toQueue:(e,s={})=>{n.add(e,{allowLaunchAfterOthers:!0,...s})}},normal:{toQueue:(e,s={})=>{b.add(e,s)}},low:{toQueue:(e,s={})=>{u.add(e,s)}},toQueue:(e,s={})=>{b.add(e,s)},only(e){Object.values(s.LaunchPriority).forEach((a=>{if(!e.includes(a))switch(a){case s.LaunchPriority.CRITICAL:h.stop();break;case s.LaunchPriority.HIGH:n.stop();break;case s.LaunchPriority.NORMAL:b.stop();break;case s.LaunchPriority.LOW:u.stop()}}))}};e.BannerDispatcher=d}(this.BX.UI=this.BX.UI||{},BX.UI.AutoLaunch,BX);
|
||||
this.BX=this.BX||{},function(e,s,a){"use strict";var i=babelHelpers.classPrivateFieldLooseKey("priority"),t=babelHelpers.classPrivateFieldLooseKey("delay"),r=babelHelpers.classPrivateFieldLooseKey("itemList"),l=babelHelpers.classPrivateFieldLooseKey("enough"),o=babelHelpers.classPrivateFieldLooseKey("launchPerHit");class c{constructor(e,s,a=!1){Object.defineProperty(this,i,{writable:!0,value:void 0}),Object.defineProperty(this,t,{writable:!0,value:void 0}),Object.defineProperty(this,r,{writable:!0,value:{}}),Object.defineProperty(this,l,{writable:!0,value:!1}),Object.defineProperty(this,o,{writable:!0,value:!1}),babelHelpers.classPrivateFieldLooseBase(this,t)[t]=1e3*parseInt(s,10),babelHelpers.classPrivateFieldLooseBase(this,i)[i]=e,babelHelpers.classPrivateFieldLooseBase(this,o)[o]=a}add(e,c={}){if(babelHelpers.classPrivateFieldLooseBase(this,l)[l])return;if(!a.Type.isFunction(e))throw new TypeError('Unexpected type "promise" argument, expected Promise or callback');const h=!(babelHelpers.classPrivateFieldLooseBase(this,o)[o]&&Object.values(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).length>0),n=a.Type.isStringFilled(c.id)?c.id:a.Text.getRandom();babelHelpers.classPrivateFieldLooseBase(this,r)[r][n]=e,s.AutoLauncher.register(e,{...c,delay:babelHelpers.classPrivateFieldLooseBase(this,t)[t],priority:babelHelpers.classPrivateFieldLooseBase(this,i)[i],allowLaunchAfterOthers:h,id:n})}getItems(){return babelHelpers.classPrivateFieldLooseBase(this,r)[r]}clean(){Object.keys(babelHelpers.classPrivateFieldLooseBase(this,r)[r]).forEach((e=>{this.remove(e)}))}enough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!0}notEnough(){babelHelpers.classPrivateFieldLooseBase(this,l)[l]=!1}stop(){this.clean(),this.enough()}remove(e){s.AutoLauncher.unregister(e)}}const h=new c(s.LaunchPriority.CRITICAL,0),n=new c(s.LaunchPriority.HIGH,1),b=new c(s.LaunchPriority.NORMAL,1,!0),u=new c(s.LaunchPriority.LOW,5,!0),d={critical:{toQueue:(e,s={})=>{h.add(e,{allowLaunchAfterOthers:!0,forceShowOnTop:!0,...s})}},high:{toQueue:(e,s={})=>{n.add(e,{allowLaunchAfterOthers:!0,...s})}},normal:{toQueue:(e,s={})=>{b.add(e,s)}},low:{toQueue:(e,s={})=>{u.add(e,s)}},toQueue:(e,s={})=>{b.add(e,s)},only(e){Object.values(s.LaunchPriority).forEach((a=>{if(!e.includes(a))switch(a){case s.LaunchPriority.CRITICAL:h.stop();break;case s.LaunchPriority.HIGH:n.stop();break;case s.LaunchPriority.NORMAL:b.stop();break;case s.LaunchPriority.LOW:u.stop()}}))},isEnabled:()=>s.AutoLauncher.isEnabled()};e.BannerDispatcher=d}(this.BX.UI=this.BX.UI||{},BX.UI.AutoLaunch,BX);
|
||||
//# sourceMappingURL=banner-dispatcher.bundle.map.js
|
||||
@@ -1,4 +1,4 @@
|
||||
import { LaunchPriority, type LaunchItemOptions, type LaunchItemCallback } from 'ui.auto-launch';
|
||||
import { LaunchPriority, type LaunchItemOptions, type LaunchItemCallback, AutoLauncher } from 'ui.auto-launch';
|
||||
import { Queue } from './queue';
|
||||
|
||||
const criticalQueue = new Queue(LaunchPriority.CRITICAL, 0);
|
||||
@@ -63,4 +63,9 @@ export const BannerDispatcher = {
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
isEnabled(): boolean
|
||||
{
|
||||
return AutoLauncher.isEnabled();
|
||||
},
|
||||
};
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
{"version":3,"file":"index.map.js","names":["fs","require","path","module","exports","webToMobilePlugin","options","this","name","modulesDirectory","join","__dirname","split","extensionsDirectory","targetExtensionFilePath","targetExtension","generateBundle","bundle","existsSync","rmSync","writeFileSync","bundleContent","readFileSync","file","Array","isArray","replacements","length","forEach","entry","replace","banner"],"sources":["index.js"],"mappings":"AAAA,MAAMA,GAAKC,QAAQ,MACnB,MAAMC,KAAOD,QAAQ,QASrBE,OAAOC,QAAU,SAASC,EAAkBC,GAC3CC,KAAKC,KAAO,uBACZ,MAAMC,EAAmBP,KAAKQ,KAAKC,UAAUC,MAAM,WAAW,GAAI,WAClE,MAAMC,EAAsBX,KAAKQ,KAAKD,EAAkB,SAAU,UAAW,YAAa,SAAU,aAAc,UAClH,MAAMK,EAA0BZ,KAAKQ,KAAKG,KAAwBP,EAAQS,gBAAgBH,MAAM,KAAM,gBAEtG,MAAO,CACNJ,KAAM,uBAENQ,eAAeC,GACd,GAAIjB,GAAGkB,WAAWJ,GAClB,CACCd,GAAGmB,OAAOL,EACX,CAEAd,GAAGoB,cAAcN,EAAyB,IAE1C,IAAIO,EAAgBrB,GAAGsB,aAAaL,EAAOM,KAAM,SACjD,GAAIC,MAAMC,QAAQnB,EAAQoB,eAAiBpB,EAAQoB,aAAaC,OAAS,EACzE,CACCrB,EAAQoB,aAAaE,SAASC,IAC7B,GAAIL,MAAMC,QAAQI,IAAUA,EAAMF,OAAS,EAC3C,CACCN,EAAgBA,EAAcS,WAAWD,EAC1C,IAEF,CAEA,UAAWvB,EAAQyB,SAAW,UAAYzB,EAAQyB,OAAOJ,OAAS,EAClE,CACCN,EAAgB,GAAGf,EAAQyB,WAAWV,GACvC,CAEArB,GAAGoB,cAAcN,EAAyBO,EAE3C,EAEF"}
|
||||
-2
@@ -1,2 +0,0 @@
|
||||
const fs=require("fs");const path=require("path");module.exports=function e(n){this.name="web-to-mobile-plugin";const i=path.join(__dirname.split("modules")[0],"modules");const t=path.join(i,"mobile","install","mobileapp","mobile","extensions","bitrix");const s=path.join(t,...n.targetExtension.split("/"),"extension.js");return{name:"web-to-mobile-plugin",generateBundle(e){if(fs.existsSync(s)){fs.rmSync(s)}fs.writeFileSync(s,"");let i=fs.readFileSync(e.file,"ascii");if(Array.isArray(n.replacements)&&n.replacements.length>0){n.replacements.forEach((e=>{if(Array.isArray(e)&&e.length>1){i=i.replace(...e)}}))}if(typeof n.banner==="string"&&n.banner.length>0){i=`${n.banner}\n${i}`}fs.writeFileSync(s,i)}}};
|
||||
//# sourceMappingURL=index.map.js
|
||||
-19
@@ -1,19 +0,0 @@
|
||||
import { Dom } from 'main.core';
|
||||
import { NodeFormatter, type NodeFormatterOptions, type ConvertCallbackOptions } from 'ui.bbcode.formatter';
|
||||
|
||||
export class SpanNodeFormatter extends NodeFormatter
|
||||
{
|
||||
constructor(options: NodeFormatterOptions = {})
|
||||
{
|
||||
super({
|
||||
name: 'span',
|
||||
convert({ node }: ConvertCallbackOptions): HTMLElement {
|
||||
return Dom.create({
|
||||
tag: 'span',
|
||||
attrs: node.getAttributes(),
|
||||
});
|
||||
},
|
||||
...options,
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -1 +0,0 @@
|
||||
{"version":3,"file":"index.map.js","names":["fs","require","path","module","exports","webToMobilePlugin","options","this","name","modulesDirectory","join","__dirname","split","extensionsDirectory","targetExtensionFilePath","targetExtension","generateBundle","bundle","existsSync","rmSync","writeFileSync","bundleContent","readFileSync","file","Array","isArray","replacements","length","forEach","entry","replace","banner"],"sources":["index.js"],"mappings":"AAAA,MAAMA,GAAKC,QAAQ,MACnB,MAAMC,KAAOD,QAAQ,QASrBE,OAAOC,QAAU,SAASC,EAAkBC,GAC3CC,KAAKC,KAAO,uBACZ,MAAMC,EAAmBP,KAAKQ,KAAKC,UAAUC,MAAM,WAAW,GAAI,WAClE,MAAMC,EAAsBX,KAAKQ,KAAKD,EAAkB,SAAU,UAAW,YAAa,SAAU,aAAc,UAClH,MAAMK,EAA0BZ,KAAKQ,KAAKG,KAAwBP,EAAQS,gBAAgBH,MAAM,KAAM,gBAEtG,MAAO,CACNJ,KAAM,uBAENQ,eAAeC,GACd,GAAIjB,GAAGkB,WAAWJ,GAClB,CACCd,GAAGmB,OAAOL,EACX,CAEAd,GAAGoB,cAAcN,EAAyB,IAE1C,IAAIO,EAAgBrB,GAAGsB,aAAaL,EAAOM,KAAM,SACjD,GAAIC,MAAMC,QAAQnB,EAAQoB,eAAiBpB,EAAQoB,aAAaC,OAAS,EACzE,CACCrB,EAAQoB,aAAaE,SAASC,IAC7B,GAAIL,MAAMC,QAAQI,IAAUA,EAAMF,OAAS,EAC3C,CACCN,EAAgBA,EAAcS,WAAWD,EAC1C,IAEF,CAEA,UAAWvB,EAAQyB,SAAW,UAAYzB,EAAQyB,OAAOJ,OAAS,EAClE,CACCN,EAAgB,GAAGf,EAAQyB,WAAWV,GACvC,CAEArB,GAAGoB,cAAcN,EAAyBO,EAE3C,EAEF"}
|
||||
@@ -1,2 +0,0 @@
|
||||
const fs=require("fs");const path=require("path");module.exports=function e(n){this.name="web-to-mobile-plugin";const i=path.join(__dirname.split("modules")[0],"modules");const t=path.join(i,"mobile","install","mobileapp","mobile","extensions","bitrix");const s=path.join(t,...n.targetExtension.split("/"),"extension.js");return{name:"web-to-mobile-plugin",generateBundle(e){if(fs.existsSync(s)){fs.rmSync(s)}fs.writeFileSync(s,"");let i=fs.readFileSync(e.file,"ascii");if(Array.isArray(n.replacements)&&n.replacements.length>0){n.replacements.forEach((e=>{if(Array.isArray(e)&&e.length>1){i=i.replace(...e)}}))}if(typeof n.banner==="string"&&n.banner.length>0){i=`${n.banner}\n${i}`}fs.writeFileSync(s,i)}}};
|
||||
//# sourceMappingURL=index.map.js
|
||||
-224
@@ -1,224 +0,0 @@
|
||||
declare module 'ui.buttons'
|
||||
{
|
||||
namespace UI
|
||||
{
|
||||
class BaseButton
|
||||
{
|
||||
constructor(options: { [key: string]: any })
|
||||
render(): HTMLElement
|
||||
renderTo(node: HTMLElement): HTMLElement | null
|
||||
getContainer(): HTMLElement
|
||||
setText(text: string): BaseButton
|
||||
getText(): string
|
||||
getTag(): any
|
||||
setProps(props: { [key: string]: string }): BaseButton
|
||||
getProps(): { [key: string]: string }
|
||||
setDataSet(dataset: { [key: string]: string }): { [key: string]: string }
|
||||
getDataSet(): DOMStringMap
|
||||
addClass(className: string): BaseButton
|
||||
removeClass(className: string): BaseButton
|
||||
setDisabled(state: boolean): BaseButton
|
||||
isDisabled(): boolean
|
||||
isInputType(): boolean
|
||||
bindEvents(events: { [key: string]: () => void }): BaseButton
|
||||
unbindEvents(events: { [key: string]: () => void }): BaseButton
|
||||
bindEvent(event: string, handler: (event: Event) => void): BaseButton
|
||||
unbindEvent(event: string, handler: (event: Event) => void): BaseButton
|
||||
}
|
||||
|
||||
class Button extends BaseButton
|
||||
{
|
||||
static Size: {
|
||||
LARGE: string,
|
||||
MEDIUM: string,
|
||||
SMALL: string,
|
||||
EXTRA_SMALL: string,
|
||||
};
|
||||
|
||||
static Color: {
|
||||
DANGER: string,
|
||||
DANGER_DARK: string,
|
||||
DANGER_LIGHT: string,
|
||||
SUCCESS: string,
|
||||
SUCCESS_LIGHT: string,
|
||||
PRIMARY_DARK: string,
|
||||
PRIMARY: string,
|
||||
SECONDARY: string,
|
||||
LINK: string,
|
||||
LIGHT: string,
|
||||
LIGHT_BORDER: string,
|
||||
};
|
||||
|
||||
static State: {
|
||||
HOVER: string,
|
||||
ACTIVE: string,
|
||||
DISABLED: string,
|
||||
CLOCKING: string,
|
||||
WAITING: string,
|
||||
};
|
||||
|
||||
static Icon: {
|
||||
UNFOLLOW: string,
|
||||
FOLLOW: string,
|
||||
ADD: string,
|
||||
STOP: string,
|
||||
START: string,
|
||||
ADD_FOLDER: string,
|
||||
PAUSE: string,
|
||||
SETTING: string,
|
||||
TASK: string,
|
||||
INFO: string,
|
||||
SEARCH: string,
|
||||
PRINT: string,
|
||||
LIST: string,
|
||||
BUSINESS: string,
|
||||
BUSINESS_CONFIRM: string,
|
||||
BUSINESS_WARNING: string,
|
||||
CAMERA: string,
|
||||
PHONE_UP: string,
|
||||
PHONE_DOWN: string,
|
||||
BACK: string,
|
||||
REMOVE: string,
|
||||
DONE: string,
|
||||
DISK: string,
|
||||
};
|
||||
|
||||
static Tag: {
|
||||
BUTTON: number,
|
||||
LINK: number,
|
||||
SUBMIT: number,
|
||||
INPUT: number,
|
||||
};
|
||||
|
||||
static Style: {
|
||||
NO_CAPS: string,
|
||||
ROUND: string,
|
||||
DROPDOWN: string,
|
||||
};
|
||||
|
||||
setSize(size: string): Button
|
||||
getSize(): string
|
||||
setColor(color: string): Button
|
||||
getColor(): string
|
||||
setIcon(icon: string): Button
|
||||
getIcon(): string
|
||||
setState(state: string): Button
|
||||
getState(): string
|
||||
setNoCaps(value: boolean): Button
|
||||
setRound(value: boolean): Button
|
||||
setDropdown(value: boolean): Button
|
||||
setMenu(options: { [key: string]: any }): Button
|
||||
getMenuBindElement(): HTMLElement
|
||||
getMenuClickElement(): HTMLElement
|
||||
getMenuWindow(): any
|
||||
setId(id: string): Button
|
||||
getId(): string | null
|
||||
setActive(value: boolean): Button
|
||||
isActive(): boolean
|
||||
setHovered(value: boolean): Button
|
||||
isHover(): boolean
|
||||
setDisabled(value: boolean): Button
|
||||
isDisabled(): boolean
|
||||
setWaiting(value: boolean): Button
|
||||
isWaiting(): boolean
|
||||
setClocking(value: boolean): Button
|
||||
isClocking(): boolean
|
||||
setContext(context: any): void
|
||||
getContext(): any
|
||||
}
|
||||
|
||||
class SaveButton extends Button
|
||||
{
|
||||
}
|
||||
|
||||
class CreateButton extends Button
|
||||
{
|
||||
}
|
||||
|
||||
class AddButton extends Button
|
||||
{
|
||||
}
|
||||
|
||||
class SendButton extends Button
|
||||
{
|
||||
}
|
||||
|
||||
class ApplyButton extends Button
|
||||
{
|
||||
}
|
||||
|
||||
class CancelButton extends Button
|
||||
{
|
||||
}
|
||||
|
||||
class CloseButton extends Button
|
||||
{
|
||||
}
|
||||
|
||||
class SplitButton extends Button
|
||||
{
|
||||
static State: {
|
||||
HOVER: string,
|
||||
MAIN_HOVER: string,
|
||||
MENU_HOVER: string,
|
||||
ACTIVE: string,
|
||||
MAIN_ACTIVE: string,
|
||||
MENU_ACTIVE: string,
|
||||
DISABLED: string,
|
||||
MAIN_DISABLED: string,
|
||||
MENU_DISABLED: string,
|
||||
CLOCKING: string,
|
||||
WAITING: string,
|
||||
};
|
||||
|
||||
getMainButton(): SplitSubButton
|
||||
getMenuButton(): SplitSubButton
|
||||
getMenuTarget(): any
|
||||
}
|
||||
|
||||
class SplitSubButton extends BaseButton
|
||||
{
|
||||
static Type: {
|
||||
MAIN: string,
|
||||
MENU: string,
|
||||
};
|
||||
|
||||
setSplitButton(button: SplitButton): SplitSubButton
|
||||
getSplitButton(): SplitButton
|
||||
isMainButton(): boolean
|
||||
isMenuButton(): boolean
|
||||
setActive(value: boolean): SplitSubButton
|
||||
isActive(): boolean
|
||||
setHovered(value: boolean): SplitSubButton
|
||||
isHovered(): boolean
|
||||
}
|
||||
|
||||
class SaveSplitButton extends SplitButton
|
||||
{
|
||||
}
|
||||
|
||||
class CreateSplitButton extends SplitButton
|
||||
{
|
||||
}
|
||||
|
||||
class AddSplitButton extends SplitButton
|
||||
{
|
||||
}
|
||||
|
||||
class SendSplitButton extends SplitButton
|
||||
{
|
||||
}
|
||||
|
||||
class ApplySplitButton extends SplitButton
|
||||
{
|
||||
}
|
||||
|
||||
class CancelSplitButton extends SplitButton
|
||||
{
|
||||
}
|
||||
|
||||
class CloseSplitButton extends SplitButton
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
+8
-1
@@ -1754,7 +1754,8 @@ this.BX = this.BX || {};
|
||||
if (_classStaticPrivateMethodGet(this, ButtonManager$$1, _getCounter).call(this, counterNode)) {
|
||||
var _counterNode;
|
||||
options.rightCounter = {
|
||||
value: _classStaticPrivateMethodGet(this, ButtonManager$$1, _getCounter).call(this, counterNode)
|
||||
value: _classStaticPrivateMethodGet(this, ButtonManager$$1, _getCounter).call(this, counterNode),
|
||||
style: _classStaticPrivateMethodGet(this, ButtonManager$$1, _getCounterStyle).call(this, counterNode)
|
||||
};
|
||||
options.counterNode = undefined;
|
||||
options.counter = undefined;
|
||||
@@ -1874,6 +1875,12 @@ this.BX = this.BX || {};
|
||||
}
|
||||
return null;
|
||||
}
|
||||
function _getCounterStyle(counterNode) {
|
||||
if (!main_core.Type.isDomNode(counterNode)) {
|
||||
return null;
|
||||
}
|
||||
return _classStaticPrivateMethodGet(this, ButtonManager$$1, _getEnumProp).call(this, counterNode, ui_cnt.CounterStyle);
|
||||
}
|
||||
function _getEnumProp(node, enumeration) {
|
||||
for (let key in enumeration) {
|
||||
if (!enumeration.hasOwnProperty(key)) {
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
@@ -2,7 +2,7 @@ import { Type, Reflection, Dom, Runtime, Tag } from 'main.core';
|
||||
import { EventEmitter, BaseEvent } from 'main.core.events';
|
||||
import { MenuItem } from 'main.popup';
|
||||
import { Switcher } from 'ui.switcher';
|
||||
import { Counter } from 'ui.cnt';
|
||||
import { Counter, CounterStyle } from 'ui.cnt';
|
||||
|
||||
import BaseButton from './base-button';
|
||||
import Button from './button/button';
|
||||
@@ -159,6 +159,7 @@ export default class ButtonManager
|
||||
{
|
||||
options.rightCounter = {
|
||||
value: this.#getCounter(counterNode),
|
||||
style: this.#getCounterStyle(counterNode),
|
||||
};
|
||||
|
||||
options.counterNode = undefined;
|
||||
@@ -331,6 +332,21 @@ export default class ButtonManager
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* @private
|
||||
* @param {HTMLElement} counterNode
|
||||
* @return {string | null}
|
||||
*/
|
||||
static #getCounterStyle(counterNode: HTMLElement): string | null
|
||||
{
|
||||
if (!Type.isDomNode(counterNode))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
return this.#getEnumProp(counterNode, CounterStyle);
|
||||
}
|
||||
|
||||
/**
|
||||
* @private
|
||||
* @param {HTMLElement} node
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import type { BaseButtonOptions } from '../base-button-options';
|
||||
import ButtonSize from './button-size';
|
||||
import ButtonStyle from './button-style';
|
||||
import AirButtonStyle from './air-button-style';
|
||||
import ButtonColor from './button-color';
|
||||
import ButtonIcon from './button-icon';
|
||||
import ButtonState from './button-state';
|
||||
@@ -19,8 +21,8 @@ export type ButtonOptions = BaseButtonOptions & {
|
||||
round?: boolean,
|
||||
dropdown?: boolean,
|
||||
dependOnTheme?: boolean,
|
||||
// Use only with useAirTheme: true option
|
||||
style?: boolean;
|
||||
// Use only with useAirDesign: true option
|
||||
style?: ButtonStyle & AirButtonStyle;
|
||||
wide?: boolean;
|
||||
iconPosition?: 'left' | 'right';
|
||||
rightCounter?: CounterOptions;
|
||||
|
||||
@@ -1,782 +0,0 @@
|
||||
/*region Variables*/
|
||||
:root {
|
||||
/*size*/
|
||||
--ui-btn-size-xs: 26px;
|
||||
--ui-btn-size-sm: 31px;
|
||||
--ui-btn-size-md: 39px;
|
||||
--ui-btn-size-lg: 47px;
|
||||
/*default param*/
|
||||
--ui-btn-padding: 0 20px;
|
||||
--ui-btn-padding-right: 20px;
|
||||
--ui-btn-min-width: 80px;
|
||||
--ui-btn-height: var(--ui-btn-size-md);
|
||||
--ui-btn-font-size: 12px;
|
||||
--ui-btn-background: #868d95;
|
||||
--ui-btn-background-hover: #5b6573;
|
||||
--ui-btn-background-active: #3b506e;
|
||||
--ui-btn-border-color: #868d95;
|
||||
--ui-btn-border-color-hover: #5b6573;
|
||||
--ui-btn-border-color-active: #3b506e;
|
||||
--ui-btn-border: 1px solid var(--ui-btn-border-color);
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #fff;
|
||||
--ui-btn-colors-before-bg: #fff;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
--ui-btn-box-shadow: none;
|
||||
--ui-btn-box-shadow-hover: none;
|
||||
--ui-btn-box-shadow-active: none;
|
||||
--ui-btn-text-shadow: none;
|
||||
--ui-btn-text-shadow-hover: none;
|
||||
--ui-btn-text-shadow-active: none;
|
||||
--ui-btn-margin-left: 12px;
|
||||
--ui-btn-radius: 2px;
|
||||
/**/
|
||||
--ui-btn-clock-white: url(/bitrix/js/ui/buttons/src/css/images/ui-loader-clock-white.min.svg?v=1.4);
|
||||
--ui-btn-clock-black: url(/bitrix/js/ui/buttons/src/css/images/ui-loader-clock-black.min.svg?v=1.4);
|
||||
--ui-btn-wait-white: url(/bitrix/js/ui/buttons/src/css/images/ui-loader-wait-white.min.svg?v=1.2);
|
||||
--ui-btn-wait-black: url(/bitrix/js/ui/buttons/src/css/images/ui-loader-wait-black.min.svg?v=1.2);
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Base style*/
|
||||
.ui-btn-container { margin: 15px 0; }
|
||||
|
||||
.ui-btn-container-center { text-align: center; }
|
||||
|
||||
.ui-btn,
|
||||
.ui-btn-main,
|
||||
.ui-btn-extra,
|
||||
.ui-btn-menu {
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
outline: none;
|
||||
height: var(--ui-btn-height);
|
||||
border: var(--ui-btn-border);
|
||||
border-color: var(--ui-btn-border-color);
|
||||
background-color: var(--ui-btn-background);
|
||||
box-shadow: var(--ui-btn-box-shadow);
|
||||
text-shadow: var(--ui-btn-text-shadow);
|
||||
cursor: pointer;
|
||||
transition: 160ms linear background-color,
|
||||
160ms linear color,
|
||||
160ms linear opacity,
|
||||
160ms linear box-shadow,
|
||||
160ms linear border-color;
|
||||
}
|
||||
|
||||
.ui-btn,
|
||||
.ui-btn-main {
|
||||
position: relative;
|
||||
display: -webkit-inline-box;
|
||||
display: -ms-inline-flexbox;
|
||||
display: inline-flex;
|
||||
-ms-flex-pack: center;
|
||||
-webkit-box-pack: center;
|
||||
justify-content: center;
|
||||
-ms-flex-align: center;
|
||||
-webkit-box-align: center;
|
||||
align-items: center;
|
||||
padding: var(--ui-btn-padding);
|
||||
color: var(--ui-btn-color);
|
||||
vertical-align: middle;
|
||||
text-align: center;
|
||||
text-decoration: none;
|
||||
text-transform: uppercase;
|
||||
white-space: nowrap;
|
||||
font: var(--ui-btn-font-size)/calc(var(--ui-btn-height) - 2px) var(--ui-font-family-secondary, var(--ui-font-family-open-sans));
|
||||
font-weight: var(--ui-font-weight-bold, 700);
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.ui-btn,
|
||||
.ui-btn-split {
|
||||
line-height: calc(var(--ui-btn-height) - 2px);
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.ui-btn { border-radius: var(--ui-btn-radius) }
|
||||
|
||||
.ui-btn-min { min-width: var(--ui-btn-min-width); }
|
||||
|
||||
.ui-btn-split {
|
||||
position: relative;
|
||||
display: -webkit-inline-box;
|
||||
display: -ms-inline-flexbox;
|
||||
display: inline-flex;
|
||||
-webkit-box-align: stretch;
|
||||
-ms-flex-align: stretch;
|
||||
align-items: stretch;
|
||||
padding-right: var(--ui-btn-height);
|
||||
border-radius: 3px;
|
||||
}
|
||||
|
||||
.ui-btn-main {
|
||||
padding-right: var(--ui-btn-padding-right);
|
||||
border-right: none !important;
|
||||
border-radius: var(--ui-btn-radius) 0 0 var(--ui-btn-radius);
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.ui-btn-extra,
|
||||
.ui-btn-menu {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
width: var(--ui-btn-height);
|
||||
border-left: none !important;
|
||||
border-radius: 0 var(--ui-btn-radius) var(--ui-btn-radius) 0;
|
||||
}
|
||||
|
||||
.ui-btn:hover,
|
||||
a.ui-btn:focus,
|
||||
.ui-btn-main:hover,
|
||||
.ui-btn-main:focus,
|
||||
.ui-btn-extra:hover,
|
||||
.ui-btn-menu:hover,
|
||||
.ui-btn.ui-btn-hover,
|
||||
.ui-btn-hover .ui-btn-main,
|
||||
.ui-btn-hover .ui-btn-extra,
|
||||
.ui-btn-hover .ui-btn-menu,
|
||||
.ui-btn-main-hover .ui-btn-main,
|
||||
.ui-btn-extra-hover .ui-btn-extra,
|
||||
.ui-btn-menu-hover .ui-btn-menu {
|
||||
border-color: var(--ui-btn-border-color-hover);
|
||||
background-color: var(--ui-btn-background-hover);
|
||||
box-shadow: var(--ui-btn-box-shadow-hover);
|
||||
color: var(--ui-btn-color-hover);
|
||||
text-decoration: none;
|
||||
text-shadow: var(--ui-btn-text-shadow-hover);
|
||||
}
|
||||
|
||||
.ui-btn:active,
|
||||
a.ui-btn:focus,
|
||||
a.ui-btn-split:focus,
|
||||
.ui-btn-main:active,
|
||||
.ui-btn-menu:active,
|
||||
.ui-btn-extra:active,
|
||||
.ui-btn-wait.ui-btn,
|
||||
.ui-btn-wait .ui-btn-main,
|
||||
.ui-btn-clock.ui-btn,
|
||||
.ui-btn-clock .ui-btn-main,
|
||||
.ui-btn-active.ui-btn,
|
||||
.ui-btn-active .ui-btn-main,
|
||||
.ui-btn-active .ui-btn-menu,
|
||||
.ui-btn-active .ui-btn-extra,
|
||||
.ui-btn-main-active .ui-btn-main,
|
||||
.ui-btn-menu-active .ui-btn-menu,
|
||||
.ui-btn-extra-active .ui-btn-extra,
|
||||
.ui-btn-wait.ui-btn:hover,
|
||||
.ui-btn-wait .ui-btn-main:hover,
|
||||
.ui-btn-clock.ui-btn:hover,
|
||||
.ui-btn-clock .ui-btn-main:hover,
|
||||
.ui-btn-active.ui-btn:hover,
|
||||
.ui-btn-active .ui-btn-main:hover,
|
||||
.ui-btn-active .ui-btn-menu:hover,
|
||||
.ui-btn-active .ui-btn-extra:hover,
|
||||
.ui-btn-main-active .ui-btn-main:hover,
|
||||
.ui-btn-menu-active .ui-btn-menu:hover,
|
||||
.ui-btn-extra-active .ui-btn-extra:hover {
|
||||
outline: none;
|
||||
border-color: var(--ui-btn-border-color-active);
|
||||
background-color: var(--ui-btn-background-active);
|
||||
box-shadow: var(--ui-btn-box-shadow-active);
|
||||
color: var(--ui-btn-color-active);
|
||||
text-shadow: var(--ui-btn-text-shadow-active);
|
||||
}
|
||||
|
||||
.ui-btn-extra:after,
|
||||
.ui-btn-menu:after {
|
||||
position: absolute;
|
||||
top: 7px;
|
||||
bottom: 6px;
|
||||
left: 0;
|
||||
width: 1px;
|
||||
background-color: var(--ui-btn-colors-after-bg);
|
||||
content: '';
|
||||
opacity: var(--ui-btn-opacity-after);
|
||||
}
|
||||
|
||||
.ui-btn-extra:before,
|
||||
.ui-btn-menu:before {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
box-sizing: border-box;
|
||||
margin-top: -2px;
|
||||
margin-left: -4px;
|
||||
width: 8px;
|
||||
border: 4px solid transparent;
|
||||
border-top-color: var(--ui-btn-colors-before-bg);
|
||||
background: none;
|
||||
content: '';
|
||||
transition: 160ms background-color linear, 160ms color linear, 160ms opacity linear, 160ms border-color linear;
|
||||
}
|
||||
|
||||
.ui-btn + .ui-btn,
|
||||
.ui-btn + .ui-btn-split,
|
||||
.ui-btn-split + .ui-btn,
|
||||
.ui-btn-split + .ui-btn-split,
|
||||
.ui-btn + script + .ui-btn,
|
||||
.ui-btn + script + .ui-btn-split,
|
||||
.ui-btn-split + script + .ui-btn,
|
||||
.ui-btn-split + script + .ui-btn-split,
|
||||
.ui-ctl + .ui-btn,
|
||||
.ui-ctl + .ui-btn-split { margin-left: var(--ui-btn-margin-left); }
|
||||
|
||||
.ui-btn-text {
|
||||
overflow: hidden;
|
||||
max-width: 100%;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
display: block;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Size*/
|
||||
.ui-btn-md {
|
||||
--ui-btn-padding: 0 19px;
|
||||
--ui-btn-padding-right: 12px;
|
||||
--ui-btn-min-width: 80px;
|
||||
--ui-btn-height: var(--ui-btn-size-md);
|
||||
--ui-btn-font-size: 12px;
|
||||
}
|
||||
|
||||
.ui-btn-lg {
|
||||
--ui-btn-padding: 0 26px;
|
||||
--ui-btn-padding-right: 12px;
|
||||
--ui-btn-min-width: 90px;
|
||||
--ui-btn-height: var(--ui-btn-size-lg);
|
||||
--ui-btn-font-size: 12px;
|
||||
}
|
||||
|
||||
.ui-btn-sm {
|
||||
--ui-btn-padding: 0 17px;
|
||||
--ui-btn-padding-right: 10px;
|
||||
--ui-btn-min-width: 70px;
|
||||
--ui-btn-height: var(--ui-btn-size-sm);
|
||||
--ui-btn-font-size: 12px;
|
||||
}
|
||||
|
||||
.ui-btn-xs {
|
||||
--ui-btn-padding: 0 15px;
|
||||
--ui-btn-padding-right: 9px;
|
||||
--ui-btn-min-width: 66px;
|
||||
--ui-btn-height: var(--ui-btn-size-xs);
|
||||
--ui-btn-font-size: 11px;
|
||||
}
|
||||
|
||||
.ui-btn-split.ui-btn-lg { padding-right: 33px; }
|
||||
|
||||
.ui-btn-lg.ui-btn:not(.ui-btn-round) { --ui-btn-radius: 3px; }
|
||||
|
||||
.ui-btn-lg:not(.ui-btn-round) .ui-btn-main { --ui-btn-radius: 3px; }
|
||||
|
||||
.ui-btn-lg.ui-btn-split { padding-right: 34px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-extra,
|
||||
.ui-btn-lg .ui-btn-menu { width: 34px; }
|
||||
|
||||
.ui-btn-lg:not(.ui-btn-round) .ui-btn-extra,
|
||||
.ui-btn-lg:not(.ui-btn-round) .ui-btn-menu { --ui-btn-radius: 3px; }
|
||||
|
||||
.ui-btn-sm.ui-btn-split { padding-right: 28px; }
|
||||
|
||||
.ui-btn-sm .ui-btn-extra,
|
||||
.ui-btn-sm .ui-btn-menu { width: 28px; }
|
||||
|
||||
.ui-btn-sm:not(.ui-btn-round) .ui-btn-extra,
|
||||
.ui-btn-sm:not(.ui-btn-round) .ui-btn-menu { --ui-btn-radius: 3px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-extra:before,
|
||||
.ui-btn-lg .ui-btn-menu:before { margin-top: -3px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-extra:after,
|
||||
.ui-btn-lg .ui-btn-menu:after {
|
||||
top: 11px;
|
||||
bottom: 10px;
|
||||
opacity: .25;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Colors*/
|
||||
/*region Color Variables*/
|
||||
.ui-btn-default { /* default variables */ }
|
||||
|
||||
.ui-btn-success {
|
||||
--ui-btn-background: #bbed21;
|
||||
--ui-btn-background-hover: #d2f95f;
|
||||
--ui-btn-background-active: #b2e232;
|
||||
--ui-btn-border-color: #bbed21;
|
||||
--ui-btn-border-color-hover: #d2f95f;
|
||||
--ui-btn-border-color-active: #b2e232;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #535c69;
|
||||
--ui-btn-color-active: #535c69;
|
||||
}
|
||||
|
||||
.ui-btn-success-light {
|
||||
--ui-btn-background: #e1f0b1;
|
||||
--ui-btn-background-hover: #eaf5c5;
|
||||
--ui-btn-background-active: #d3e59a;
|
||||
--ui-btn-border-color: #e1f0b1;
|
||||
--ui-btn-border-color-hover: #eaf5c5;
|
||||
--ui-btn-border-color-active: #d3e59a;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #333;
|
||||
--ui-btn-colors-before-bg: #a3bf63;
|
||||
--ui-btn-color: #668d13;
|
||||
--ui-btn-color-hover: #668d13;
|
||||
--ui-btn-color-active: #668d13;
|
||||
}
|
||||
|
||||
.ui-btn-success-dark {
|
||||
--ui-btn-background: #86a732;
|
||||
--ui-btn-background-hover: #a2bf54;
|
||||
--ui-btn-background-active: #a2bf54;
|
||||
--ui-btn-border-color: #86a732;
|
||||
--ui-btn-border-color-hover: #a2bf54;
|
||||
--ui-btn-border-color-active: #a2bf54;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #fff;
|
||||
--ui-btn-colors-before-bg: #a3bf63;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-danger {
|
||||
--ui-btn-background: #f1361a;
|
||||
--ui-btn-background-hover: #cc1c00;
|
||||
--ui-btn-background-active: #d24430;
|
||||
--ui-btn-border-color: #f1361a;
|
||||
--ui-btn-border-color-hover: #cc1c00;
|
||||
--ui-btn-border-color-active: #d24430;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-danger-dark {
|
||||
--ui-btn-background: #a21429;
|
||||
--ui-btn-background-hover: #c43d51;
|
||||
--ui-btn-background-active: #c43d51;
|
||||
--ui-btn-border-color: #a21429;
|
||||
--ui-btn-border-color-hover: #c43d51;
|
||||
--ui-btn-border-color-active: #c43d51;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-danger-light {
|
||||
--ui-btn-background: #ffccca;
|
||||
--ui-btn-background-hover: #ffdcdb;
|
||||
--ui-btn-background-active: #f2b6b3;
|
||||
--ui-btn-border-color: #ffccca;
|
||||
--ui-btn-border-color-hover: #ffdcdb;
|
||||
--ui-btn-border-color-active: #f2b6b3;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #333;
|
||||
--ui-btn-colors-before-bg: #eb8783;
|
||||
--ui-btn-color: #d7413c;
|
||||
--ui-btn-color-hover: #d7413c;
|
||||
--ui-btn-color-active: #d7413c;
|
||||
}
|
||||
|
||||
.ui-btn-primary {
|
||||
--ui-btn-background: #3bc8f5;
|
||||
--ui-btn-background-hover: #3eddff;
|
||||
--ui-btn-background-active: #12b1e3;
|
||||
--ui-btn-border-color: #3bc8f5;
|
||||
--ui-btn-border-color-hover: #3eddff;
|
||||
--ui-btn-border-color-active: #12b1e3;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-primary-dark {
|
||||
--ui-btn-background: #399fc2;
|
||||
--ui-btn-background-hover: #37aed4;
|
||||
--ui-btn-background-active: #37aed4;
|
||||
--ui-btn-border-color: #399fc2;
|
||||
--ui-btn-border-color-hover: #37aed4;
|
||||
--ui-btn-border-color-active: #37aed4;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-secondary {
|
||||
--ui-btn-background: #c5e7f4;
|
||||
--ui-btn-background-hover: #d1eef9;
|
||||
--ui-btn-background-active: #aee0f2;
|
||||
--ui-btn-border-color: #aee0f2;
|
||||
--ui-btn-border-color-hover: #aee0f2;
|
||||
--ui-btn-border-color-active: #aee0f2;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #535c69;
|
||||
--ui-btn-color-active: #535c69;
|
||||
}
|
||||
|
||||
.ui-btn-link {
|
||||
--ui-btn-background: transparent;
|
||||
--ui-btn-background-hover: transparent;
|
||||
--ui-btn-background-active: transparent;
|
||||
--ui-btn-border-color: transparent;
|
||||
--ui-btn-border-color-hover: transparent;
|
||||
--ui-btn-border-color-active: transparent;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #80868e;
|
||||
--ui-btn-color-active: #535c69;
|
||||
}
|
||||
|
||||
.ui-btn-light {
|
||||
--ui-btn-background: transparent;
|
||||
--ui-btn-background-hover: #f6f8f9;
|
||||
--ui-btn-background-active: #d6f1fb;
|
||||
--ui-btn-border-color: transparent;
|
||||
--ui-btn-border-color-hover: #f6f8f9;
|
||||
--ui-btn-border-color-active: #d6f1fb;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #333;
|
||||
--ui-btn-color-active: #000;
|
||||
--ui-btn-padding: 0 6px;
|
||||
/*--ui-btn-margin-left: 18px;*/
|
||||
}
|
||||
|
||||
.ui-btn-light-border {
|
||||
--ui-btn-background: transparent;
|
||||
--ui-btn-background-hover: #cfd4d8;
|
||||
--ui-btn-background-active: #dde2e5;
|
||||
--ui-btn-border-color: #c6cdd3;
|
||||
--ui-btn-border-color-hover: #c6cdd3;
|
||||
--ui-btn-border-color-active: #9fa4ab;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535b69;
|
||||
--ui-btn-color-hover: #535b69;
|
||||
--ui-btn-color-active: #535b69;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Button Color*/
|
||||
/*region Link button*/
|
||||
.ui-btn-link.ui-btn {
|
||||
padding-right: 0;
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
.ui-btn-link .ui-btn-main { padding-left: 0; }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Light-border button*/
|
||||
/*region Fix for Themes*/
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-link {
|
||||
--ui-btn-color: #ebebeb;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-light,
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-light-border {
|
||||
--ui-btn-background: rgba(255, 255, 255, .15);
|
||||
--ui-btn-background-hover: rgba(255, 255, 255, .3);
|
||||
--ui-btn-background-active: rgba(255, 255, 255, .4);
|
||||
--ui-btn-colors-after-bg: #fff;
|
||||
--ui-btn-colors-before-bg: #fff;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-light-border { --ui-btn-border-color: rgba(255, 255, 255, .4); }
|
||||
|
||||
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-link {
|
||||
--ui-btn-color: rgba(51, 51, 51, .8);
|
||||
--ui-btn-color-hover: rgba(51, 51, 51, .8);;
|
||||
--ui-btn-color-active: rgba(51, 51, 51, .8);;
|
||||
}
|
||||
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-light,
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-light-border {
|
||||
--ui-btn-background: rgba(0, 0, 0, .07);
|
||||
--ui-btn-background-hover: rgba(0, 0, 0, .1);
|
||||
--ui-btn-background-active: rgba(0, 0, 0, .15);
|
||||
--ui-btn-colors-after-bg: rgba(51, 51, 51, .8);
|
||||
--ui-btn-colors-before-bg: rgba(51, 51, 51, .8);
|
||||
--ui-btn-color: rgba(51, 51, 51, .8);
|
||||
--ui-btn-color-hover: rgba(51, 51, 51, .8);;
|
||||
--ui-btn-color-active: rgba(51, 51, 51, .8);;
|
||||
}
|
||||
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-light-border { --ui-btn-border-color: rgba(0, 0, 0, .06); }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Others*/
|
||||
.ui-btn-round { --ui-btn-radius: calc(var(--ui-btn-height) / 2); }
|
||||
|
||||
.ui-btn-no-caps,
|
||||
.ui-btn-no-caps .ui-btn-main {
|
||||
text-transform: none;
|
||||
font-size: calc(var(--ui-btn-font-size) + 2px);
|
||||
font-family: var(--ui-font-family-secondary, var(--ui-font-family-open-sans));
|
||||
font-weight: var(--ui-font-weight-semi-bold, 600);
|
||||
}
|
||||
|
||||
|
||||
.ui-btn-shadow,
|
||||
.ui-btn-shadow:hover,
|
||||
.ui-btn-shadow.ui-btn-hover { box-shadow: 0 1px 2px 0 rgba(0,0,0,0.18); }
|
||||
|
||||
.ui-btn-shadow:active,
|
||||
.ui-btn-shadow.ui-btn-active { box-shadow: 0 0 1px 0 rgba(0,0,0,0.18); }
|
||||
|
||||
/*region Counter*/
|
||||
.ui-btn-counter {
|
||||
display: inline-block;
|
||||
padding: 0 8px;
|
||||
border-radius: 10px;
|
||||
background-color: #f34829;
|
||||
color: #fff;
|
||||
vertical-align: middle;
|
||||
font: 11px/19px var(--ui-font-family-secondary, var(--ui-font-family-open-sans));
|
||||
font-weight: var(--ui-font-weight-regular, 400);
|
||||
}
|
||||
|
||||
.ui-btn-text + .ui-btn-counter { margin-left: 12px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-counter { margin-left: 15px; }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Dropdown*/
|
||||
.ui-btn.ui-btn-dropdown,
|
||||
.ui-btn-dropdown .ui-btn-main { padding-right: 29px; }
|
||||
|
||||
.ui-btn.ui-btn-dropdown:before,
|
||||
.ui-btn-dropdown .ui-btn-main:before {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
right: 13px;
|
||||
display: block;
|
||||
box-sizing: border-box;
|
||||
margin-top: -1.5px;
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
border-bottom: 2px solid;
|
||||
border-left: 2px solid;
|
||||
content: '';
|
||||
transform: translateY(-50%) rotate(-45deg);
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-dropdown:before,
|
||||
.ui-btn-dropdown .ui-btn-main:before { border-color: var(--ui-btn-color); }
|
||||
|
||||
.ui-btn.ui-btn-empty.ui-btn-dropdown:before,
|
||||
.ui-btn.ui-btn-collapsed.ui-btn-dropdown:before,
|
||||
.ui-btn-empty.ui-btn-dropdown .ui-btn-main:before,
|
||||
.ui-btn-collapsed.ui-btn-dropdown .ui-btn-main:before {
|
||||
right: auto;
|
||||
transform: translate(-50%, -50%) rotate(-45deg);
|
||||
left: 50%;
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-empty.ui-btn-dropdown[class*="ui-btn-icon-"]:before,
|
||||
.ui-btn.ui-btn-collapsed.ui-btn-dropdown[class*="ui-btn-icon-"]:before,
|
||||
.ui-btn-empty.ui-btn-dropdown[class*="ui-btn-icon-"] .ui-btn-main:before,
|
||||
.ui-btn-collapsed.ui-btn-dropdown[class*="ui-btn-icon-"] .ui-btn-main:before {
|
||||
right: 12px;
|
||||
transform: translateY(-50%) rotate(-45deg);
|
||||
left: auto;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Disabled*/
|
||||
.ui-btn.ui-btn-disabled,
|
||||
.ui-btn.ui-btn-disabled:hover,
|
||||
.ui-btn.ui-btn-disabled:active,
|
||||
.ui-btn[disabled],
|
||||
.ui-btn[disabled]:hover,
|
||||
.ui-btn[disabled]:active,
|
||||
.ui-btn-disabled .ui-btn-main,
|
||||
.ui-btn-disabled .ui-btn-main:hover,
|
||||
.ui-btn-disabled .ui-btn-main:active,
|
||||
.ui-btn-disabled .ui-btn-extra,
|
||||
.ui-btn-disabled .ui-btn-extra:hover,
|
||||
.ui-btn-disabled .ui-btn-extra:active,
|
||||
.ui-btn-disabled .ui-btn-menu,
|
||||
.ui-btn-disabled .ui-btn-menu:hover,
|
||||
.ui-btn-disabled .ui-btn-menu:active,
|
||||
.ui-btn-main-disabled .ui-btn-main,
|
||||
.ui-btn-main-disabled .ui-btn-main:hover,
|
||||
.ui-btn-main-disabled .ui-btn-main:active,
|
||||
.ui-btn-extra-disabled .ui-btn-extra,
|
||||
.ui-btn-extra-disabled .ui-btn-extra:hover,
|
||||
.ui-btn-extra-disabled .ui-btn-extra:active,
|
||||
.ui-btn-menu-disabled .ui-btn-menu,
|
||||
.ui-btn-menu-disabled .ui-btn-menu:hover,
|
||||
.ui-btn-menu-disabled .ui-btn-menu:active {
|
||||
opacity: .4;
|
||||
cursor: not-allowed;
|
||||
background-color: var(--ui-btn-background);
|
||||
border-color: var(--ui-btn-border-color);
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Wait*/
|
||||
.ui-btn.ui-btn-wait,
|
||||
.ui-btn-wait .ui-btn-main {
|
||||
background-position: center !important;
|
||||
background-repeat: no-repeat !important;
|
||||
color: transparent !important;
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-wait:after,
|
||||
.ui-btn-wait .ui-btn-main:after { opacity: 0; }
|
||||
|
||||
.ui-btn-wait,
|
||||
.ui-btn-wait.ui-btn-danger,
|
||||
.ui-btn-wait.ui-btn-primary,
|
||||
.ui-btn-wait.ui-btn-default,
|
||||
.ui-btn-wait.ui-btn-danger-dark,
|
||||
.ui-btn-wait.ui-btn-success-dark,
|
||||
.ui-btn-wait.ui-btn-primary-dark { --ui-btn-wait-loader: var(--ui-btn-wait-white); }
|
||||
|
||||
.ui-btn-wait.ui-btn-link,
|
||||
.ui-btn-wait.ui-btn-secondary,
|
||||
.ui-btn-wait.ui-btn-light,
|
||||
.ui-btn-wait.ui-btn-success,
|
||||
.ui-btn-wait.ui-btn-light-border,
|
||||
.ui-btn-wait.ui-btn-link { --ui-btn-wait-loader: var(--ui-btn-wait-black); }
|
||||
|
||||
.ui-btn.ui-btn-wait,
|
||||
.ui-btn-wait .ui-btn-main { background-image: var(--ui-btn-wait-loader); }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Clock*/
|
||||
.ui-btn.ui-btn-clock,
|
||||
.ui-btn-split.ui-btn-clock .ui-btn-main {
|
||||
background-position: center !important;
|
||||
background-repeat: no-repeat !important;
|
||||
color: transparent !important;
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-clock:after,
|
||||
.ui-btn-split.ui-btn-clock .ui-btn-main:after { opacity: 0; }
|
||||
|
||||
.ui-btn-clock,
|
||||
.ui-btn-clock.ui-btn-danger,
|
||||
.ui-btn-clock.ui-btn-primary,
|
||||
.ui-btn-clock.ui-btn-default,
|
||||
.ui-btn-clock.ui-btn-danger-dark,
|
||||
.ui-btn-clock.ui-btn-success-dark,
|
||||
.ui-btn-clock.ui-btn-primary-dark { --ui-btn-clock-loader: var(--ui-btn-clock-white); }
|
||||
|
||||
.ui-btn-clock.ui-btn-link,
|
||||
.ui-btn-clock.ui-btn-secondary,
|
||||
.ui-btn-clock.ui-btn-light,
|
||||
.ui-btn-clock.ui-btn-success,
|
||||
.ui-btn-clock.ui-btn-light-border,
|
||||
.ui-btn-clock.ui-btn-link { --ui-btn-clock-loader: var(--ui-btn-clock-black); }
|
||||
|
||||
.ui-btn.ui-btn-clock,
|
||||
.ui-btn-clock .ui-btn-main { background-image: var(--ui-btn-clock-loader); }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Links*/
|
||||
:root {
|
||||
--ui-link-color: #216bb6;
|
||||
--ui-link-border-color: #216bb6;
|
||||
}
|
||||
|
||||
.ui-link,
|
||||
*.ui-link:hover {
|
||||
cursor: pointer;
|
||||
font: 13px/22px var(--ui-font-family-primary, var(--ui-font-family-helvetica));
|
||||
color: var(--ui-link-color);
|
||||
transition: 250ms linear color, 250ms linear border-color;
|
||||
}
|
||||
|
||||
.ui-link + .ui-link,
|
||||
.ui-link + script + .ui-link { margin-left: 12px; }
|
||||
|
||||
.ui-link,
|
||||
.ui-link-primary {
|
||||
--ui-link-color: #216bb6;
|
||||
--ui-link-border-color: #216bb6
|
||||
}
|
||||
|
||||
.ui-link:hover,
|
||||
.ui-link-primary:hover {
|
||||
--ui-link-color: #2067b0;
|
||||
--ui-link-border-color: #2067b0
|
||||
}
|
||||
|
||||
.ui-link-secondary {
|
||||
--ui-link-color: #80868e;
|
||||
--ui-link-border-color: #d8d8d8
|
||||
}
|
||||
|
||||
.ui-link-secondary:hover {
|
||||
--ui-link-color: #333;
|
||||
--ui-link-border-color: #333
|
||||
}
|
||||
|
||||
.ui-link-dark {
|
||||
--ui-link-color: #333;
|
||||
--ui-link-border-color: #333
|
||||
}
|
||||
|
||||
.ui-link-dark:hover {
|
||||
--ui-link-color: #000;
|
||||
--ui-link-border-color: #000
|
||||
}
|
||||
|
||||
.ui-link-solid { border-bottom: 1px solid var(--ui-link-border-color); }
|
||||
|
||||
.ui-link-dashed { border-bottom: 1px dashed var(--ui-link-border-color); }
|
||||
|
||||
.ui-link-dotted { border-bottom: 1px dotted var(--ui-link-border-color); }
|
||||
|
||||
/*endregion*/
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,711 +0,0 @@
|
||||
/*region Variables*/
|
||||
:root {
|
||||
/*size*/
|
||||
--ui-btn-size-xs: 26px;
|
||||
--ui-btn-size-sm: 31px;
|
||||
--ui-btn-size-md: 39px;
|
||||
--ui-btn-size-lg: 47px;
|
||||
/*default param*/
|
||||
--ui-btn-padding: 0 20px;
|
||||
--ui-btn-padding-right: 20px;
|
||||
--ui-btn-min-width: 80px;
|
||||
--ui-btn-height: var(--ui-btn-size-md);
|
||||
--ui-btn-font-size: 12px;
|
||||
--ui-btn-background: #868d95;
|
||||
--ui-btn-background-hover: #5b6573;
|
||||
--ui-btn-background-active: #3b506e;
|
||||
--ui-btn-border-color: #868d95;
|
||||
--ui-btn-border-color-hover: #5b6573;
|
||||
--ui-btn-border-color-active: #3b506e;
|
||||
--ui-btn-border: 1px solid var(--ui-btn-border-color);
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #fff;
|
||||
--ui-btn-colors-before-bg: #fff;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
--ui-btn-box-shadow: none;
|
||||
--ui-btn-box-shadow-hover: none;
|
||||
--ui-btn-box-shadow-active: none;
|
||||
--ui-btn-text-shadow: none;
|
||||
--ui-btn-text-shadow-hover: none;
|
||||
--ui-btn-text-shadow-active: none;
|
||||
/**/
|
||||
--ui-btn-clock-white: url(/bitrix/js/ui/buttons/images/ui-loader-clock-white.min.svg?v=1.1);
|
||||
--ui-btn-clock-black: url(/bitrix/js/ui/buttons/images/ui-loader-clock-black.min.svg?v=1.1);
|
||||
--ui-btn-wait-white: url(/bitrix/js/ui/buttons/images/ui-loader-wait-white.min.svg?v=1.1);
|
||||
--ui-btn-wait-black: url(/bitrix/js/ui/buttons/images/ui-loader-wait-black.min.svg?v=1.1);
|
||||
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Base style*/
|
||||
.ui-btn-container { margin: 15px 0; }
|
||||
|
||||
.ui-btn-container-center { text-align: center; }
|
||||
|
||||
.ui-btn,
|
||||
.ui-btn-main,
|
||||
.ui-btn-extra,
|
||||
.ui-btn-menu {
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
height: var(--ui-btn-height);
|
||||
outline: none;
|
||||
border: var(--ui-btn-border);
|
||||
border-color: var(--ui-btn-border-color);
|
||||
background-color: var(--ui-btn-background);
|
||||
box-shadow: var(--ui-btn-box-shadow);
|
||||
text-shadow: var(--ui-btn-text-shadow);
|
||||
cursor: pointer;
|
||||
transition: 160ms background-color linear, 160ms color linear, 160ms opacity linear, 160ms border-color linear;
|
||||
}
|
||||
|
||||
.ui-btn,
|
||||
.ui-btn-main {
|
||||
position: relative;
|
||||
display: -webkit-inline-box;
|
||||
display: -ms-inline-flexbox;
|
||||
display: inline-flex;
|
||||
-webkit-box-align: center;
|
||||
-ms-flex-align: center;
|
||||
align-items: center;
|
||||
padding: var(--ui-btn-padding);
|
||||
color: var(--ui-btn-color);
|
||||
vertical-align: middle;
|
||||
text-align: center;
|
||||
text-decoration: none;
|
||||
text-transform: uppercase;
|
||||
white-space: nowrap;
|
||||
font: var(--ui-btn-font-size)/calc(var(--ui-btn-height) - 2px) "OpenSans-Bold", "Helvetica Neue", Helvetica, Arial, sans-serif;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.ui-btn,
|
||||
.ui-btn-double,
|
||||
.ui-btn-split {
|
||||
line-height: calc(var(--ui-btn-height) - 2px);
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.ui-btn {
|
||||
min-width: var(--ui-btn-min-width);
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
.ui-btn-double,
|
||||
.ui-btn-split {
|
||||
position: relative;
|
||||
display: -webkit-inline-box;
|
||||
display: -ms-inline-flexbox;
|
||||
display: inline-flex;
|
||||
-webkit-box-align: stretch;
|
||||
-ms-flex-align: stretch;
|
||||
align-items: stretch;
|
||||
padding-right: 30px;
|
||||
border-radius: 3px;
|
||||
}
|
||||
|
||||
.ui-btn-main {
|
||||
padding-right: var(--ui-btn-padding-right);
|
||||
border-right: none !important;
|
||||
border-radius: 2px 0 0 2px;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.ui-btn-extra,
|
||||
.ui-btn-menu {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
width: 30px;
|
||||
border-left: none !important;
|
||||
border-radius: 0 2px 2px 0;
|
||||
}
|
||||
|
||||
.ui-btn:hover,
|
||||
a.ui-btn:focus,
|
||||
.ui-btn-main:hover,
|
||||
.ui-btn-main:focus,
|
||||
.ui-btn-extra:hover,
|
||||
.ui-btn-menu:hover,
|
||||
.ui-btn.ui-btn-hover,
|
||||
.ui-btn-hover .ui-btn-main,
|
||||
.ui-btn-hover .ui-btn-extra,
|
||||
.ui-btn-hover .ui-btn-menu,
|
||||
.ui-btn-main-hover .ui-btn-main,
|
||||
.ui-btn-extra-hover .ui-btn-extra,
|
||||
.ui-btn-menu-hover .ui-btn-menu {
|
||||
border-color: var(--ui-btn-border-color-hover);
|
||||
background-color: var(--ui-btn-background-hover);
|
||||
box-shadow: var(--ui-btn-box-shadow-hover);
|
||||
color: var(--ui-btn-color-hover);
|
||||
text-decoration: none;
|
||||
text-shadow: var(--ui-btn-text-shadow-hover);
|
||||
}
|
||||
|
||||
.ui-btn:active,
|
||||
a.ui-btn:focus,
|
||||
a.ui-btn-split:focus,
|
||||
a.ui-btn-double:focus,
|
||||
.ui-btn-main:active,
|
||||
.ui-btn-menu:active,
|
||||
.ui-btn-extra:active,
|
||||
.ui-btn-wait.ui-btn,
|
||||
.ui-btn-wait .ui-btn-main,
|
||||
.ui-btn-clock.ui-btn,
|
||||
.ui-btn-clock .ui-btn-main,
|
||||
.ui-btn-active.ui-btn,
|
||||
.ui-btn-active .ui-btn-main,
|
||||
.ui-btn-active .ui-btn-menu,
|
||||
.ui-btn-active .ui-btn-extra,
|
||||
.ui-btn-main-active .ui-btn-main,
|
||||
.ui-btn-menu-active .ui-btn-menu,
|
||||
.ui-btn-extra-active .ui-btn-extra,
|
||||
.ui-btn-wait.ui-btn:hover,
|
||||
.ui-btn-wait .ui-btn-main:hover,
|
||||
.ui-btn-clock.ui-btn:hover,
|
||||
.ui-btn-clock .ui-btn-main:hover,
|
||||
.ui-btn-active.ui-btn:hover,
|
||||
.ui-btn-active .ui-btn-main:hover,
|
||||
.ui-btn-active .ui-btn-menu:hover,
|
||||
.ui-btn-active .ui-btn-extra:hover,
|
||||
.ui-btn-main-active .ui-btn-main:hover,
|
||||
.ui-btn-menu-active .ui-btn-menu:hover,
|
||||
.ui-btn-extra-active .ui-btn-extra:hover {
|
||||
outline: none;
|
||||
border-color: var(--ui-btn-border-color-active);
|
||||
background-color: var(--ui-btn-background-active);
|
||||
box-shadow: var(--ui-btn-box-shadow-active);
|
||||
color: var(--ui-btn-color-active);
|
||||
text-shadow: var(--ui-btn-text-shadow-active);
|
||||
}
|
||||
|
||||
.ui-btn-extra:after,
|
||||
.ui-btn-menu:after {
|
||||
position: absolute;
|
||||
top: 7px;
|
||||
bottom: 6px;
|
||||
left: 0;
|
||||
width: 1px;
|
||||
background-color: var(--ui-btn-colors-after-bg);
|
||||
content: '';
|
||||
opacity: var(--ui-btn-opacity-after);
|
||||
}
|
||||
|
||||
.ui-btn-extra:before,
|
||||
.ui-btn-menu:before {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
box-sizing: border-box;
|
||||
margin-top: -2px;
|
||||
margin-left: -4px;
|
||||
width: 8px;
|
||||
border: 4px solid transparent;
|
||||
border-top-color: var(--ui-btn-colors-before-bg);
|
||||
background: none;
|
||||
content: '';
|
||||
transition: 160ms background-color linear, 160ms color linear, 160ms opacity linear, 160ms border-color linear;
|
||||
}
|
||||
|
||||
.ui-btn + .ui-btn,
|
||||
.ui-btn + .ui-btn-double,
|
||||
.ui-btn-double + .ui-btn,
|
||||
.ui-btn-double + .ui-btn-double,
|
||||
.ui-btn + .ui-btn-split,
|
||||
.ui-btn-split + .ui-btn,
|
||||
.ui-btn-split + .ui-btn-split,
|
||||
.ui-btn + script + .ui-btn,
|
||||
.ui-btn + script + .ui-btn-split,
|
||||
.ui-btn-split + script + .ui-btn,
|
||||
.ui-btn-split + script + .ui-btn-split,
|
||||
.ui-ctl + .ui-btn,
|
||||
.ui-ctl + .ui-btn-double,
|
||||
.ui-ctl + .ui-btn-split { margin-left: 12px; }
|
||||
|
||||
.ui-btn-text {
|
||||
overflow: hidden;
|
||||
max-width: 100%;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
display: block;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Size*/
|
||||
.ui-btn-md {
|
||||
--ui-btn-padding: 0 19px;
|
||||
--ui-btn-padding-right: 12px;
|
||||
--ui-btn-min-width: 80px;
|
||||
--ui-btn-height: var(--ui-btn-size-md);
|
||||
--ui-btn-font-size: 12px;
|
||||
}
|
||||
|
||||
.ui-btn-lg {
|
||||
--ui-btn-padding: 0 26px;
|
||||
--ui-btn-padding-right: 12px;
|
||||
--ui-btn-min-width: 90px;
|
||||
--ui-btn-height: var(--ui-btn-size-lg);
|
||||
--ui-btn-font-size: 12px;
|
||||
}
|
||||
|
||||
.ui-btn-sm {
|
||||
--ui-btn-padding: 0 17px;
|
||||
--ui-btn-padding-right: 10px;
|
||||
--ui-btn-min-width: 70px;
|
||||
--ui-btn-height: var(--ui-btn-size-sm);
|
||||
--ui-btn-font-size: 12px;
|
||||
}
|
||||
|
||||
.ui-btn-xs {
|
||||
--ui-btn-padding: 0 15px;
|
||||
--ui-btn-padding-right: 9px;
|
||||
--ui-btn-min-width: 66px;
|
||||
--ui-btn-height: var(--ui-btn-size-xs);
|
||||
--ui-btn-font-size: 11px;
|
||||
}
|
||||
|
||||
.ui-btn-double.ui-btn-lg,
|
||||
.ui-btn-split.ui-btn-lg { padding-right: 33px; }
|
||||
|
||||
.ui-btn-lg.ui-btn { border-radius: 3px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-main { border-radius: 3px 0 0 3px; }
|
||||
|
||||
.ui-btn-lg.ui-btn-double,
|
||||
.ui-btn-lg.ui-btn-split { padding-right: 34px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-extra,
|
||||
.ui-btn-lg .ui-btn-menu {
|
||||
width: 34px;
|
||||
border-radius: 0 3px 3px 0;
|
||||
}
|
||||
|
||||
.ui-btn-sm.ui-btn-double,
|
||||
.ui-btn-sm.ui-btn-split { padding-right: 28px; }
|
||||
|
||||
.ui-btn-sm .ui-btn-extra,
|
||||
.ui-btn-sm .ui-btn-menu {
|
||||
width: 28px;
|
||||
border-radius: 0 3px 3px 0;
|
||||
}
|
||||
|
||||
.ui-btn-lg .ui-btn-extra:before,
|
||||
.ui-btn-lg .ui-btn-menu:before { margin-top: -3px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-extra:after,
|
||||
.ui-btn-lg .ui-btn-menu:after {
|
||||
top: 11px;
|
||||
bottom: 10px;
|
||||
opacity: .25;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Colors*/
|
||||
/*region Color Variables*/
|
||||
.ui-btn-default { /* default variables */ }
|
||||
|
||||
.ui-btn-success {
|
||||
--ui-btn-background: #bbed21;
|
||||
--ui-btn-background-hover: #d2f95f;
|
||||
--ui-btn-background-active: #b2e232;
|
||||
--ui-btn-border-color: #bbed21;
|
||||
--ui-btn-border-color-hover: #d2f95f;
|
||||
--ui-btn-border-color-active: #b2e232;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #535c69;
|
||||
--ui-btn-color-active: #535c69;
|
||||
}
|
||||
|
||||
.ui-btn-success-light {
|
||||
--ui-btn-background: #e1f0b1;
|
||||
--ui-btn-background-hover: #eaf5c5;
|
||||
--ui-btn-background-active: #d3e59a;
|
||||
--ui-btn-border-color: #e1f0b1;
|
||||
--ui-btn-border-color-hover: #eaf5c5;
|
||||
--ui-btn-border-color-active: #d3e59a;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #333;
|
||||
--ui-btn-colors-before-bg: #a3bf63;
|
||||
--ui-btn-color: #668d13;
|
||||
--ui-btn-color-hover: #668d13;
|
||||
--ui-btn-color-active: #668d13;
|
||||
}
|
||||
|
||||
.ui-btn-success-dark {
|
||||
--ui-btn-background: #86a732;
|
||||
--ui-btn-background-hover: #a2bf54;
|
||||
--ui-btn-background-active: #a2bf54;
|
||||
--ui-btn-border-color: #86a732;
|
||||
--ui-btn-border-color-hover: #a2bf54;
|
||||
--ui-btn-border-color-active: #a2bf54;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #fff;
|
||||
--ui-btn-colors-before-bg: #a3bf63;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-danger {
|
||||
--ui-btn-background: #f1361a;
|
||||
--ui-btn-background-hover: #cc1c00;
|
||||
--ui-btn-background-active: #d24430;
|
||||
--ui-btn-border-color: #f1361a;
|
||||
--ui-btn-border-color-hover: #cc1c00;
|
||||
--ui-btn-border-color-active: #d24430;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-danger-dark {
|
||||
--ui-btn-background: #a21429;
|
||||
--ui-btn-background-hover: #c43d51;
|
||||
--ui-btn-background-active: #c43d51;
|
||||
--ui-btn-border-color: #a21429;
|
||||
--ui-btn-border-color-hover: #c43d51;
|
||||
--ui-btn-border-color-active: #c43d51;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-danger-light {
|
||||
--ui-btn-background: #ffccca;
|
||||
--ui-btn-background-hover: #ffdcdb;
|
||||
--ui-btn-background-active: #f2b6b3;
|
||||
--ui-btn-border-color: #ffccca;
|
||||
--ui-btn-border-color-hover: #ffdcdb;
|
||||
--ui-btn-border-color-active: #f2b6b3;
|
||||
--ui-btn-opacity-after: .2;
|
||||
--ui-btn-colors-after-bg: #333;
|
||||
--ui-btn-colors-before-bg: #eb8783;
|
||||
--ui-btn-color: #d7413c;
|
||||
--ui-btn-color-hover: #d7413c;
|
||||
--ui-btn-color-active: #d7413c;
|
||||
}
|
||||
|
||||
.ui-btn-primary {
|
||||
--ui-btn-background: #3bc8f5;
|
||||
--ui-btn-background-hover: #3eddff;
|
||||
--ui-btn-background-active: #12b1e3;
|
||||
--ui-btn-border-color: #3bc8f5;
|
||||
--ui-btn-border-color-hover: #3eddff;
|
||||
--ui-btn-border-color-active: #12b1e3;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-primary-dark {
|
||||
--ui-btn-background: #399fc2;
|
||||
--ui-btn-background-hover: #37aed4;
|
||||
--ui-btn-background-active: #37aed4;
|
||||
--ui-btn-border-color: #399fc2;
|
||||
--ui-btn-border-color-hover: #37aed4;
|
||||
--ui-btn-border-color-active: #37aed4;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.ui-btn-secondary {
|
||||
--ui-btn-background: #c5e7f4;
|
||||
--ui-btn-background-hover: #d1eef9;
|
||||
--ui-btn-background-active: #aee0f2;
|
||||
--ui-btn-border-color: #aee0f2;
|
||||
--ui-btn-border-color-hover: #aee0f2;
|
||||
--ui-btn-border-color-active: #aee0f2;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #535c69;
|
||||
--ui-btn-color-active: #535c69;
|
||||
}
|
||||
|
||||
.ui-btn-link {
|
||||
--ui-btn-background: transparent;
|
||||
--ui-btn-background-hover: transparent;
|
||||
--ui-btn-background-active: transparent;
|
||||
--ui-btn-border-color: transparent;
|
||||
--ui-btn-border-color-hover: transparent;
|
||||
--ui-btn-border-color-active: transparent;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #80868e;
|
||||
--ui-btn-color-active: #535c69;
|
||||
}
|
||||
|
||||
.ui-btn-light {
|
||||
--ui-btn-background: transparent;
|
||||
--ui-btn-background-hover: #f6f8f9;
|
||||
--ui-btn-background-active: #d6f1fb;
|
||||
--ui-btn-border-color: transparent;
|
||||
--ui-btn-border-color-hover: #f6f8f9;
|
||||
--ui-btn-border-color-active: #d6f1fb;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535c69;
|
||||
--ui-btn-color-hover: #333;
|
||||
--ui-btn-color-active: #000;
|
||||
}
|
||||
|
||||
.ui-btn-light-border {
|
||||
--ui-btn-background: transparent;
|
||||
--ui-btn-background-hover: #cfd4d8;
|
||||
--ui-btn-background-active: #dde2e5;
|
||||
--ui-btn-border-color: #c6cdd3;
|
||||
--ui-btn-border-color-hover: #c6cdd3;
|
||||
--ui-btn-border-color-active: #9fa4ab;
|
||||
--ui-btn-opacity-after: .3;
|
||||
--ui-btn-colors-after-bg: #535c69;
|
||||
--ui-btn-colors-before-bg: #535c69;
|
||||
--ui-btn-color: #535b69;
|
||||
--ui-btn-color-hover: #535b69;
|
||||
--ui-btn-color-active: #535b69;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Button Color*/
|
||||
|
||||
/*region Link button*/
|
||||
.ui-btn-link.ui-btn {
|
||||
padding-right: 0;
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
.ui-btn-link .ui-btn-main { padding-left: 0; }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Light-border button*/
|
||||
|
||||
/*region Fix for Themes*/
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-link,
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-light,
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-light-border {
|
||||
--ui-btn-background: rgba(255, 255, 255, .15);
|
||||
--ui-btn-background-hover: rgba(255, 255, 255, .3);
|
||||
--ui-btn-background-active: rgba(255, 255, 255, .4);
|
||||
--ui-btn-colors-after-bg: #fff;
|
||||
--ui-btn-colors-before-bg: #fff;
|
||||
--ui-btn-color: #fff;
|
||||
--ui-btn-color-hover: #fff;
|
||||
--ui-btn-color-active: #fff;
|
||||
}
|
||||
|
||||
.bitrix24-light-theme .ui-btn-themes.ui-btn-light-border { --ui-btn-border-color: rgba(255, 255, 255, .4); }
|
||||
|
||||
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-link,
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-light,
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-light-border {
|
||||
--ui-btn-background: rgba(0, 0, 0, .07);
|
||||
--ui-btn-background-hover: rgba(0, 0, 0, .1);
|
||||
--ui-btn-background-active: rgba(0, 0, 0, .15);
|
||||
--ui-btn-colors-after-bg: rgba(51, 51, 51, .8);
|
||||
--ui-btn-colors-before-bg: rgba(51, 51, 51, .8);
|
||||
--ui-btn-color: rgba(51, 51, 51, .8);
|
||||
--ui-btn-color-hover: rgba(51, 51, 51, .8);;
|
||||
--ui-btn-color-active: rgba(51, 51, 51, .8);;
|
||||
}
|
||||
|
||||
.bitrix24-dark-theme .ui-btn-themes.ui-btn-light-border { --ui-btn-border-color: rgba(0, 0, 0, .06); }
|
||||
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Others*/
|
||||
|
||||
.ui-btn-round { border-radius: calc(var(--ui-btn-height) / 2) !important; }
|
||||
|
||||
.ui-btn-no-caps,
|
||||
.ui-btn-no-caps .ui-btn-main {
|
||||
text-transform: none;
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
/*region Counter*/
|
||||
.ui-btn-counter {
|
||||
display: inline-block;
|
||||
padding: 0 8px;
|
||||
border-radius: 10px;
|
||||
background-color: #f34829;
|
||||
color: #fff;
|
||||
vertical-align: middle;
|
||||
font: 11px/19px "Open Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
.ui-btn-text + .ui-btn-counter { margin-left: 12px; }
|
||||
|
||||
.ui-btn-lg .ui-btn-counter { margin-left: 15px; }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Dropdown*/
|
||||
.ui-btn.ui-btn-dropdown,
|
||||
.ui-btn-dropdown .ui-btn-main { padding-right: 29px; }
|
||||
|
||||
.ui-btn.ui-btn-dropdown:before,
|
||||
.ui-btn-dropdown .ui-btn-main:before {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
right: 13px;
|
||||
display: block;
|
||||
box-sizing: border-box;
|
||||
margin-top: -1.5px;
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
border-bottom: 2px solid;
|
||||
border-left: 2px solid;
|
||||
content: '';
|
||||
transform: translateY(-50%) rotate(-45deg);
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-dropdown:before,
|
||||
.ui-btn-dropdown .ui-btn-main:before { border-color: var(--ui-btn-color); }
|
||||
|
||||
.ui-btn.ui-btn-empty.ui-btn-dropdown:before,
|
||||
.ui-btn.ui-btn-collapsed.ui-btn-dropdown:before,
|
||||
.ui-btn-empty.ui-btn-dropdown .ui-btn-main:before,
|
||||
.ui-btn-collapsed.ui-btn-dropdown .ui-btn-main:before {
|
||||
right: auto;
|
||||
transform: translate(-50%, -50%) rotate(-45deg);
|
||||
left: 50%;
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-empty.ui-btn-dropdown[class*="ui-btn-icon-"]:before,
|
||||
.ui-btn.ui-btn-collapsed.ui-btn-dropdown[class*="ui-btn-icon-"]:before,
|
||||
.ui-btn-empty.ui-btn-dropdown[class*="ui-btn-icon-"] .ui-btn-main:before,
|
||||
.ui-btn-collapsed.ui-btn-dropdown[class*="ui-btn-icon-"] .ui-btn-main:before {
|
||||
right: 12px;
|
||||
transform: translateY(-50%) rotate(-45deg);
|
||||
left: auto;
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Disabled*/
|
||||
.ui-btn.ui-btn-disabled,
|
||||
.ui-btn.ui-btn-disabled:hover,
|
||||
.ui-btn.ui-btn-disabled:active,
|
||||
.ui-btn[disabled],
|
||||
.ui-btn[disabled]:hover,
|
||||
.ui-btn[disabled]:active,
|
||||
.ui-btn-disabled .ui-btn-main,
|
||||
.ui-btn-disabled .ui-btn-main:hover,
|
||||
.ui-btn-disabled .ui-btn-main:active,
|
||||
.ui-btn-disabled .ui-btn-extra,
|
||||
.ui-btn-disabled .ui-btn-extra:hover,
|
||||
.ui-btn-disabled .ui-btn-extra:active,
|
||||
.ui-btn-disabled .ui-btn-menu,
|
||||
.ui-btn-disabled .ui-btn-menu:hover,
|
||||
.ui-btn-disabled .ui-btn-menu:active,
|
||||
.ui-btn-main-disabled .ui-btn-main,
|
||||
.ui-btn-main-disabled .ui-btn-main:hover,
|
||||
.ui-btn-main-disabled .ui-btn-main:active,
|
||||
.ui-btn-extra-disabled .ui-btn-extra,
|
||||
.ui-btn-extra-disabled .ui-btn-extra:hover,
|
||||
.ui-btn-extra-disabled .ui-btn-extra:active,
|
||||
.ui-btn-menu-disabled .ui-btn-menu,
|
||||
.ui-btn-menu-disabled .ui-btn-menu:hover,
|
||||
.ui-btn-menu-disabled .ui-btn-menu:active {
|
||||
opacity: .4;
|
||||
cursor: not-allowed;
|
||||
background-color: var(--ui-btn-background);
|
||||
border-color: var(--ui-btn-border-color);
|
||||
}
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Wait*/
|
||||
.ui-btn.ui-btn-wait,
|
||||
.ui-btn-wait .ui-btn-main {
|
||||
background-position: center !important;
|
||||
background-repeat: no-repeat !important;
|
||||
color: transparent !important;
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-wait:after,
|
||||
.ui-btn-wait .ui-btn-main:after { opacity: 0; }
|
||||
|
||||
.ui-btn-wait,
|
||||
.ui-btn-wait.ui-btn-danger,
|
||||
.ui-btn-wait.ui-btn-primary,
|
||||
.ui-btn-wait.ui-btn-default,
|
||||
.ui-btn-wait.ui-btn-danger-dark,
|
||||
.ui-btn-wait.ui-btn-success-dark,
|
||||
.ui-btn-wait.ui-btn-primary-dark { --ui-btn-wait-loader: var(--ui-btn-wait-white); }
|
||||
|
||||
.ui-btn-wait.ui-btn-link,
|
||||
.ui-btn-wait.ui-btn-secondary,
|
||||
.ui-btn-wait.ui-btn-light,
|
||||
.ui-btn-wait.ui-btn-success,
|
||||
.ui-btn-wait.ui-btn-light-border,
|
||||
.ui-btn-wait.ui-btn-link { --ui-btn-wait-loader: var(--ui-btn-wait-black); }
|
||||
|
||||
.ui-btn.ui-btn-wait,
|
||||
.ui-btn-wait .ui-btn-main { background-image: var(--ui-btn-wait-loader); }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*region Clock*/
|
||||
.ui-btn.ui-btn-clock,
|
||||
.ui-btn-double.ui-btn-clock .ui-btn-main,
|
||||
.ui-btn-split.ui-btn-clock .ui-btn-main {
|
||||
background-position: center !important;
|
||||
background-repeat: no-repeat !important;
|
||||
color: transparent !important;
|
||||
}
|
||||
|
||||
.ui-btn.ui-btn-clock:after,
|
||||
.ui-btn-double.ui-btn-clock .ui-btn-main:after,
|
||||
.ui-btn-split.ui-btn-clock .ui-btn-main:after { opacity: 0; }
|
||||
|
||||
.ui-btn-clock,
|
||||
.ui-btn-clock.ui-btn-danger,
|
||||
.ui-btn-clock.ui-btn-primary,
|
||||
.ui-btn-clock.ui-btn-default,
|
||||
.ui-btn-clock.ui-btn-danger-dark,
|
||||
.ui-btn-clock.ui-btn-success-dark,
|
||||
.ui-btn-clock.ui-btn-primary-dark { --ui-btn-clock-loader: var(--ui-btn-clock-white); }
|
||||
|
||||
.ui-btn-clock.ui-btn-link,
|
||||
.ui-btn-clock.ui-btn-secondary,
|
||||
.ui-btn-clock.ui-btn-light,
|
||||
.ui-btn-clock.ui-btn-success,
|
||||
.ui-btn-clock.ui-btn-light-border,
|
||||
.ui-btn-clock.ui-btn-link { --ui-btn-clock-loader: var(--ui-btn-clock-black); }
|
||||
|
||||
.ui-btn.ui-btn-clock,
|
||||
.ui-btn-clock .ui-btn-main { background-image: var(--ui-btn-clock-loader); }
|
||||
|
||||
/*endregion*/
|
||||
|
||||
/*endregion*/
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
+57
-21
@@ -1,6 +1,6 @@
|
||||
/**
|
||||
* Do not edit directly
|
||||
* Generated on Tue, 29 Apr 2025 05:39:16 GMT
|
||||
* Generated on Tue, 08 Jul 2025 12:00:23 GMT
|
||||
*/
|
||||
|
||||
:root, .--ui-context-content-light {
|
||||
@@ -14,8 +14,8 @@
|
||||
--ui-color-base-7: #EDEEF0;
|
||||
--ui-color-base-8: #FFFFFF;
|
||||
--ui-color-base-black-fixed: #000000;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-bg-content-primary: #FFFFFF;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-divider-accent: #E2E2E2;
|
||||
--ui-color-divider-default: #F0F0F0;
|
||||
--ui-color-divider-less: #F7F7F7;
|
||||
@@ -33,9 +33,9 @@
|
||||
--ui-divider-optical-1-weight: 0px;
|
||||
--ui-divider-optical-2-weight: 0px;
|
||||
--ui-color-divider-optical-on-overlay: #FFFFFF00;
|
||||
--ui-color-bg-content-secondary: #FBFBFB;
|
||||
--ui-color-bg-content-secondary: #FAFCFD;
|
||||
--ui-divider-optical-on-overlay-weight: 0px;
|
||||
--ui-color-bg-content-tertiary: #F1F4F6;
|
||||
--ui-color-bg-content-tertiary: #EEF2F4;
|
||||
--ui-color-bg-vibrant-accent: #FFFFFFF5;
|
||||
--ui-color-bg-state-hover-default-hex: #000000;
|
||||
--ui-color-bg-state-hover-default-opacity: 3%;
|
||||
@@ -109,6 +109,13 @@
|
||||
--ui-color-design-filled-warning-content-icon: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-chevron: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-divider: #FFFFFF3D;
|
||||
--ui-color-design-filled-white-bg: #FAFAFC;
|
||||
--ui-color-design-filled-white-stroke: var(--ui-color-base-7);
|
||||
--ui-design-filled-white-stroke-weight: 0px;
|
||||
--ui-color-design-filled-white-content: var(--ui-color-base-2);
|
||||
--ui-color-design-filled-white-content-icon: var(--ui-color-base-2);
|
||||
--ui-color-design-filled-white-content-chevron: var(--ui-color-base-2);
|
||||
--ui-color-design-filled-white-content-divider: var(--ui-color-base-7);
|
||||
--ui-color-design-filled-na-bg: var(--ui-color-base-4);
|
||||
--ui-color-design-filled-na-bg-secondary: var(--ui-color-base-5);
|
||||
--ui-color-design-filled-copilot-bg: var(--ui-color-copilot-accent-primary);
|
||||
@@ -266,8 +273,9 @@
|
||||
--ui-color-design-selection-bg: var(--ui-color-accent-soft-blue-3);
|
||||
--ui-color-design-selection-stroke: var(--ui-color-accent-soft-blue-1);
|
||||
--ui-design-selection-stroke-weight: var(--ui-border-width-medium);
|
||||
--ui-color-design-selection-content: var(--ui-color-accent-main-primary);
|
||||
--ui-design-selection-stroke-weight-alt: var(--ui-border-width-thin);
|
||||
--ui-color-design-plain-na-focused-stroke: var(--ui-color-divider-default);
|
||||
--ui-color-design-selection-content: var(--ui-color-accent-main-primary);
|
||||
--ui-design-plain-na-focused-stroke-weight: var(--ui-border-width-medium);
|
||||
--ui-color-design-selection-content-icon: var(--ui-color-accent-main-primary);
|
||||
--ui-color-design-selection-content-icon-secondary: var(--ui-color-accent-main-primary-alt-2);
|
||||
@@ -276,7 +284,7 @@
|
||||
--ui-color-design-selection-content-divider: var(--ui-color-accent-soft-blue-1);
|
||||
--ui-color-design-selection-focused-bg: var(--ui-color-bg-content-primary);
|
||||
--ui-color-accent-main-primary-alt: #1F86FF;
|
||||
--ui-color-accent-main-primary-alt-2: #7AB7FF;
|
||||
--ui-color-accent-main-primary-alt-2: #58B1FF;
|
||||
--ui-color-accent-main-success: #1BCE7B;
|
||||
--ui-color-accent-main-success-alt: #10B769;
|
||||
--ui-color-accent-main-success-alt-2: #00A659;
|
||||
@@ -344,8 +352,8 @@
|
||||
--ui-color-tech-bg-picture-tint: #00000000;
|
||||
--ui-color-tech-dark-fixes: #FFFFFF00;
|
||||
--ui-color-blue-02: #F9FCFF;
|
||||
--ui-color-blue-04: #F8FBFF;
|
||||
--ui-color-black-base: #333333;
|
||||
--ui-color-blue-04: #F8FBFF;
|
||||
--ui-color-blue-06: #F7FBFF;
|
||||
--ui-color-blue-08: #F5FAFF;
|
||||
--ui-color-g-content-glass-1: #FFFFFFE6;
|
||||
@@ -491,6 +499,7 @@
|
||||
--ui-color-design-disabled-stroke: var(--ui-color-base-7);
|
||||
--ui-design-disabled-stroke-weight: 0px;
|
||||
--ui-color-design-disabled-content: var(--ui-color-base-5);
|
||||
--ui-color-design-disabled-content-alt: var(--ui-color-base-4);
|
||||
--ui-color-design-disabled-content-icon: var(--ui-color-base-5);
|
||||
--ui-color-design-disabled-content-chevron: var(--ui-color-base-5);
|
||||
--ui-color-design-disabled-content-divider: var(--ui-color-base-6);
|
||||
@@ -535,8 +544,8 @@
|
||||
--ui-color-base-7: #373838;
|
||||
--ui-color-base-8: #252626;
|
||||
--ui-color-base-black-fixed: #000000;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-bg-content-primary: #262626;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-divider-accent: #383838;
|
||||
--ui-color-divider-default: #323232;
|
||||
--ui-color-divider-less: #323232;
|
||||
@@ -630,6 +639,13 @@
|
||||
--ui-color-design-filled-warning-content-icon: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-chevron: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-divider: #FFFFFF3D;
|
||||
--ui-color-design-filled-white-bg: var(--ui-color-bg-content-primary);
|
||||
--ui-color-design-filled-white-stroke: var(--ui-color-base-7);
|
||||
--ui-design-filled-white-stroke-weight: 0px;
|
||||
--ui-color-design-filled-white-content: var(--ui-color-base-2);
|
||||
--ui-color-design-filled-white-content-icon: var(--ui-color-base-2);
|
||||
--ui-color-design-filled-white-content-chevron: var(--ui-color-base-2);
|
||||
--ui-color-design-filled-white-content-divider: var(--ui-color-base-7);
|
||||
--ui-color-design-filled-na-bg: var(--ui-color-base-4);
|
||||
--ui-color-design-filled-na-bg-secondary: var(--ui-color-base-5);
|
||||
--ui-color-design-filled-copilot-bg: var(--ui-color-copilot-accent-primary);
|
||||
@@ -787,8 +803,9 @@
|
||||
--ui-color-design-selection-bg: #1F3048;
|
||||
--ui-color-design-selection-stroke: #294162;
|
||||
--ui-design-selection-stroke-weight: var(--ui-border-width-medium);
|
||||
--ui-color-design-selection-content: #2A94FF;
|
||||
--ui-design-selection-stroke-weight-alt: var(--ui-border-width-thin);
|
||||
--ui-color-design-plain-na-focused-stroke: var(--ui-color-divider-default);
|
||||
--ui-color-design-selection-content: #2A94FF;
|
||||
--ui-design-plain-na-focused-stroke-weight: var(--ui-border-width-medium);
|
||||
--ui-color-design-selection-content-icon: #2A94FF;
|
||||
--ui-color-design-selection-content-icon-secondary: #5EAEFF;
|
||||
@@ -865,8 +882,8 @@
|
||||
--ui-color-tech-bg-picture-tint: #0000003D;
|
||||
--ui-color-tech-dark-fixes: #383838;
|
||||
--ui-color-blue-02: #FFFFFF;
|
||||
--ui-color-blue-04: #FFFFFF;
|
||||
--ui-color-black-base: #333333;
|
||||
--ui-color-blue-04: #FFFFFF;
|
||||
--ui-color-blue-06: #FFFFFF;
|
||||
--ui-color-blue-08: #FFFFFF;
|
||||
--ui-color-g-content-glass-1: #FFFFFFE6;
|
||||
@@ -1012,6 +1029,7 @@
|
||||
--ui-color-design-disabled-stroke: var(--ui-color-base-7);
|
||||
--ui-design-disabled-stroke-weight: 0px;
|
||||
--ui-color-design-disabled-content: var(--ui-color-base-5);
|
||||
--ui-color-design-disabled-content-alt: var(--ui-color-base-4);
|
||||
--ui-color-design-disabled-content-icon: var(--ui-color-base-5);
|
||||
--ui-color-design-disabled-content-chevron: var(--ui-color-base-5);
|
||||
--ui-color-design-disabled-content-divider: var(--ui-color-base-6);
|
||||
@@ -1047,7 +1065,7 @@
|
||||
|
||||
.--ui-context-edge-light {
|
||||
--ui-color-base-0: #000000;
|
||||
--ui-color-base-1: #000000;
|
||||
--ui-color-base-1: #1D1E1F;
|
||||
--ui-color-base-2: #000000BF;
|
||||
--ui-color-base-3: #000000A6;
|
||||
--ui-color-base-4: #0000008C;
|
||||
@@ -1056,8 +1074,8 @@
|
||||
--ui-color-base-7: #00000040;
|
||||
--ui-color-base-8: #00000026;
|
||||
--ui-color-base-black-fixed: #000000;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-bg-content-primary: #0000000F;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-divider-accent: #0000000F;
|
||||
--ui-color-divider-default: #0000000A;
|
||||
--ui-color-divider-less: #00000008;
|
||||
@@ -1109,7 +1127,7 @@
|
||||
--ui-color-bg-content-inapp: #00428F;
|
||||
--ui-color-bg-content-primary-layer: #292929;
|
||||
--ui-color-bg-content-light: #EEEEEE;
|
||||
--ui-bg-blur-content: var(--ui-bg-blur-default);
|
||||
--ui-bg-blur-content: var(--ui-bg-blur-accent);
|
||||
--ui-bg-blur-vibrant: var(--ui-bg-blur-accent);
|
||||
--ui-color-accent-main-primary: #1587FA;
|
||||
--ui-color-design-filled-bg: var(--ui-color-accent-main-primary);
|
||||
@@ -1151,6 +1169,13 @@
|
||||
--ui-color-design-filled-warning-content-icon: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-chevron: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-divider: #FFFFFF1F;
|
||||
--ui-color-design-filled-white-bg: var(--ui-color-bg-content-primary);
|
||||
--ui-color-design-filled-white-stroke: #00000014;
|
||||
--ui-design-filled-white-stroke-weight: 0px;
|
||||
--ui-color-design-filled-white-content: var(--ui-color-base-0);
|
||||
--ui-color-design-filled-white-content-icon: var(--ui-color-base-1);
|
||||
--ui-color-design-filled-white-content-chevron: var(--ui-color-base-1);
|
||||
--ui-color-design-filled-white-content-divider: var(--ui-color-base-7);
|
||||
--ui-color-design-filled-na-bg: var(--ui-color-base-4);
|
||||
--ui-color-design-filled-na-bg-secondary: var(--ui-color-base-5);
|
||||
--ui-color-design-filled-copilot-bg: var(--ui-color-copilot-accent-primary);
|
||||
@@ -1305,13 +1330,14 @@
|
||||
--ui-color-design-plain-na-content-chevron: var(--ui-color-base-5);
|
||||
--ui-color-design-plain-na-content-divider: var(--ui-color-base-8);
|
||||
--ui-color-design-plain-na-focused-bg: #00000014;
|
||||
--ui-color-design-selection-bg: #0000001F;
|
||||
--ui-color-design-selection-bg: #00000014;
|
||||
--ui-color-design-selection-stroke: #00000000;
|
||||
--ui-design-selection-stroke-weight: 0px;
|
||||
--ui-color-design-selection-content: var(--ui-color-base-0);
|
||||
--ui-design-selection-stroke-weight-alt: 0px;
|
||||
--ui-color-design-plain-na-focused-stroke: #00000014;
|
||||
--ui-color-design-selection-content: var(--ui-color-base-1);
|
||||
--ui-design-plain-na-focused-stroke-weight: var(--ui-border-width-medium);
|
||||
--ui-color-design-selection-content-icon: var(--ui-color-base-0);
|
||||
--ui-color-design-selection-content-icon: var(--ui-color-base-1);
|
||||
--ui-color-design-selection-content-icon-secondary: var(--ui-color-base-2);
|
||||
--ui-color-design-selection-content-chevron: var(--ui-color-base-0);
|
||||
--ui-color-design-plain-na-focused-content: var(--ui-color-base-1);
|
||||
@@ -1386,8 +1412,8 @@
|
||||
--ui-color-tech-bg-picture-tint: #0000003D;
|
||||
--ui-color-tech-dark-fixes: #383838;
|
||||
--ui-color-blue-02: #FFFFFF;
|
||||
--ui-color-blue-04: #FFFFFF;
|
||||
--ui-color-black-base: #333333;
|
||||
--ui-color-blue-04: #FFFFFF;
|
||||
--ui-color-blue-06: #FFFFFF;
|
||||
--ui-color-blue-08: #FFFFFF;
|
||||
--ui-color-g-content-glass-1: #FFFFFFE6;
|
||||
@@ -1533,6 +1559,7 @@
|
||||
--ui-color-design-disabled-stroke: var(--ui-color-bg-content-primary);
|
||||
--ui-design-disabled-stroke-weight: 0px;
|
||||
--ui-color-design-disabled-content: var(--ui-color-base-7);
|
||||
--ui-color-design-disabled-content-alt: var(--ui-color-base-6);
|
||||
--ui-color-design-disabled-content-icon: var(--ui-color-base-7);
|
||||
--ui-color-design-disabled-content-chevron: var(--ui-color-base-7);
|
||||
--ui-color-design-disabled-content-divider: var(--ui-color-base-8);
|
||||
@@ -1577,8 +1604,8 @@
|
||||
--ui-color-base-7: #FFFFFF4D;
|
||||
--ui-color-base-8: #FFFFFF33;
|
||||
--ui-color-base-black-fixed: #000000;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-bg-content-primary: #FFFFFF29;
|
||||
--ui-color-base-white-fixed: #FFFFFF;
|
||||
--ui-color-divider-accent: #FFFFFF14;
|
||||
--ui-color-divider-default: #FFFFFF0F;
|
||||
--ui-color-divider-less: #FFFFFF0A;
|
||||
@@ -1630,7 +1657,7 @@
|
||||
--ui-color-bg-content-inapp: #00428F;
|
||||
--ui-color-bg-content-primary-layer: #FFFFFF;
|
||||
--ui-color-bg-content-light: #EEEEEE;
|
||||
--ui-bg-blur-content: var(--ui-bg-blur-default);
|
||||
--ui-bg-blur-content: var(--ui-bg-blur-accent);
|
||||
--ui-bg-blur-vibrant: var(--ui-bg-blur-accent-more);
|
||||
--ui-color-accent-main-primary: #1587FA;
|
||||
--ui-color-design-filled-bg: var(--ui-color-accent-main-primary);
|
||||
@@ -1672,6 +1699,13 @@
|
||||
--ui-color-design-filled-warning-content-icon: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-chevron: var(--ui-color-base-white-fixed);
|
||||
--ui-color-design-filled-warning-content-divider: #FFFFFF29;
|
||||
--ui-color-design-filled-white-bg: var(--ui-color-bg-content-primary);
|
||||
--ui-color-design-filled-white-stroke: #FFFFFF24;
|
||||
--ui-design-filled-white-stroke-weight: 0px;
|
||||
--ui-color-design-filled-white-content: var(--ui-color-base-0);
|
||||
--ui-color-design-filled-white-content-icon: var(--ui-color-base-1);
|
||||
--ui-color-design-filled-white-content-chevron: var(--ui-color-base-1);
|
||||
--ui-color-design-filled-white-content-divider: var(--ui-color-base-7);
|
||||
--ui-color-design-filled-na-bg: var(--ui-color-base-4);
|
||||
--ui-color-design-filled-na-bg-secondary: var(--ui-color-base-5);
|
||||
--ui-color-design-filled-copilot-bg: var(--ui-color-copilot-accent-primary);
|
||||
@@ -1829,8 +1863,9 @@
|
||||
--ui-color-design-selection-bg: #FFFFFF4D;
|
||||
--ui-color-design-selection-stroke: #FFFFFF00;
|
||||
--ui-design-selection-stroke-weight: 0px;
|
||||
--ui-color-design-selection-content: var(--ui-color-base-0);
|
||||
--ui-design-selection-stroke-weight-alt: 0px;
|
||||
--ui-color-design-plain-na-focused-stroke: #FFFFFF1F;
|
||||
--ui-color-design-selection-content: var(--ui-color-base-0);
|
||||
--ui-design-plain-na-focused-stroke-weight: var(--ui-border-width-medium);
|
||||
--ui-color-design-selection-content-icon: var(--ui-color-base-0);
|
||||
--ui-color-design-selection-content-icon-secondary: var(--ui-color-base-2);
|
||||
@@ -1907,8 +1942,8 @@
|
||||
--ui-color-tech-bg-picture-tint: #0000003D;
|
||||
--ui-color-tech-dark-fixes: #383838;
|
||||
--ui-color-blue-02: #FFFFFF;
|
||||
--ui-color-blue-04: #FFFFFF;
|
||||
--ui-color-black-base: #333333;
|
||||
--ui-color-blue-04: #FFFFFF;
|
||||
--ui-color-blue-06: #FFFFFF;
|
||||
--ui-color-blue-08: #FFFFFF;
|
||||
--ui-color-g-content-glass-1: #FFFFFFE6;
|
||||
@@ -2054,6 +2089,7 @@
|
||||
--ui-color-design-disabled-stroke: var(--ui-color-bg-content-primary);
|
||||
--ui-design-disabled-stroke-weight: 0px;
|
||||
--ui-color-design-disabled-content: var(--ui-color-base-7);
|
||||
--ui-color-design-disabled-content-alt: var(--ui-color-base-6);
|
||||
--ui-color-design-disabled-content-icon: var(--ui-color-base-7);
|
||||
--ui-color-design-disabled-content-chevron: var(--ui-color-base-7);
|
||||
--ui-color-design-disabled-content-divider: var(--ui-color-base-8);
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -69,13 +69,13 @@
|
||||
"value": "#000000"
|
||||
},
|
||||
{
|
||||
"name": "base/base-white-fixed",
|
||||
"name": "backgrounds/content/bg-content-primary",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "backgrounds/content/bg-content-primary",
|
||||
"name": "base/base-white-fixed",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
@@ -186,7 +186,7 @@
|
||||
"name": "backgrounds/content/bg-content-secondary",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FBFBFB"
|
||||
"value": "#FAFCFD"
|
||||
},
|
||||
{
|
||||
"name": "divider/optical/divider-optical-on-overlay-weight",
|
||||
@@ -198,7 +198,7 @@
|
||||
"name": "backgrounds/content/bg-content-tertiary",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#F1F4F6"
|
||||
"value": "#EEF2F4"
|
||||
},
|
||||
{
|
||||
"name": "backgrounds/vibrant/bg-vibrant-accent",
|
||||
@@ -623,6 +623,63 @@
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF3D"
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-bg",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FAFAFC"
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke-weight",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-icon",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-chevron",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-divider",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled no accent/default/design-filled-na-bg",
|
||||
"type": "color",
|
||||
@@ -1938,12 +1995,12 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-content",
|
||||
"type": "color",
|
||||
"name": "design/selection/default/design-selection-stroke-weight-alt",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "accent/main/accent-main-primary"
|
||||
"collection": "fixed",
|
||||
"name": "global/border/width/border-width-thin"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -1955,6 +2012,15 @@
|
||||
"name": "divider/content/divider-default"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-content",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "accent/main/accent-main-primary"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke-weight",
|
||||
"type": "number",
|
||||
@@ -2028,7 +2094,7 @@
|
||||
"name": "accent/main/accent-main-primary-alt-2",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#7AB7FF"
|
||||
"value": "#58B1FF"
|
||||
},
|
||||
{
|
||||
"name": "accent/main/accent-main-success",
|
||||
@@ -2718,7 +2784,7 @@
|
||||
"name": "component/drawer/drawer-bg-default",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#F6F8FA"
|
||||
"value": "#EEF2F4"
|
||||
},
|
||||
{
|
||||
"name": "component/drawer/drawer-bg-unfocused",
|
||||
@@ -3293,18 +3359,18 @@
|
||||
"isAlias": false,
|
||||
"value": "#F9FCFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#F8FBFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/black/black-base",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#333333"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#F8FBFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-06",
|
||||
"type": "color",
|
||||
@@ -4670,6 +4736,15 @@
|
||||
"name": "base/base-5"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-alt",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-icon",
|
||||
"type": "color",
|
||||
@@ -4969,18 +5044,18 @@
|
||||
"isAlias": false,
|
||||
"value": "#000000"
|
||||
},
|
||||
{
|
||||
"name": "base/base-white-fixed",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "backgrounds/content/bg-content-primary",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#262626"
|
||||
},
|
||||
{
|
||||
"name": "base/base-white-fixed",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "divider/content/divider-accent",
|
||||
"type": "color",
|
||||
@@ -5533,6 +5608,66 @@
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF3D"
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-bg",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "backgrounds/content/bg-content-primary"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke-weight",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-icon",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-chevron",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-divider",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled no accent/default/design-filled-na-bg",
|
||||
"type": "color",
|
||||
@@ -6842,10 +6977,13 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-content",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#2A94FF"
|
||||
"name": "design/selection/default/design-selection-stroke-weight-alt",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "fixed",
|
||||
"name": "global/border/width/border-width-thin"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke",
|
||||
@@ -6856,6 +6994,12 @@
|
||||
"name": "divider/content/divider-default"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-content",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#2A94FF"
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke-weight",
|
||||
"type": "number",
|
||||
@@ -8170,18 +8314,18 @@
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/black/black-base",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#333333"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-06",
|
||||
"type": "color",
|
||||
@@ -9547,6 +9691,15 @@
|
||||
"name": "base/base-5"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-alt",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-4"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-icon",
|
||||
"type": "color",
|
||||
@@ -9796,7 +9949,7 @@
|
||||
"name": "base/base-1",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#000000"
|
||||
"value": "#1D1E1F"
|
||||
},
|
||||
{
|
||||
"name": "base/base-2",
|
||||
@@ -9846,18 +9999,18 @@
|
||||
"isAlias": false,
|
||||
"value": "#000000"
|
||||
},
|
||||
{
|
||||
"name": "base/base-white-fixed",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "backgrounds/content/bg-content-primary",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#0000000F"
|
||||
},
|
||||
{
|
||||
"name": "base/base-white-fixed",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "divider/content/divider-accent",
|
||||
"type": "color",
|
||||
@@ -10410,6 +10563,63 @@
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF1F"
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-bg",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "backgrounds/content/bg-content-primary"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#00000014"
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke-weight",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-icon",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-chevron",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-divider",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled no accent/default/design-filled-na-bg",
|
||||
"type": "color",
|
||||
@@ -11719,7 +11929,7 @@
|
||||
"name": "design/selection/default/design-selection-bg",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#0000001F"
|
||||
"value": "#00000014"
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-stroke",
|
||||
@@ -11734,13 +11944,10 @@
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-content",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-0"
|
||||
}
|
||||
"name": "design/selection/default/design-selection-stroke-weight-alt",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke",
|
||||
@@ -11748,6 +11955,15 @@
|
||||
"isAlias": false,
|
||||
"value": "#00000014"
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-content",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke-weight",
|
||||
"type": "number",
|
||||
@@ -11763,7 +11979,7 @@
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-0"
|
||||
"name": "base/base-1"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -12511,7 +12727,7 @@
|
||||
"name": "component/drawer/drawer-bg-default",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#F6F8FA00"
|
||||
"value": "#EEF2F400"
|
||||
},
|
||||
{
|
||||
"name": "component/drawer/drawer-bg-unfocused",
|
||||
@@ -13047,18 +13263,18 @@
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/black/black-base",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#333333"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-06",
|
||||
"type": "color",
|
||||
@@ -14427,6 +14643,15 @@
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-alt",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-6"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-icon",
|
||||
"type": "color",
|
||||
@@ -14720,18 +14945,18 @@
|
||||
"isAlias": false,
|
||||
"value": "#000000"
|
||||
},
|
||||
{
|
||||
"name": "base/base-white-fixed",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "backgrounds/content/bg-content-primary",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF29"
|
||||
},
|
||||
{
|
||||
"name": "base/base-white-fixed",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "divider/content/divider-accent",
|
||||
"type": "color",
|
||||
@@ -15284,6 +15509,63 @@
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF29"
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-bg",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "backgrounds/content/bg-content-primary"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF24"
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-stroke-weight",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-icon",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-chevron",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled white/default/design-filled-white-content-divider",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/filled no accent/default/design-filled-na-bg",
|
||||
"type": "color",
|
||||
@@ -16607,6 +16889,18 @@
|
||||
"isAlias": false,
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-stroke-weight-alt",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF1F"
|
||||
},
|
||||
{
|
||||
"name": "design/selection/default/design-selection-content",
|
||||
"type": "color",
|
||||
@@ -16616,12 +16910,6 @@
|
||||
"name": "base/base-0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF1F"
|
||||
},
|
||||
{
|
||||
"name": "design/plain no accent/focused/design-plain-na-focused-stroke-weight",
|
||||
"type": "number",
|
||||
@@ -17385,7 +17673,7 @@
|
||||
"name": "component/drawer/drawer-bg-default",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#F6F8FA00"
|
||||
"value": "#EEF2F400"
|
||||
},
|
||||
{
|
||||
"name": "component/drawer/drawer-bg-unfocused",
|
||||
@@ -17921,18 +18209,18 @@
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/black/black-base",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#333333"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-04",
|
||||
"type": "color",
|
||||
"isAlias": false,
|
||||
"value": "#FFFFFF"
|
||||
},
|
||||
{
|
||||
"name": "pallete/blue/blue-06",
|
||||
"type": "color",
|
||||
@@ -19301,6 +19589,15 @@
|
||||
"name": "base/base-7"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-alt",
|
||||
"type": "color",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "design",
|
||||
"name": "base/base-6"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "design/disabled/default/design-disabled-content-icon",
|
||||
"type": "color",
|
||||
@@ -19672,37 +19969,175 @@
|
||||
"value": "#0000000D"
|
||||
},
|
||||
{
|
||||
"name": "global/font/letter-spacing-2XL",
|
||||
"name": "global/font/font size/font-size-4XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 25
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-3XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 21
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-2XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 19
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 17
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-L",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 16
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-M",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 15
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-S",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 14
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 13
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-2XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 12
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-3XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 10
|
||||
},
|
||||
{
|
||||
"name": "global/font/font size/font-size-4XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 9
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-5XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 33
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-4XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 29
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-3XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 26
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-2XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 23
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 21
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-L",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 20
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-M",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 19
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-S",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 17
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 15
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-2XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 14
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-3XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 13
|
||||
},
|
||||
{
|
||||
"name": "global/font/line height/line-height-4XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 12
|
||||
},
|
||||
{
|
||||
"name": "global/font/letter spacing/letter-spacing-2XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0.75
|
||||
},
|
||||
{
|
||||
"name": "global/font/letter-spacing-XL",
|
||||
"name": "global/font/letter spacing/letter-spacing-XL",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 0.6499999761581421
|
||||
},
|
||||
{
|
||||
"name": "global/font/letter-spacing-L",
|
||||
"name": "global/font/letter spacing/letter-spacing-L",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": -0.05000000074505806
|
||||
},
|
||||
{
|
||||
"name": "global/font/letter-spacing-M",
|
||||
"name": "global/font/letter spacing/letter-spacing-M",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": -0.10000000149011612
|
||||
},
|
||||
{
|
||||
"name": "global/font/letter-spacing-S",
|
||||
"name": "global/font/letter spacing/letter-spacing-S",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": -0.20000000298023224
|
||||
},
|
||||
{
|
||||
"name": "global/font/letter-spacing-XS",
|
||||
"name": "global/font/letter spacing/letter-spacing-XS",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": -0.3499999940395355
|
||||
@@ -20098,12 +20533,12 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/toggle/button-toggle-XL-space-inset",
|
||||
"name": "component/button/space/submenu/button-submenu-XL-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "fixed",
|
||||
"name": "global/space/inset/space-inset-sm2"
|
||||
"name": "global/space/inset/space-inset-sm"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -20161,25 +20596,13 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/toggle/button-toggle-L-space-inset",
|
||||
"name": "component/button/space/submenu/button-submenu-L-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "fixed",
|
||||
"name": "global/space/inset/space-inset-sm"
|
||||
}
|
||||
"isAlias": false,
|
||||
"value": 9
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/toggle/button-toggle-M-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "fixed",
|
||||
"name": "global/space/inset/space-inset-xs2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/toggle/button-toggle-S-space-inset",
|
||||
"name": "component/button/space/submenu/button-submenu-M-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
@@ -20188,7 +20611,7 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/toggle/button-toggle-XS-space-inset",
|
||||
"name": "component/button/space/submenu/button-submenu-S-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
@@ -20197,7 +20620,13 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/toggle/button-toggle-2XS-space-inset",
|
||||
"name": "component/button/space/submenu/button-submenu-XS-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": false,
|
||||
"value": 5
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/submenu/button-submenu-2XS-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
@@ -20205,6 +20634,15 @@
|
||||
"name": "global/space/inset/space-inset-2xs"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/button/space/submenu/button-submenu-3XS-space-inset",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "fixed",
|
||||
"name": "global/space/inset/space-inset-3xs"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/area/box shadow/default/area-box-shadow-default-X",
|
||||
"type": "number",
|
||||
@@ -20716,7 +21154,7 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/popup-menu/pmenu-cell-space-inset-TB",
|
||||
"name": "component/popup-menu/pmenu-cell-space-inset-TB-M",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
@@ -20724,6 +21162,15 @@
|
||||
"name": "global/space/inset/space-inset-xs"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/popup-menu/pmenu-cell-space-inset-TB-L",
|
||||
"type": "number",
|
||||
"isAlias": true,
|
||||
"value": {
|
||||
"collection": "fixed",
|
||||
"name": "global/space/inset/space-inset-sm2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "component/popup-menu/pmenu-cell-space-inset-L",
|
||||
"type": "number",
|
||||
|
||||
@@ -335,7 +335,7 @@ function parseArgs()
|
||||
const args = process.argv.slice(2);
|
||||
let inputFile = defaultInputPath;
|
||||
let outputFile = defaultOutputPath;
|
||||
let excludeList = ['legacy', 'chat', 'stage', 'space', 'opacity', 'size', 'radius', 'component'];
|
||||
let excludeList = ['legacy', 'chat', 'stage', 'space', 'opacity', 'size', 'radius', 'component', 'font size', 'line height'];
|
||||
let collectionsFilter = ['design', 'fixed'];
|
||||
|
||||
args.forEach(arg =>
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,2 +1,2 @@
|
||||
const fs=require("fs");const path=require("path");const specialHexTokens=["backgrounds/state/bg-state-hover-default","backgrounds/state/bg-state-click-default","backgrounds/state/bg-state-hover-alt","backgrounds/state/bg-state-click-alt","backgrounds/state/bg-state-hover-default-overlay","backgrounds/state/bg-state-click-default-overlay","backgrounds/state/bg-state-hover-alt-overlay","backgrounds/state/bg-state-click-alt-overlay"];function applyCustomRules(e,t){if(e.type==="number"&&e.name.toLowerCase().includes("opacity")){return(e.value/100).toString()}return t}function shouldIgnoreToken(e,t){const n=e.split("/");for(const e of n){if(t.includes(e)){return true}}return false}function transformTokenName(e,t){const n=e.split("/");let s=n[n.length-1];s=s.replace(/\s+/g,"-").toLowerCase();const o=t==="color"?"color-":"";return`ui-${o}${s}`}function buildTokenLookup(e,t,n){const s={};e.forEach((e=>{if(n.length>0&&!n.includes(e.name)){return}const o=e.name;if(!s[o]){s[o]={}}e.modes.forEach((e=>{if(Array.isArray(e.variables)){e.variables.forEach((e=>{if(shouldIgnoreToken(e.name,t)){return}const n=transformTokenName(e.name,e.type);s[o][e.name]=n}))}}))}));return s}function generateCssVariables(e,t,n){let s="";e.forEach((e=>{if(shouldIgnoreToken(e.name,n)){return}const o=transformTokenName(e.name,e.type);if(specialHexTokens.includes(e.name)){const t=e.value;if(t&&t[0]==="#"&&t.length===9){const e=t.slice(0,7);const n=t.slice(7);const r=Math.round(parseInt(n,16)/255*100);s+=` --${o}-hex: ${e};\n`;s+=` --${o}-opacity: ${r}%;\n`}else{s+=` --${o}: ${e.value};\n`}s+=` --${o}: ${e.value};\n`;return}let r="";if(e.isAlias&&typeof e.value==="object"){const n=e.value.collection;const s=e.value.name;if(t[n]&&t[n][s]){const e=t[n][s];r=`var(--${e})`}else{console.error(`Alias target token not found: collection "${n}", name "${s}"`);r="undefined"}}else{if(e.type==="number"){const t=`${e.value}px`;r=applyCustomRules(e,t)}else{r=e.value}}if(e.name.toLowerCase().includes("blur")){if(e.isAlias&&typeof e.value==="object"){}else if(e.type==="number"){if(e.value===0){r="none"}else{const t=`${e.value}px`;const n=applyCustomRules(e,t);r=`blur(${n})`}}else{r=`blur(${r})`}}s+=` --${o}: ${r};\n`}));return s}function generateCss(e,t,n){const s=`/**\n * Do not edit directly\n * Generated on ${(new Date).toUTCString()}\n */\n\n`;const{collections:o}=e;const r=new Set;o.forEach((e=>{if(n.length>0&&!n.includes(e.name))return;e.modes.forEach((e=>{e.variables.forEach((e=>{if(!shouldIgnoreToken(e.name,t)&&e.name.toLowerCase().includes("bg-blur")){const t=transformTokenName(e.name,e.type);r.add(t)}}))}))}));const a=buildTokenLookup(o,t,n);let l=s;o.forEach((e=>{if(n.length>0&&!n.includes(e.name)){return}if(e.modes.length===1){const n=e.modes[0];l+=`:root {\n`;l+=generateCssVariables(n.variables,a,t);l+=`}\n\n`}else{const n=e.modes[0];const s=`--ui-context-${n.name.toLowerCase().replace(/\s+/g,"-")}`;l+=`:root, .${s} {\n`;l+=generateCssVariables(n.variables,a,t);l+=`}\n\n`;e.modes.forEach((e=>{if(e.name.toLowerCase()===n.name.toLowerCase()){return}const s=`--ui-context-${e.name.toLowerCase().replace(/\s+/g,"-")}`;l+=`.${s} {\n`;l+=generateCssVariables(e.variables,a,t);l+=`}\n\n`}))}}));if(r.size>0){l+=`.--ui-reset-bg-blur {\n`;r.forEach((e=>{l+=` --${e}: none;\n`}));l+=`}\n\n`}return l}function parseArgs(){const e="./src/figma-tokens.json";const t="./dist/air-design-tokens.css";const n=process.argv.slice(2);let s=e;let o=t;let r=["legacy","chat","stage","space","opacity","size","radius","component"];let a=["design","fixed"];n.forEach((e=>{if(e.startsWith("--input=")){s=e.split("=")[1]}else if(e.startsWith("--output=")){o=e.split("=")[1]}else if(e.startsWith("--exclude=")){r=e.split("=")[1].split(",").map((e=>e.trim()))}else if(e.startsWith("--collections=")){a=e.split("=")[1].split(",").map((e=>e.trim()))}}));return{input:path.resolve(s),output:path.resolve(o),exclude:r,collections:a}}function main(){const e=parseArgs();let t;try{const n=fs.readFileSync(e.input,"utf8");t=JSON.parse(n)}catch(e){console.error("Error reading or parsing JSON file:",e);process.exit(1)}let n="";try{const e=path.join(__dirname,"src","hoverable.css");n=fs.readFileSync(e,"utf8")}catch(e){console.error("Error reading hoverable.css:",e);process.exit(1)}const s=generateCss(t,e.exclude,e.collections);const o=`${s}${n}`;try{fs.writeFileSync(e.output,o,"utf8");console.log(`CSS file successfully generated: ${e.output}`)}catch(e){console.error("Error writing CSS file:",e);process.exit(1)}}main();
|
||||
const fs=require("fs");const path=require("path");const specialHexTokens=["backgrounds/state/bg-state-hover-default","backgrounds/state/bg-state-click-default","backgrounds/state/bg-state-hover-alt","backgrounds/state/bg-state-click-alt","backgrounds/state/bg-state-hover-default-overlay","backgrounds/state/bg-state-click-default-overlay","backgrounds/state/bg-state-hover-alt-overlay","backgrounds/state/bg-state-click-alt-overlay"];function applyCustomRules(e,t){if(e.type==="number"&&e.name.toLowerCase().includes("opacity")){return(e.value/100).toString()}return t}function shouldIgnoreToken(e,t){const n=e.split("/");for(const e of n){if(t.includes(e)){return true}}return false}function transformTokenName(e,t){const n=e.split("/");let s=n[n.length-1];s=s.replace(/\s+/g,"-").toLowerCase();const o=t==="color"?"color-":"";return`ui-${o}${s}`}function buildTokenLookup(e,t,n){const s={};e.forEach((e=>{if(n.length>0&&!n.includes(e.name)){return}const o=e.name;if(!s[o]){s[o]={}}e.modes.forEach((e=>{if(Array.isArray(e.variables)){e.variables.forEach((e=>{if(shouldIgnoreToken(e.name,t)){return}const n=transformTokenName(e.name,e.type);s[o][e.name]=n}))}}))}));return s}function generateCssVariables(e,t,n){let s="";e.forEach((e=>{if(shouldIgnoreToken(e.name,n)){return}const o=transformTokenName(e.name,e.type);if(specialHexTokens.includes(e.name)){const t=e.value;if(t&&t[0]==="#"&&t.length===9){const e=t.slice(0,7);const n=t.slice(7);const r=Math.round(parseInt(n,16)/255*100);s+=` --${o}-hex: ${e};\n`;s+=` --${o}-opacity: ${r}%;\n`}else{s+=` --${o}: ${e.value};\n`}s+=` --${o}: ${e.value};\n`;return}let r="";if(e.isAlias&&typeof e.value==="object"){const n=e.value.collection;const s=e.value.name;if(t[n]&&t[n][s]){const e=t[n][s];r=`var(--${e})`}else{console.error(`Alias target token not found: collection "${n}", name "${s}"`);r="undefined"}}else{if(e.type==="number"){const t=`${e.value}px`;r=applyCustomRules(e,t)}else{r=e.value}}if(e.name.toLowerCase().includes("blur")){if(e.isAlias&&typeof e.value==="object"){}else if(e.type==="number"){if(e.value===0){r="none"}else{const t=`${e.value}px`;const n=applyCustomRules(e,t);r=`blur(${n})`}}else{r=`blur(${r})`}}s+=` --${o}: ${r};\n`}));return s}function generateCss(e,t,n){const s=`/**\n * Do not edit directly\n * Generated on ${(new Date).toUTCString()}\n */\n\n`;const{collections:o}=e;const r=new Set;o.forEach((e=>{if(n.length>0&&!n.includes(e.name))return;e.modes.forEach((e=>{e.variables.forEach((e=>{if(!shouldIgnoreToken(e.name,t)&&e.name.toLowerCase().includes("bg-blur")){const t=transformTokenName(e.name,e.type);r.add(t)}}))}))}));const a=buildTokenLookup(o,t,n);let l=s;o.forEach((e=>{if(n.length>0&&!n.includes(e.name)){return}if(e.modes.length===1){const n=e.modes[0];l+=`:root {\n`;l+=generateCssVariables(n.variables,a,t);l+=`}\n\n`}else{const n=e.modes[0];const s=`--ui-context-${n.name.toLowerCase().replace(/\s+/g,"-")}`;l+=`:root, .${s} {\n`;l+=generateCssVariables(n.variables,a,t);l+=`}\n\n`;e.modes.forEach((e=>{if(e.name.toLowerCase()===n.name.toLowerCase()){return}const s=`--ui-context-${e.name.toLowerCase().replace(/\s+/g,"-")}`;l+=`.${s} {\n`;l+=generateCssVariables(e.variables,a,t);l+=`}\n\n`}))}}));if(r.size>0){l+=`.--ui-reset-bg-blur {\n`;r.forEach((e=>{l+=` --${e}: none;\n`}));l+=`}\n\n`}return l}function parseArgs(){const e="./src/figma-tokens.json";const t="./dist/air-design-tokens.css";const n=process.argv.slice(2);let s=e;let o=t;let r=["legacy","chat","stage","space","opacity","size","radius","component","font size","line height"];let a=["design","fixed"];n.forEach((e=>{if(e.startsWith("--input=")){s=e.split("=")[1]}else if(e.startsWith("--output=")){o=e.split("=")[1]}else if(e.startsWith("--exclude=")){r=e.split("=")[1].split(",").map((e=>e.trim()))}else if(e.startsWith("--collections=")){a=e.split("=")[1].split(",").map((e=>e.trim()))}}));return{input:path.resolve(s),output:path.resolve(o),exclude:r,collections:a}}function main(){const e=parseArgs();let t;try{const n=fs.readFileSync(e.input,"utf8");t=JSON.parse(n)}catch(e){console.error("Error reading or parsing JSON file:",e);process.exit(1)}let n="";try{const e=path.join(__dirname,"src","hoverable.css");n=fs.readFileSync(e,"utf8")}catch(e){console.error("Error reading hoverable.css:",e);process.exit(1)}const s=generateCss(t,e.exclude,e.collections);const o=`${s}${n}`;try{fs.writeFileSync(e.output,o,"utf8");console.log(`CSS file successfully generated: ${e.output}`)}catch(e){console.error("Error writing CSS file:",e);process.exit(1)}}main();
|
||||
//# sourceMappingURL=tokens-converter.map.js
|
||||
-5252
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@@ -2,7 +2,6 @@
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_ACCEPT_BUTTON"] = "Anwenden";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_CANCEL_BUTTON"] = "Abbrechen";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SELECT_ALL_MSGVER_1"] = "alle auswählen";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_DESCRIPTION"] = "Versuchen Sie ein anderes Suchkriterium.";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_DESCRIPTION_MSGVER_1"] = "Ändern Sie Ihre Suchparameter";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_TITLE_MSGVER_1"] = "Nicht gefunden";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_MSGVER_1"] = "standardmäßig";
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_ACCEPT_BUTTON"] = "Apply";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_CANCEL_BUTTON"] = "Cancel";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SELECT_ALL_MSGVER_1"] = "select all";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_DESCRIPTION"] = "Try a different search criteria.";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_DESCRIPTION_MSGVER_1"] = "change your search parameters";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_TITLE_MSGVER_1"] = "Not found";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_MSGVER_1"] = "default";
|
||||
|
||||
@@ -1,13 +1,8 @@
|
||||
<?php
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_ACCEPT_BUTTON"] = "Қолдану";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_CANCEL_BUTTON"] = "Болдырмау";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SELECT_ALL"] = "Барлығын таңдау";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SELECT_ALL_MSGVER_1"] = "барлығын таңдау";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS"] = "Әдепкі бойынша";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_DESELECT_ALL"] = "Барлығын болдырмау";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_DESCRIPTION"] = "Іздеуге сұрауды өзгертіп көріңіз";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_DESCRIPTION_MSGVER_1"] = "Іздеу параметрлерін өзгертіңіз";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_TITLE"] = "Ештеңе табылған жоқ";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_EMPTY_STATE_TITLE_MSGVER_1"] = "Табылмады";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_MSGVER_1"] = "әдепкі бойынша";
|
||||
$MESS["UI_CHECKBOX_LIST_DEFAULT_SETTINGS_PLACEHOLDER"] = "Іздеу";
|
||||
|
||||
@@ -19,6 +19,10 @@
|
||||
font-size: var(--ui-font-size-md);
|
||||
}
|
||||
|
||||
.ui-message-box.--air:has(.popup-window-buttons) {
|
||||
padding-bottom: 0;
|
||||
}
|
||||
|
||||
.ui-message-box .popup-window-titlebar + .popup-window-content {
|
||||
padding-top: 10px;
|
||||
text-align: left;
|
||||
@@ -40,4 +44,4 @@
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
gap: 6px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -123,6 +123,7 @@ this.BX.UI = this.BX.UI || {};
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {});
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {}, 'Proceed', () => {});
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {}, 'Proceed', () => {}, 'Cancel');
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {}, 'Proceed', () => {}, 'Cancel', true);
|
||||
*/
|
||||
static confirm(message, ...args) {
|
||||
let title = null;
|
||||
@@ -130,11 +131,12 @@ this.BX.UI = this.BX.UI || {};
|
||||
let okCaption = null;
|
||||
let cancelCallback = null;
|
||||
let cancelCaption = null;
|
||||
let useAirDesign = false;
|
||||
if (args.length > 0) {
|
||||
if (main_core.Type.isString(args[0])) {
|
||||
[title, okCallback, okCaption, cancelCallback, cancelCaption] = args;
|
||||
if (main_core.Type.isString(args[0]) || main_core.Type.isNull(args[0])) {
|
||||
[title, okCallback, okCaption, cancelCallback, cancelCaption, useAirDesign] = args;
|
||||
} else {
|
||||
[okCallback, okCaption, cancelCallback, cancelCaption] = args;
|
||||
[okCallback, okCaption, cancelCallback, cancelCaption, useAirDesign] = args;
|
||||
}
|
||||
}
|
||||
const messageBox = this.create({
|
||||
@@ -142,6 +144,7 @@ this.BX.UI = this.BX.UI || {};
|
||||
title,
|
||||
okCaption,
|
||||
cancelCaption,
|
||||
useAirDesign,
|
||||
onOk: okCallback,
|
||||
onCancel: cancelCallback,
|
||||
buttons: BX.UI.Dialogs.MessageBoxButtons.OK_CANCEL
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
|
||||
.ui-message-box .popup-window-buttons{padding:15px 20px}.ui-message-box-medium-buttons .popup-window-buttons{padding:16px 0 17px;margin:0 20px;border-top:1px solid rgba(82,92,105,.1)}.ui-message-box .popup-window-content{padding:20px 20px 30px;text-align:center;line-height:var(--ui-font-line-height-md);font-size:var(--ui-font-size-md)}.ui-message-box .popup-window-titlebar+.popup-window-content{padding-top:10px;text-align:left}.ui-message-box .popup-window-titlebar{height:auto}.ui-message-box .popup-window-titlebar-text{color:#535c69;padding:18px 40px 0 20px;line-height:normal;white-space:normal}.ui-message-box.--air .popup-window-buttons{display:flex;justify-content:center;gap:6px}
|
||||
.ui-message-box .popup-window-buttons{padding:15px 20px}.ui-message-box-medium-buttons .popup-window-buttons{padding:16px 0 17px;margin:0 20px;border-top:1px solid rgba(82,92,105,.1)}.ui-message-box .popup-window-content{padding:20px 20px 30px;text-align:center;line-height:var(--ui-font-line-height-md);font-size:var(--ui-font-size-md)}.ui-message-box.--air:has(.popup-window-buttons){padding-bottom:0}.ui-message-box .popup-window-titlebar+.popup-window-content{padding-top:10px;text-align:left}.ui-message-box .popup-window-titlebar{height:auto}.ui-message-box .popup-window-titlebar-text{color:#535c69;padding:18px 40px 0 20px;line-height:normal;white-space:normal}.ui-message-box.--air .popup-window-buttons{display:flex;justify-content:center;gap:6px}
|
||||
File diff suppressed because one or more lines are too long
@@ -19,6 +19,10 @@
|
||||
font-size: var(--ui-font-size-md);
|
||||
}
|
||||
|
||||
.ui-message-box.--air:has(.popup-window-buttons) {
|
||||
padding-bottom: 0;
|
||||
}
|
||||
|
||||
.ui-message-box .popup-window-titlebar + .popup-window-content {
|
||||
padding-top: 10px;
|
||||
text-align: left;
|
||||
@@ -40,4 +44,4 @@
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
gap: 6px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -136,6 +136,7 @@ export default class MessageBox
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {});
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {}, 'Proceed', () => {});
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {}, 'Proceed', () => {}, 'Cancel');
|
||||
* BX.UI.Dialogs.MessageBox.confirm('Message', 'Title', () => {}, 'Proceed', () => {}, 'Cancel', true);
|
||||
*/
|
||||
static confirm(message: string, ...args): MessageBox
|
||||
{
|
||||
@@ -144,16 +145,17 @@ export default class MessageBox
|
||||
let okCaption = null;
|
||||
let cancelCallback = null;
|
||||
let cancelCaption = null;
|
||||
let useAirDesign = false;
|
||||
|
||||
if (args.length > 0)
|
||||
{
|
||||
if (Type.isString(args[0]))
|
||||
if (Type.isString(args[0]) || Type.isNull(args[0]))
|
||||
{
|
||||
[title, okCallback, okCaption, cancelCallback, cancelCaption] = args;
|
||||
[title, okCallback, okCaption, cancelCallback, cancelCaption, useAirDesign] = args;
|
||||
}
|
||||
else
|
||||
{
|
||||
[okCallback, okCaption, cancelCallback, cancelCaption] = args;
|
||||
[okCallback, okCaption, cancelCallback, cancelCaption, useAirDesign] = args;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -162,6 +164,7 @@ export default class MessageBox
|
||||
title,
|
||||
okCaption,
|
||||
cancelCaption,
|
||||
useAirDesign,
|
||||
onOk: okCallback,
|
||||
onCancel: cancelCallback,
|
||||
buttons: BX.UI.Dialogs.MessageBoxButtons.OK_CANCEL,
|
||||
|
||||
@@ -13,6 +13,8 @@ return [
|
||||
'ui.vue3.components.hint',
|
||||
'ui.feedback.form',
|
||||
'ui.icons',
|
||||
'ui.cnt',
|
||||
'ui.vue3.components.counter',
|
||||
'ui.advice',
|
||||
'ui.vue3.pinia',
|
||||
'main.popup',
|
||||
|
||||
@@ -156,12 +156,6 @@
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__recently {
|
||||
padding-right: 12px;
|
||||
box-sizing: border-box;
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__main-groups-content {
|
||||
max-height: 100%;
|
||||
width: 100%;
|
||||
@@ -195,6 +189,23 @@
|
||||
margin-top: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content li {
|
||||
box-sizing: border-box;
|
||||
border-radius: 8px;
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content ul {
|
||||
padding-right: 12px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content .ui-entity-catalog__menu_item:not(.ui-entity-catalog__menu_item:first-child)::before {
|
||||
content: none;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content .ui-entity-catalog__menu {
|
||||
overflow: hidden;
|
||||
}
|
||||
.ui-entity-catalog__main-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
@@ -417,6 +428,11 @@
|
||||
.ui-entity-catalog__menu_item.--disabled .ui-entity-catalog__svg-icon-blue {
|
||||
fill: var(--ui-color-base-40, #bdc1c6);
|
||||
}
|
||||
|
||||
.ui-entity-catalog__menu_item-entity-count {
|
||||
position: absolute;
|
||||
right: calc(5px + 16px + 4px);
|
||||
}
|
||||
.ui-entity-catalog__option {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
@@ -446,4 +462,13 @@
|
||||
font-size: var(--ui-font-size-md, 14px);
|
||||
line-height: var(--ui-font-line-height-xl, 1.62);
|
||||
opacity: 0.4;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__option-info_top_text {
|
||||
font-weight: var(--ui-font-weight-semi-bold, 500);
|
||||
font-size: var(--ui-font-size-5xs, 9px);
|
||||
line-height: 100%;
|
||||
letter-spacing: 0;
|
||||
color: var(--ui-color-palette-blue-50);
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
+470
-165
@@ -1,6 +1,6 @@
|
||||
/* eslint-disable */
|
||||
this.BX = this.BX || {};
|
||||
(function (exports,ui_vue3,ui_vue3_components_hint,ui_feedback_form,ui_icons,ui_advice,item,button,ui_vue3_pinia,group,main_popup,main_core_events,main_core,group$1) {
|
||||
(function (exports,ui_vue3,ui_vue3_components_hint,ui_feedback_form,ui_icons,ui_cnt,ui_vue3_components_counter,ui_advice,item,button,ui_vue3_pinia,group,main_popup,main_core_events,main_core,group$1) {
|
||||
'use strict';
|
||||
|
||||
const feedback = {
|
||||
@@ -15,7 +15,11 @@ this.BX = this.BX || {};
|
||||
const Group = {
|
||||
emits: ['selected', 'unselected'],
|
||||
name: 'ui-entity-catalog-group',
|
||||
components: {
|
||||
Counter: ui_vue3_components_counter.Counter
|
||||
},
|
||||
props: {
|
||||
/** @type GroupData */
|
||||
groupData: {
|
||||
type: group.GroupData,
|
||||
required: true
|
||||
@@ -24,6 +28,16 @@ this.BX = this.BX || {};
|
||||
computed: {
|
||||
hasIcon() {
|
||||
return main_core.Type.isStringFilled(this.groupData.icon);
|
||||
},
|
||||
getCounterStyle() {
|
||||
return ui_cnt.CounterStyle.FILLED_SUCCESS;
|
||||
},
|
||||
getCounterValue() {
|
||||
var _this$groupData$custo, _this$groupData;
|
||||
const custom = (_this$groupData$custo = (_this$groupData = this.groupData) == null ? void 0 : _this$groupData.customData) != null ? _this$groupData$custo : {};
|
||||
const value = custom.counterValue;
|
||||
const isValueInteger = Number.isInteger(value);
|
||||
return isValueInteger && value > 0 ? value : null;
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
@@ -37,16 +51,26 @@ this.BX = this.BX || {};
|
||||
},
|
||||
template: `
|
||||
<slot name="group" v-bind:groupData="groupData" v-bind:handleClick="handleClick">
|
||||
<li
|
||||
<li
|
||||
:class="{
|
||||
'ui-entity-catalog__menu_item': true,
|
||||
'--active': groupData.selected,
|
||||
'--disabled': groupData.disabled
|
||||
'--disabled': groupData.disabled,
|
||||
}"
|
||||
@click="handleClick"
|
||||
>
|
||||
<span class="ui-entity-catalog__menu_item-icon" v-if="hasIcon" v-html="groupData.icon"/>
|
||||
<span class="ui-entity-catalog__menu_item-text">{{ groupData.name }}</span>
|
||||
<span
|
||||
v-if="getCounterValue !== null"
|
||||
class="ui-entity-catalog__menu_item-entity-count"
|
||||
>
|
||||
<Counter
|
||||
:value="getCounterValue"
|
||||
:style="getCounterStyle"
|
||||
>
|
||||
</Counter>
|
||||
</span>
|
||||
</li>
|
||||
</slot>
|
||||
`
|
||||
@@ -59,11 +83,29 @@ this.BX = this.BX || {};
|
||||
Group
|
||||
},
|
||||
props: {
|
||||
/** @type Array<Array<GroupData>> */
|
||||
groups: {
|
||||
type: Array,
|
||||
required: true
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
groupLists() {
|
||||
if (!this.groups || this.groups.length === 0) {
|
||||
return [];
|
||||
}
|
||||
if (Array.isArray(this.groups[0])) {
|
||||
return this.groups;
|
||||
}
|
||||
return [this.groups];
|
||||
},
|
||||
headerLists() {
|
||||
return this.groupLists.map(list => list.filter(g => !!g.isHeaderGroup)).filter(list => list.length > 0);
|
||||
},
|
||||
mainLists() {
|
||||
return this.groupLists.map(list => list.filter(g => !g.isHeaderGroup)).filter(list => list.length > 0);
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
handleGroupSelected(group$$1) {
|
||||
this.$emit('groupSelected', group$$1);
|
||||
@@ -73,23 +115,58 @@ this.BX = this.BX || {};
|
||||
}
|
||||
},
|
||||
template: `
|
||||
<ul class="ui-entity-catalog__menu">
|
||||
<Group
|
||||
:group-data="group"
|
||||
:key="group.id"
|
||||
v-for="group in groups"
|
||||
@selected="handleGroupSelected"
|
||||
@unselected="handleGroupUnselected"
|
||||
<div>
|
||||
<div
|
||||
class="ui-entity-catalog__header-groups-content"
|
||||
v-if="headerLists && headerLists.length"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
<slot
|
||||
name="group"
|
||||
v-bind:groupData="groupSlotProps.groupData"
|
||||
v-bind:handleClick="groupSlotProps.handleClick"
|
||||
/>
|
||||
</template>
|
||||
</Group>
|
||||
</ul>
|
||||
<ul
|
||||
class="ui-entity-catalog__menu"
|
||||
v-for="(groupList, listIndex) in headerLists"
|
||||
:key="'header-'+listIndex"
|
||||
>
|
||||
<Group
|
||||
:group-data="group"
|
||||
:key="group.id"
|
||||
v-for="group in groupList"
|
||||
@selected="handleGroupSelected"
|
||||
@unselected="handleGroupUnselected"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
<slot
|
||||
name="group"
|
||||
v-bind:groupData="groupSlotProps.groupData"
|
||||
v-bind:handleClick="groupSlotProps.handleClick"
|
||||
/>
|
||||
</template>
|
||||
</Group>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<ul
|
||||
class="ui-entity-catalog__menu"
|
||||
v-for="(groupList, listIndex) in mainLists"
|
||||
:key="'main-'+listIndex"
|
||||
>
|
||||
<Group
|
||||
:group-data="group"
|
||||
:key="group.id"
|
||||
v-for="group in groupList"
|
||||
@selected="handleGroupSelected"
|
||||
@unselected="handleGroupUnselected"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
<slot
|
||||
name="group"
|
||||
v-bind:groupData="groupSlotProps.groupData"
|
||||
v-bind:handleClick="groupSlotProps.handleClick"
|
||||
/>
|
||||
</template>
|
||||
</Group>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
`
|
||||
};
|
||||
|
||||
@@ -100,85 +177,45 @@ this.BX = this.BX || {};
|
||||
GroupList
|
||||
},
|
||||
props: {
|
||||
recentGroupData: {
|
||||
type: group$1.GroupData,
|
||||
required: false
|
||||
},
|
||||
groups: {
|
||||
/** @type Array<Array<GroupData>> */
|
||||
type: Array,
|
||||
required: true
|
||||
},
|
||||
showRecentGroup: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
searching: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
selectedGroup: {
|
||||
/** @type GroupData */
|
||||
type: Object,
|
||||
default: null
|
||||
}
|
||||
},
|
||||
data() {
|
||||
var _this$recentGroupData, _this$groups$find;
|
||||
const recentGroup = this.getRecentGroup();
|
||||
recentGroup[0] = Object.assign(recentGroup[0], (_this$recentGroupData = this.recentGroupData) != null ? _this$recentGroupData : {});
|
||||
let selectedGroup = (_this$groups$find = this.groups.find(group$$1 => group$$1.selected)) != null ? _this$groups$find : null;
|
||||
if (!selectedGroup) {
|
||||
var _recentGroup$find;
|
||||
selectedGroup = (_recentGroup$find = recentGroup.find(group$$1 => group$$1.selected)) != null ? _recentGroup$find : null;
|
||||
}
|
||||
return {
|
||||
shownGroups: this.groups,
|
||||
selectedGroup: null,
|
||||
recentGroup
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
selectedGroup(newGroup) {
|
||||
const newGroupId = newGroup ? newGroup.id : null;
|
||||
this.shownGroups = this.shownGroups.map(groupList => groupList.map(group$$1 => ({
|
||||
...group$$1,
|
||||
selected: group$$1.id === newGroupId
|
||||
})));
|
||||
if (this.showRecentGroup && newGroupId !== this.recentGroup[0].id) {
|
||||
this.recentGroup = [Object.assign(this.recentGroup[0], {
|
||||
selected: false
|
||||
})];
|
||||
}
|
||||
this.$emit('groupSelected', newGroup);
|
||||
}
|
||||
},
|
||||
beforeUpdate() {
|
||||
if (this.searching) {
|
||||
this.shownGroups = this.shownGroups.map(groupList => groupList.map(group$$1 => ({
|
||||
...group$$1,
|
||||
selected: false
|
||||
})));
|
||||
this.recentGroup = [Object.assign(this.recentGroup[0], {
|
||||
selected: false
|
||||
})];
|
||||
computed: {
|
||||
processedGroups() {
|
||||
const selectedGroupId = this.searching ? null : this.selectedGroup ? this.selectedGroup.id : null;
|
||||
const groupsClone = BX.Runtime.clone(this.groups);
|
||||
groupsClone.forEach(groupList => {
|
||||
groupList.forEach(group$$1 => {
|
||||
group$$1.selected = group$$1.id === selectedGroupId;
|
||||
});
|
||||
});
|
||||
return groupsClone;
|
||||
},
|
||||
headerLists() {
|
||||
return this.processedGroups.map(list => list.filter(g => g.isHeaderGroup)).filter(list => list.length > 0);
|
||||
},
|
||||
mainLists() {
|
||||
return this.processedGroups.map(list => list.filter(g => !g.isHeaderGroup)).filter(list => list.length > 0);
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
getRecentGroup() {
|
||||
return [{
|
||||
id: 'recent',
|
||||
name: main_core.Loc.getMessage('UI_JS_ENTITY_CATALOG_GROUP_LIST_RECENT_GROUP_DEFAULT_NAME'),
|
||||
icon: `
|
||||
<svg width="18" height="14" viewBox="0 0 18 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path class="ui-entity-catalog__svg-icon-blue" fill-rule="evenodd" clip-rule="evenodd" d="M9.369 13.2593C13.0305 13.2593 15.9986 10.2911 15.9986 6.62965C15.9986 2.9682 13.0305 0 9.369 0C6.00693 0 3.22939 2.50263 2.79764 5.74663H0L3.69844 9.44506L7.39687 5.74663H4.48558C4.90213 3.4276 6.93006 1.66789 9.369 1.66789C12.1093 1.66789 14.3308 3.88935 14.3308 6.62965C14.3308 9.36995 12.1093 11.5914 9.369 11.5914C9.2435 11.5914 9.11909 11.5867 8.99593 11.5776V13.249C9.11941 13.2558 9.2438 13.2593 9.369 13.2593ZM10.0865 4.01429H8.41983V8.18096H9.65978H10.0865H12.1195V6.56367H10.0865V4.01429Z"></path>
|
||||
</svg>
|
||||
`
|
||||
}];
|
||||
},
|
||||
handleGroupSelected(group$$1) {
|
||||
this.selectedGroup = group$$1;
|
||||
},
|
||||
handleRecentGroupSelected(group$$1) {
|
||||
group$$1.selected = true;
|
||||
this.selectedGroup = group$$1;
|
||||
this.$emit('groupSelected', group$$1);
|
||||
},
|
||||
handleGroupUnselected() {
|
||||
this.selectedGroup = null;
|
||||
this.$emit('groupSelected', null);
|
||||
}
|
||||
},
|
||||
template: `
|
||||
@@ -186,10 +223,13 @@ this.BX = this.BX || {};
|
||||
<div class="ui-entity-catalog__main-groups-head">
|
||||
<slot name="group-list-header"/>
|
||||
</div>
|
||||
<div class="ui-entity-catalog__recently" v-if="showRecentGroup">
|
||||
<div
|
||||
class="ui-entity-catalog__header-groups-content"
|
||||
v-if="headerLists && headerLists.length"
|
||||
>
|
||||
<GroupList
|
||||
:groups="recentGroup"
|
||||
@groupSelected="handleRecentGroupSelected"
|
||||
:groups="headerLists"
|
||||
@groupSelected="handleGroupSelected"
|
||||
@groupUnselected="handleGroupUnselected"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
@@ -203,8 +243,7 @@ this.BX = this.BX || {};
|
||||
</div>
|
||||
<div class="ui-entity-catalog__main-groups-content">
|
||||
<GroupList
|
||||
:groups="groupList"
|
||||
v-for="groupList in shownGroups"
|
||||
:groups="mainLists"
|
||||
@groupSelected="handleGroupSelected"
|
||||
@groupUnselected="handleGroupUnselected"
|
||||
>
|
||||
@@ -317,12 +356,29 @@ this.BX = this.BX || {};
|
||||
this.itemData.button = {};
|
||||
}
|
||||
return this.itemData.button;
|
||||
},
|
||||
topText() {
|
||||
var _this$itemData$custom, _this$itemData;
|
||||
const custom = (_this$itemData$custom = (_this$itemData = this.itemData) == null ? void 0 : _this$itemData.customData) != null ? _this$itemData$custom : {};
|
||||
if (main_core.Type.isStringFilled(custom.topText)) {
|
||||
return custom.topText;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
},
|
||||
template: `
|
||||
<slot name="item" v-bind:itemData="itemData">
|
||||
<div class="ui-entity-catalog__option">
|
||||
<div
|
||||
class="ui-entity-catalog__option"
|
||||
:data-item-id="String(itemData.id)"
|
||||
>
|
||||
<div class="ui-entity-catalog__option-info">
|
||||
<div
|
||||
v-if="topText"
|
||||
class="ui-entity-catalog__option-info_top_text"
|
||||
>
|
||||
{{ topText }}
|
||||
</div>
|
||||
<div class="ui-entity-catalog__option-info_name">
|
||||
<span>{{itemData.title}}</span>
|
||||
<span class="ui-entity-catalog__option-info_label" v-if="itemData.subtitle">{{itemData.subtitle}}</span>
|
||||
@@ -344,6 +400,7 @@ this.BX = this.BX || {};
|
||||
},
|
||||
props: {
|
||||
items: {
|
||||
/** @type Array<ItemData> */
|
||||
Type: Array,
|
||||
required: true
|
||||
}
|
||||
@@ -399,10 +456,12 @@ this.BX = this.BX || {};
|
||||
},
|
||||
props: {
|
||||
items: {
|
||||
/** @type Array<ItemData> */
|
||||
type: Array,
|
||||
required: true
|
||||
},
|
||||
itemsToShow: {
|
||||
/** @type Array<ItemData> */
|
||||
type: Array
|
||||
},
|
||||
group: {
|
||||
@@ -679,14 +738,12 @@ this.BX = this.BX || {};
|
||||
Search
|
||||
},
|
||||
props: {
|
||||
recentGroupData: {
|
||||
type: group$1.GroupData,
|
||||
required: false
|
||||
},
|
||||
/** @type Array<Array<GroupData>> */
|
||||
groups: {
|
||||
type: Array,
|
||||
required: true
|
||||
},
|
||||
/** @type Array<ItemData> */
|
||||
items: {
|
||||
type: Array,
|
||||
required: true
|
||||
@@ -695,10 +752,6 @@ this.BX = this.BX || {};
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
showRecentGroup: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
},
|
||||
filterOptions: {
|
||||
type: Object,
|
||||
default: {
|
||||
@@ -708,7 +761,7 @@ this.BX = this.BX || {};
|
||||
}
|
||||
},
|
||||
data() {
|
||||
var _this$recentGroupData, _selectedGroup$id, _selectedGroup;
|
||||
var _selectedGroup$id, _selectedGroup;
|
||||
let selectedGroup = null;
|
||||
for (const groupList of this.groups) {
|
||||
selectedGroup = groupList.find(group$$1 => group$$1.selected);
|
||||
@@ -716,18 +769,11 @@ this.BX = this.BX || {};
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (main_core.Type.isNil(selectedGroup) && (_this$recentGroupData = this.recentGroupData) != null && _this$recentGroupData.selected) {
|
||||
var _this$recentGroupData2;
|
||||
selectedGroup = {
|
||||
id: 'recent',
|
||||
...((_this$recentGroupData2 = this.recentGroupData) != null ? _this$recentGroupData2 : {})
|
||||
};
|
||||
}
|
||||
return {
|
||||
selectedGroup,
|
||||
selectedGroupId: (_selectedGroup$id = (_selectedGroup = selectedGroup) == null ? void 0 : _selectedGroup.id) != null ? _selectedGroup$id : null,
|
||||
shownItems: [],
|
||||
shownGroups: this.getDisplayedGroup(),
|
||||
shownGroups: [],
|
||||
lastSearchString: '',
|
||||
filters: []
|
||||
};
|
||||
@@ -738,6 +784,34 @@ this.BX = this.BX || {};
|
||||
const items = this.items.filter(item$$1 => item$$1.groupIds.some(id => id === this.selectedGroupId));
|
||||
return (_this$selectedGroup = this.selectedGroup) != null && _this$selectedGroup.compare ? items.sort(this.selectedGroup.compare) : items;
|
||||
},
|
||||
computedShownGroups() {
|
||||
if (this.showEmptyGroups) {
|
||||
return main_core.Runtime.clone(this.groups);
|
||||
}
|
||||
const groupIdsWithItems = new Set();
|
||||
this.items.forEach(item$$1 => {
|
||||
item$$1.groupIds.forEach(groupId => groupIdsWithItems.add(groupId));
|
||||
});
|
||||
return this.groups.map(groupList => groupList.filter(group$$1 => group$$1.isHeaderGroup === true || groupIdsWithItems.has(group$$1.id))).filter(list => list.length > 0);
|
||||
},
|
||||
computedShownItems() {
|
||||
if (this.searching && main_core.Type.isStringFilled(this.lastSearchString)) {
|
||||
const q = this.lastSearchString;
|
||||
let result = this.items.filter(item$$1 => {
|
||||
var _item$tags;
|
||||
return String(item$$1.title).toLowerCase().includes(q) || String(item$$1.description).toLowerCase().includes(q) || ((_item$tags = item$$1.tags) == null ? void 0 : _item$tags.some(tag => tag === q));
|
||||
});
|
||||
for (const filterId in this.filters) {
|
||||
result = result.filter(this.filters[filterId].action);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
let result = this.itemsBySelectedGroupId.slice();
|
||||
for (const filterId in this.filters) {
|
||||
result = result.filter(this.filters[filterId].action);
|
||||
}
|
||||
return result;
|
||||
},
|
||||
...ui_vue3_pinia.mapWritableState(useGlobalState, {
|
||||
searchQuery: 'searchQuery',
|
||||
searching: 'searchApplied',
|
||||
@@ -747,21 +821,33 @@ this.BX = this.BX || {};
|
||||
})
|
||||
},
|
||||
watch: {
|
||||
computedShownItems: {
|
||||
handler() {
|
||||
this.$nextTick(() => {
|
||||
this.$emit('itemsRendered');
|
||||
});
|
||||
},
|
||||
flush: 'post'
|
||||
},
|
||||
computedShownGroups: {
|
||||
immediate: true,
|
||||
handler(newVal) {
|
||||
// quick replace in-place to keep same array object reference
|
||||
this.shownGroups.splice(0, this.shownGroups.length, ...newVal);
|
||||
if (!this.selectedGroupId) {
|
||||
const selected = this.shownGroups.flat().find(g => g.selected);
|
||||
if (selected) {
|
||||
this.selectedGroup = selected;
|
||||
this.selectedGroupId = selected.id;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
selectedGroup() {
|
||||
this.shouldShowWelcomeStub = false;
|
||||
this.globalGroup = this.selectedGroup;
|
||||
},
|
||||
selectedGroupId() {
|
||||
if (this.searching) {
|
||||
return;
|
||||
}
|
||||
this.shownItems = this.itemsBySelectedGroupId;
|
||||
this.applyFilters();
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.shownItems = this.itemsBySelectedGroupId;
|
||||
},
|
||||
methods: {
|
||||
getDisplayedGroup() {
|
||||
if (this.showEmptyGroups) {
|
||||
@@ -773,7 +859,7 @@ this.BX = this.BX || {};
|
||||
groupIdsWithItems.add(groupId);
|
||||
});
|
||||
});
|
||||
return this.groups.map(groupList => groupList.filter(group$$1 => groupIdsWithItems.has(group$$1.id))).filter(groupList => groupList.length > 0);
|
||||
return this.groups.map(groupList => groupList.filter(group$$1 => group$$1.isHeaderGroup === true || groupIdsWithItems.has(group$$1.id))).filter(groupList => groupList.length > 0);
|
||||
},
|
||||
handleGroupSelected(group$$1) {
|
||||
var _this$$refs$search;
|
||||
@@ -795,8 +881,8 @@ this.BX = this.BX || {};
|
||||
this.selectedGroup = null;
|
||||
this.selectedGroupId = null;
|
||||
this.shownItems = this.items.filter(item$$1 => {
|
||||
var _item$tags;
|
||||
return String(item$$1.title).toLowerCase().includes(queryString) || String(item$$1.description).toLowerCase().includes(queryString) || ((_item$tags = item$$1.tags) == null ? void 0 : _item$tags.some(tag => tag === queryString));
|
||||
var _item$tags2;
|
||||
return String(item$$1.title).toLowerCase().includes(queryString) || String(item$$1.description).toLowerCase().includes(queryString) || ((_item$tags2 = item$$1.tags) == null ? void 0 : _item$tags2.some(tag => tag === queryString));
|
||||
});
|
||||
this.applyFilters();
|
||||
},
|
||||
@@ -832,11 +918,10 @@ this.BX = this.BX || {};
|
||||
template: `
|
||||
<div class="ui-entity-catalog__main">
|
||||
<MainGroups
|
||||
:recent-group-data="this.recentGroupData"
|
||||
:groups="this.shownGroups"
|
||||
:show-recent-group="showRecentGroup"
|
||||
:searching="searching"
|
||||
@group-selected="handleGroupSelected"
|
||||
:selected-group="selectedGroup"
|
||||
>
|
||||
<template #group-list-header>
|
||||
<slot name="group-list-header"/>
|
||||
@@ -854,7 +939,7 @@ this.BX = this.BX || {};
|
||||
</MainGroups>
|
||||
<MainContent
|
||||
:items="itemsBySelectedGroupId"
|
||||
:items-to-show="shownItems"
|
||||
:items-to-show="computedShownItems"
|
||||
:group="selectedGroup"
|
||||
:searching="searching"
|
||||
>
|
||||
@@ -922,21 +1007,25 @@ this.BX = this.BX || {};
|
||||
var _customTitleBar = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("customTitleBar");
|
||||
var _groups = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("groups");
|
||||
var _items = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("items");
|
||||
var _recentGroupData = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("recentGroupData");
|
||||
var _showEmptyGroups = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("showEmptyGroups");
|
||||
var _showRecentGroup = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("showRecentGroup");
|
||||
var _showSearch = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("showSearch");
|
||||
var _filterOptions = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("filterOptions");
|
||||
var _application = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("application");
|
||||
var _slots = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("slots");
|
||||
var _customComponents = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("customComponents");
|
||||
var _recentGroupData = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("recentGroupData");
|
||||
var _showRecentGroup = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("showRecentGroup");
|
||||
var _vueInstance = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("vueInstance");
|
||||
var _resolveGroupsForTemplate = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("resolveGroupsForTemplate");
|
||||
var _attachTemplate = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("attachTemplate");
|
||||
var _getDefaultPopupOptions = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("getDefaultPopupOptions");
|
||||
var _getPopupTitleBar = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("getPopupTitleBar");
|
||||
var _handleClose = /*#__PURE__*/babelHelpers.classPrivateFieldLooseKey("handleClose");
|
||||
class EntityCatalog extends main_core_events.EventEmitter {
|
||||
// backward compatability
|
||||
|
||||
constructor(props) {
|
||||
var _props$slots, _props$customComponen;
|
||||
var _props$recentGroupDat, _props$slots, _props$customComponen;
|
||||
super();
|
||||
Object.defineProperty(this, _handleClose, {
|
||||
value: _handleClose2
|
||||
@@ -950,6 +1039,9 @@ this.BX = this.BX || {};
|
||||
Object.defineProperty(this, _attachTemplate, {
|
||||
value: _attachTemplate2
|
||||
});
|
||||
Object.defineProperty(this, _resolveGroupsForTemplate, {
|
||||
value: _resolveGroupsForTemplate2
|
||||
});
|
||||
Object.defineProperty(this, _popup, {
|
||||
writable: true,
|
||||
value: void 0
|
||||
@@ -974,18 +1066,10 @@ this.BX = this.BX || {};
|
||||
writable: true,
|
||||
value: []
|
||||
});
|
||||
Object.defineProperty(this, _recentGroupData, {
|
||||
writable: true,
|
||||
value: void 0
|
||||
});
|
||||
Object.defineProperty(this, _showEmptyGroups, {
|
||||
writable: true,
|
||||
value: false
|
||||
});
|
||||
Object.defineProperty(this, _showRecentGroup, {
|
||||
writable: true,
|
||||
value: false
|
||||
});
|
||||
Object.defineProperty(this, _showSearch, {
|
||||
writable: true,
|
||||
value: false
|
||||
@@ -1009,10 +1093,25 @@ this.BX = this.BX || {};
|
||||
writable: true,
|
||||
value: void 0
|
||||
});
|
||||
Object.defineProperty(this, _recentGroupData, {
|
||||
writable: true,
|
||||
value: void 0
|
||||
});
|
||||
Object.defineProperty(this, _showRecentGroup, {
|
||||
writable: true,
|
||||
value: false
|
||||
});
|
||||
Object.defineProperty(this, _vueInstance, {
|
||||
writable: true,
|
||||
value: void 0
|
||||
});
|
||||
this.setEventNamespace('BX.UI.EntityCatalog');
|
||||
this.setGroups(main_core.Type.isArray(props.groups) ? props.groups : []);
|
||||
this.setItems(main_core.Type.isArray(props.items) ? props.items : []);
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData] = props.recentGroupData;
|
||||
|
||||
// backward compatibility
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData] = (_props$recentGroupDat = props.recentGroupData) != null ? _props$recentGroupDat : null;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _showRecentGroup)[_showRecentGroup] = main_core.Type.isBoolean(props.showRecentGroup) ? props.showRecentGroup : false;
|
||||
if (main_core.Type.isBoolean(props.canDeselectGroups)) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups].forEach(groupList => {
|
||||
groupList.forEach(group$$1 => {
|
||||
@@ -1021,7 +1120,6 @@ this.BX = this.BX || {};
|
||||
});
|
||||
}
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _showEmptyGroups)[_showEmptyGroups] = main_core.Type.isBoolean(props.showEmptyGroups) ? props.showEmptyGroups : false;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _showRecentGroup)[_showRecentGroup] = main_core.Type.isBoolean(props.showRecentGroup) ? props.showRecentGroup : false;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _showSearch)[_showSearch] = main_core.Type.isBoolean(props.showSearch) ? props.showSearch : false;
|
||||
if (main_core.Type.isPlainObject(props.filterOptions)) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _filterOptions)[_filterOptions] = props.filterOptions;
|
||||
@@ -1044,18 +1142,116 @@ this.BX = this.BX || {};
|
||||
...group$$1
|
||||
}));
|
||||
});
|
||||
if (!babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance] || !babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].localGroups) {
|
||||
return this;
|
||||
}
|
||||
if (this.isGroupsStructureChanged(babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups])) {
|
||||
try {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].refreshGroups(babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups]);
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].localGroups = babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups];
|
||||
}
|
||||
} else {
|
||||
const countersMap = {};
|
||||
for (const list of babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups]) {
|
||||
for (const g of list) {
|
||||
var _g$customData$counter, _g$customData;
|
||||
countersMap[String(g.id)] = (_g$customData$counter = (_g$customData = g.customData) == null ? void 0 : _g$customData.counterValue) != null ? _g$customData$counter : null;
|
||||
}
|
||||
}
|
||||
this._updateCountersInGroupLists(babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].localGroups, countersMap);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
isGroupsStructureChanged(newGroups) {
|
||||
if (!Array.isArray(babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups]) || !Array.isArray(newGroups)) {
|
||||
return true;
|
||||
}
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups].length !== newGroups.length) {
|
||||
return true;
|
||||
}
|
||||
for (let i = 0; i < newGroups.length; i++) {
|
||||
const oldList = babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups][i] || [];
|
||||
const newList = newGroups[i] || [];
|
||||
if (oldList.length !== newList.length) {
|
||||
return true;
|
||||
}
|
||||
for (let j = 0; j < newList.length; j++) {
|
||||
var _oldList$j, _newList$j;
|
||||
if (String((_oldList$j = oldList[j]) == null ? void 0 : _oldList$j.id) !== String((_newList$j = newList[j]) == null ? void 0 : _newList$j.id)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
_updateCountersInGroupLists(groupLists, countersMap = {}) {
|
||||
if (!Array.isArray(groupLists)) return;
|
||||
for (const list of groupLists) {
|
||||
for (const group$$1 of list) {
|
||||
const id = String(group$$1.id);
|
||||
if (Object.prototype.hasOwnProperty.call(countersMap, id)) {
|
||||
var _group$customData;
|
||||
const custom = (_group$customData = group$$1.customData) != null ? _group$customData : {};
|
||||
group$$1.customData = Object.assign({}, custom, {
|
||||
counterValue: countersMap[id]
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
updateGroupCounter(groupId, counterValue) {
|
||||
const idStr = String(groupId);
|
||||
const countersMap = {
|
||||
[idStr]: counterValue
|
||||
};
|
||||
this._updateCountersInGroupLists(babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups], countersMap);
|
||||
if (!babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance]) {
|
||||
return this;
|
||||
}
|
||||
try {
|
||||
this._updateCountersInGroupLists(babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].localGroups, countersMap);
|
||||
} catch (e) {
|
||||
if (typeof babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].refreshGroups === 'function') {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].refreshGroups(babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups]);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
getItems() {
|
||||
return babelHelpers.classPrivateFieldLooseBase(this, _items)[_items];
|
||||
}
|
||||
setItems(items) {
|
||||
items = items.map(item$$1 => ({
|
||||
button: {},
|
||||
...item$$1
|
||||
}));
|
||||
setItems(items = []) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _items)[_items].length = 0;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _items)[_items].push(...items);
|
||||
if (!babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance] || typeof babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].refreshItems !== 'function') {
|
||||
return this;
|
||||
}
|
||||
try {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].refreshItems(babelHelpers.classPrivateFieldLooseBase(this, _items)[_items]);
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
updateItemById(id, patch = {}) {
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance] && typeof babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].updateItemById === 'function') {
|
||||
try {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].updateItemById(id, patch);
|
||||
return this;
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
}
|
||||
}
|
||||
const itemForUpdate = babelHelpers.classPrivateFieldLooseBase(this, _items)[_items].find(item$$1 => String(item$$1.id) === String(id));
|
||||
if (itemForUpdate) {
|
||||
Object.assign(itemForUpdate, patch);
|
||||
} else {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _items)[_items].push(Object.assign({
|
||||
id
|
||||
}, patch));
|
||||
}
|
||||
return this;
|
||||
}
|
||||
show() {
|
||||
@@ -1072,20 +1268,80 @@ this.BX = this.BX || {};
|
||||
}
|
||||
return babelHelpers.classPrivateFieldLooseBase(this, _popup)[_popup];
|
||||
}
|
||||
selectGroup(groupId) {
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance] && babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].$refs.application) {
|
||||
const group$$1 = babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].localGroups.flat().find(g => String(g.id) === String(groupId));
|
||||
if (group$$1) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance].$refs.application.handleGroupSelected(group$$1);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
close() {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _application)[_application].unmount();
|
||||
this.getPopup().close();
|
||||
try {
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _application)[_application] && typeof babelHelpers.classPrivateFieldLooseBase(this, _application)[_application].unmount === 'function') {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _application)[_application].unmount();
|
||||
}
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _popup)[_popup]) {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _popup)[_popup].close();
|
||||
}
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
}
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _application)[_application] = null;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance] = null;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _popup)[_popup] = null;
|
||||
}
|
||||
}
|
||||
function _resolveGroupsForTemplate2() {
|
||||
var _babelHelpers$classPr, _babelHelpers$classPr2, _babelHelpers$classPr3, _babelHelpers$classPr4, _babelHelpers$classPr5, _babelHelpers$classPr6, _babelHelpers$classPr7, _babelHelpers$classPr8, _babelHelpers$classPr9;
|
||||
if (!babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData] || !babelHelpers.classPrivateFieldLooseBase(this, _showRecentGroup)[_showRecentGroup]) {
|
||||
return babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups];
|
||||
}
|
||||
|
||||
// clone groups shallowly to avoid mutating original arrays
|
||||
const groupsClone = babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups].map(list => list.slice());
|
||||
const recent = {
|
||||
isHeaderGroup: true,
|
||||
id: (_babelHelpers$classPr = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].id) != null ? _babelHelpers$classPr : 'recent',
|
||||
name: (_babelHelpers$classPr2 = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].name) != null ? _babelHelpers$classPr2 : '',
|
||||
icon: (_babelHelpers$classPr3 = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].icon) != null ? _babelHelpers$classPr3 : '',
|
||||
tags: (_babelHelpers$classPr4 = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].tags) != null ? _babelHelpers$classPr4 : [],
|
||||
adviceTitle: babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].adviceTitle,
|
||||
adviceAvatar: babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].adviceAvatar,
|
||||
selected: !!babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].selected,
|
||||
disabled: !!babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].disabled,
|
||||
deselectable: (_babelHelpers$classPr5 = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].deselectable) != null ? _babelHelpers$classPr5 : true,
|
||||
compare: babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].compare,
|
||||
customData: Object.assign({}, (_babelHelpers$classPr6 = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].customData) != null ? _babelHelpers$classPr6 : {}, {
|
||||
// prefer canonical name `counterValue`, fallback to legacy `newEntitiesCount`
|
||||
counterValue: (_babelHelpers$classPr7 = (_babelHelpers$classPr8 = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].customData) == null ? void 0 : _babelHelpers$classPr8.counterValue) != null ? _babelHelpers$classPr7 : (_babelHelpers$classPr9 = babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData].customData) == null ? void 0 : _babelHelpers$classPr9.newEntitiesCount
|
||||
})
|
||||
};
|
||||
if (groupsClone.length > 0 && Array.isArray(groupsClone[0]) && groupsClone[0].some(g => g.isHeaderGroup)) {
|
||||
groupsClone[0].unshift(recent);
|
||||
return groupsClone;
|
||||
}
|
||||
return [[recent], ...groupsClone];
|
||||
}
|
||||
function _attachTemplate2() {
|
||||
var _babelHelpers$classPr, _babelHelpers$classPr2, _babelHelpers$classPr3, _babelHelpers$classPr4, _babelHelpers$classPr5, _babelHelpers$classPr6, _babelHelpers$classPr7, _babelHelpers$classPr8, _babelHelpers$classPr9, _babelHelpers$classPr10, _babelHelpers$classPr11;
|
||||
var _babelHelpers$classPr10, _babelHelpers$classPr11, _babelHelpers$classPr12, _babelHelpers$classPr13, _babelHelpers$classPr14, _babelHelpers$classPr15, _babelHelpers$classPr16, _babelHelpers$classPr17, _babelHelpers$classPr18, _babelHelpers$classPr19, _babelHelpers$classPr20;
|
||||
const container = this.getPopup().getContentContainer();
|
||||
if (babelHelpers.classPrivateFieldLooseBase(this, _application)[_application] && typeof babelHelpers.classPrivateFieldLooseBase(this, _application)[_application].unmount === 'function') {
|
||||
try {
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _application)[_application].unmount();
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
}
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _application)[_application] = null;
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance] = null;
|
||||
}
|
||||
const context = this;
|
||||
const groupsToPass = babelHelpers.classPrivateFieldLooseBase(this, _resolveGroupsForTemplate)[_resolveGroupsForTemplate]();
|
||||
const rootProps = {
|
||||
recentGroupData: babelHelpers.classPrivateFieldLooseBase(this, _recentGroupData)[_recentGroupData],
|
||||
groups: babelHelpers.classPrivateFieldLooseBase(this, _groups)[_groups],
|
||||
groups: groupsToPass,
|
||||
items: babelHelpers.classPrivateFieldLooseBase(this, _items)[_items],
|
||||
showEmptyGroups: babelHelpers.classPrivateFieldLooseBase(this, _showEmptyGroups)[_showEmptyGroups],
|
||||
showRecentGroups: babelHelpers.classPrivateFieldLooseBase(this, _showRecentGroup)[_showRecentGroup],
|
||||
filterOptions: babelHelpers.classPrivateFieldLooseBase(this, _filterOptions)[_filterOptions]
|
||||
};
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _application)[_application] = ui_vue3.BitrixVue.createApp({
|
||||
@@ -1099,40 +1355,89 @@ this.BX = this.BX || {};
|
||||
feedback
|
||||
},
|
||||
props: {
|
||||
recentGroupData: Object,
|
||||
groups: Array,
|
||||
items: Array,
|
||||
showEmptyGroups: Boolean,
|
||||
showRecentGroups: Boolean,
|
||||
filterOptions: Object
|
||||
},
|
||||
created() {
|
||||
this.$app = context;
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
localGroups: this.groups,
|
||||
localItems: this.items
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
onItemsRendered() {
|
||||
this.$app.emit('onItemsRendered');
|
||||
},
|
||||
refreshGroups(groups) {
|
||||
this.localGroups = groups;
|
||||
},
|
||||
refreshItems(newItems = []) {
|
||||
try {
|
||||
const existingMap = new Map(this.localItems.map(it => [String(it.id), it]));
|
||||
newItems.forEach(newIt => {
|
||||
const id = String(newIt.id);
|
||||
if (existingMap.has(id)) {
|
||||
Object.assign(existingMap.get(id), newIt);
|
||||
} else {
|
||||
this.localItems.push(newIt);
|
||||
existingMap.set(id, this.localItems[this.localItems.length - 1]);
|
||||
}
|
||||
});
|
||||
const newIds = new Set(newItems.map(it => String(it.id)));
|
||||
for (let i = this.localItems.length - 1; i >= 0; i--) {
|
||||
if (!newIds.has(String(this.localItems[i].id))) {
|
||||
this.localItems.splice(i, 1);
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
this.localItems.splice(0, this.localItems.length, ...newItems);
|
||||
}
|
||||
},
|
||||
updateItemById(id, patch = {}) {
|
||||
try {
|
||||
const it = this.localItems.find(x => String(x.id) === String(id));
|
||||
if (it) {
|
||||
Object.assign(it, patch);
|
||||
} else {
|
||||
this.localItems.push(Object.assign({
|
||||
id
|
||||
}, patch));
|
||||
}
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
}
|
||||
}
|
||||
},
|
||||
template: `
|
||||
<Application
|
||||
:recent-group-data="recentGroupData"
|
||||
:groups="groups"
|
||||
:items="items"
|
||||
ref="application"
|
||||
@itemsRendered="onItemsRendered"
|
||||
:groups="localGroups"
|
||||
:items="localItems"
|
||||
:show-empty-groups="showEmptyGroups"
|
||||
:show-recent-group="showRecentGroups"
|
||||
:filter-options="filterOptions"
|
||||
>
|
||||
<template #group-list-header>
|
||||
${(_babelHelpers$classPr = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_GROUP_LIST_HEADER]) != null ? _babelHelpers$classPr : ''}
|
||||
${(_babelHelpers$classPr10 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_GROUP_LIST_HEADER]) != null ? _babelHelpers$classPr10 : ''}
|
||||
</template>
|
||||
<template #group="groupSlotProps">
|
||||
${(_babelHelpers$classPr2 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_GROUP]) != null ? _babelHelpers$classPr2 : ''}
|
||||
${(_babelHelpers$classPr11 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_GROUP]) != null ? _babelHelpers$classPr11 : ''}
|
||||
</template>
|
||||
<template #group-list-footer>
|
||||
${(_babelHelpers$classPr3 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_GROUP_LIST_FOOTER]) != null ? _babelHelpers$classPr3 : ''}
|
||||
${(_babelHelpers$classPr12 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_GROUP_LIST_FOOTER]) != null ? _babelHelpers$classPr12 : ''}
|
||||
</template>
|
||||
|
||||
<template #main-content-header>
|
||||
${(_babelHelpers$classPr4 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_HEADER]) != null ? _babelHelpers$classPr4 : ''}
|
||||
${(_babelHelpers$classPr13 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_HEADER]) != null ? _babelHelpers$classPr13 : ''}
|
||||
</template>
|
||||
<template #main-content-footer>
|
||||
${(_babelHelpers$classPr5 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_FOOTER]) != null ? _babelHelpers$classPr5 : ''}
|
||||
${(_babelHelpers$classPr14 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_FOOTER]) != null ? _babelHelpers$classPr14 : ''}
|
||||
</template>
|
||||
<template #main-content-filter-stub v-if="${!!babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_FILTERS_STUB]}">
|
||||
${babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_FILTERS_STUB]}
|
||||
@@ -1141,30 +1446,30 @@ this.BX = this.BX || {};
|
||||
${babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_FILTERS_STUB_TITLE]}
|
||||
</template>
|
||||
<template #main-content-search-not-found-stub>
|
||||
${(_babelHelpers$classPr6 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_SEARCH_NOT_FOUND]) != null ? _babelHelpers$classPr6 : main_core.Loc.getMessage('UI_JS_ENTITY_CATALOG_GROUP_LIST_ITEM_LIST_SEARCH_STUB_DEFAULT_TITLE')}
|
||||
${(_babelHelpers$classPr15 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_SEARCH_NOT_FOUND]) != null ? _babelHelpers$classPr15 : main_core.Loc.getMessage('UI_JS_ENTITY_CATALOG_GROUP_LIST_ITEM_LIST_SEARCH_STUB_DEFAULT_TITLE')}
|
||||
</template>
|
||||
<template v-if="${Boolean(babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_SEARCH_STUB])}" #main-content-search-stub>
|
||||
${babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_SEARCH_STUB]}
|
||||
</template>
|
||||
<template #main-content-welcome-stub>
|
||||
${(_babelHelpers$classPr7 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_WELCOME_STUB]) != null ? _babelHelpers$classPr7 : ''}
|
||||
${(_babelHelpers$classPr16 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_WELCOME_STUB]) != null ? _babelHelpers$classPr16 : ''}
|
||||
</template>
|
||||
<template #main-content-no-selected-group-stub>
|
||||
${(_babelHelpers$classPr8 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_NO_SELECTED_GROUP_STUB]) != null ? _babelHelpers$classPr8 : ''}
|
||||
${(_babelHelpers$classPr17 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_NO_SELECTED_GROUP_STUB]) != null ? _babelHelpers$classPr17 : ''}
|
||||
</template>
|
||||
<template #main-content-empty-group-stub>
|
||||
${(_babelHelpers$classPr9 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_EMPTY_GROUP_STUB]) != null ? _babelHelpers$classPr9 : ''}
|
||||
${(_babelHelpers$classPr18 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_EMPTY_GROUP_STUB]) != null ? _babelHelpers$classPr18 : ''}
|
||||
</template>
|
||||
<template #main-content-empty-group-stub-title>
|
||||
${(_babelHelpers$classPr10 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_EMPTY_GROUP_STUB_TITLE]) != null ? _babelHelpers$classPr10 : ''}
|
||||
${(_babelHelpers$classPr19 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_EMPTY_GROUP_STUB_TITLE]) != null ? _babelHelpers$classPr19 : ''}
|
||||
</template>
|
||||
<template #item="itemSlotProps">
|
||||
${(_babelHelpers$classPr11 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_ITEM]) != null ? _babelHelpers$classPr11 : ''}
|
||||
${(_babelHelpers$classPr20 = babelHelpers.classPrivateFieldLooseBase(this, _slots)[_slots][EntityCatalog.SLOT_MAIN_CONTENT_ITEM]) != null ? _babelHelpers$classPr20 : ''}
|
||||
</template>
|
||||
</Application>
|
||||
`
|
||||
}, rootProps);
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _application)[_application].use(ui_vue3_pinia.createPinia()).mount(this.getPopup().getContentContainer());
|
||||
babelHelpers.classPrivateFieldLooseBase(this, _vueInstance)[_vueInstance] = babelHelpers.classPrivateFieldLooseBase(this, _application)[_application].use(ui_vue3_pinia.createPinia()).mount(container);
|
||||
}
|
||||
function _getDefaultPopupOptions2() {
|
||||
return {
|
||||
@@ -1223,5 +1528,5 @@ this.BX = this.BX || {};
|
||||
exports.States = States;
|
||||
exports.EntityCatalog = EntityCatalog;
|
||||
|
||||
}((this.BX.UI = this.BX.UI || {}),BX.Vue3,BX.Vue3.Components,BX.UI.Feedback,BX,BX.UI,BX,BX,BX.Vue3.Pinia,BX,BX.Main,BX.Event,BX,BX));
|
||||
}((this.BX.UI = this.BX.UI || {}),BX.Vue3,BX.Vue3.Components,BX.UI.Feedback,BX,BX.UI,BX.UI.Vue3.Components,BX.UI,BX,BX,BX.Vue3.Pinia,BX,BX.Main,BX.Event,BX,BX));
|
||||
//# sourceMappingURL=entity-catalog.bundle.js.map
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -24,14 +24,12 @@ export const Application = {
|
||||
Search,
|
||||
},
|
||||
props: {
|
||||
recentGroupData: {
|
||||
type: GroupData,
|
||||
required: false,
|
||||
},
|
||||
/** @type Array<Array<GroupData>> */
|
||||
groups: {
|
||||
type: Array,
|
||||
required: true,
|
||||
},
|
||||
/** @type Array<ItemData> */
|
||||
items: {
|
||||
type: Array,
|
||||
required: true,
|
||||
@@ -40,10 +38,6 @@ export const Application = {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
showRecentGroup: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
filterOptions: {
|
||||
type: Object,
|
||||
default: {
|
||||
@@ -52,9 +46,17 @@ export const Application = {
|
||||
},
|
||||
},
|
||||
},
|
||||
data(): Object
|
||||
data(): {
|
||||
selectedGroup: ?GroupData,
|
||||
selectedGroupId: ?string,
|
||||
shownItems: Array,
|
||||
shownGroups: Array<Array<GroupData>>,
|
||||
lastSearchString: string,
|
||||
filters: Array,
|
||||
}
|
||||
{
|
||||
let selectedGroup = null;
|
||||
|
||||
for (const groupList of this.groups)
|
||||
{
|
||||
selectedGroup = groupList.find(group => group.selected);
|
||||
@@ -63,16 +65,12 @@ export const Application = {
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (Type.isNil(selectedGroup) && this.recentGroupData?.selected)
|
||||
{
|
||||
selectedGroup = {id: 'recent', ...(this.recentGroupData ?? {})};
|
||||
}
|
||||
|
||||
return {
|
||||
selectedGroup,
|
||||
selectedGroupId: selectedGroup?.id ?? null,
|
||||
shownItems: [],
|
||||
shownGroups: this.getDisplayedGroup(),
|
||||
shownGroups: [],
|
||||
lastSearchString: '',
|
||||
filters: [],
|
||||
};
|
||||
@@ -84,6 +82,51 @@ export const Application = {
|
||||
|
||||
return this.selectedGroup?.compare ? items.sort(this.selectedGroup.compare) : items;
|
||||
},
|
||||
computedShownGroups(): Array<Array<GroupData>>
|
||||
{
|
||||
if (this.showEmptyGroups)
|
||||
{
|
||||
return Runtime.clone(this.groups);
|
||||
}
|
||||
|
||||
const groupIdsWithItems = new Set();
|
||||
this.items.forEach((item) => {
|
||||
item.groupIds.forEach((groupId) => groupIdsWithItems.add(groupId));
|
||||
});
|
||||
|
||||
return (
|
||||
this.groups
|
||||
.map(groupList => groupList.filter(group => group.isHeaderGroup === true || groupIdsWithItems.has(group.id)))
|
||||
.filter(list => list.length > 0)
|
||||
);
|
||||
},
|
||||
|
||||
computedShownItems(): Array<ItemData>
|
||||
{
|
||||
if (this.searching && Type.isStringFilled(this.lastSearchString))
|
||||
{
|
||||
const q = this.lastSearchString;
|
||||
let result = this.items.filter((item) => (
|
||||
String(item.title).toLowerCase().includes(q)
|
||||
|| String(item.description).toLowerCase().includes(q)
|
||||
|| item.tags?.some(tag => tag === q)
|
||||
));
|
||||
|
||||
for (const filterId in this.filters)
|
||||
{
|
||||
result = result.filter(this.filters[filterId].action);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
let result = this.itemsBySelectedGroupId.slice();
|
||||
for (const filterId in this.filters)
|
||||
{
|
||||
result = result.filter(this.filters[filterId].action);
|
||||
}
|
||||
return result;
|
||||
},
|
||||
...mapWritableState(useGlobalState, {
|
||||
searchQuery: 'searchQuery',
|
||||
searching: 'searchApplied',
|
||||
@@ -93,25 +136,38 @@ export const Application = {
|
||||
}),
|
||||
},
|
||||
watch: {
|
||||
computedShownItems: {
|
||||
handler()
|
||||
{
|
||||
this.$nextTick(() => {
|
||||
this.$emit('itemsRendered');
|
||||
});
|
||||
},
|
||||
flush: 'post',
|
||||
},
|
||||
computedShownGroups: {
|
||||
immediate: true,
|
||||
handler(newVal)
|
||||
{
|
||||
// quick replace in-place to keep same array object reference
|
||||
this.shownGroups.splice(0, this.shownGroups.length, ...newVal);
|
||||
|
||||
if (!this.selectedGroupId)
|
||||
{
|
||||
const selected = this.shownGroups.flat().find(g => g.selected);
|
||||
if (selected)
|
||||
{
|
||||
this.selectedGroup = selected;
|
||||
this.selectedGroupId = selected.id;
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
selectedGroup()
|
||||
{
|
||||
this.shouldShowWelcomeStub = false;
|
||||
this.globalGroup = this.selectedGroup;
|
||||
},
|
||||
selectedGroupId()
|
||||
{
|
||||
if (this.searching)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
this.shownItems = this.itemsBySelectedGroupId;
|
||||
this.applyFilters();
|
||||
},
|
||||
},
|
||||
created()
|
||||
{
|
||||
this.shownItems = this.itemsBySelectedGroupId;
|
||||
},
|
||||
methods: {
|
||||
getDisplayedGroup(): Array<Array<GroupData>>
|
||||
@@ -124,15 +180,16 @@ export const Application = {
|
||||
const groupIdsWithItems = new Set();
|
||||
this.items.forEach((item: ItemData) => {
|
||||
item.groupIds.forEach((groupId: String | Number) => {
|
||||
groupIdsWithItems.add(groupId)
|
||||
groupIdsWithItems.add(groupId);
|
||||
});
|
||||
});
|
||||
|
||||
return (
|
||||
this
|
||||
.groups
|
||||
.map((groupList: Array<GroupData>) => groupList.filter((group: GroupData) => groupIdsWithItems.has(group.id)
|
||||
))
|
||||
.map((groupList: Array<GroupData>) => groupList.filter((group: GroupData) => (
|
||||
(group.isHeaderGroup === true) || groupIdsWithItems.has(group.id)
|
||||
)))
|
||||
.filter(groupList => groupList.length > 0)
|
||||
);
|
||||
},
|
||||
@@ -175,7 +232,7 @@ export const Application = {
|
||||
this.filters = event.getData();
|
||||
if (this.searching)
|
||||
{
|
||||
this.onSearch(new BaseEvent({data: {queryString: this.lastSearchString}}));
|
||||
this.onSearch(new BaseEvent({ data: { queryString: this.lastSearchString } }));
|
||||
|
||||
return;
|
||||
}
|
||||
@@ -194,17 +251,17 @@ export const Application = {
|
||||
getFilterNode(): ?Element
|
||||
{
|
||||
return (this.$root.$app
|
||||
.getPopup()
|
||||
.getTitleContainer()
|
||||
.querySelector('[data-role="titlebar-filter"]')
|
||||
.getPopup()
|
||||
.getTitleContainer()
|
||||
.querySelector('[data-role="titlebar-filter"]')
|
||||
);
|
||||
},
|
||||
getSearchNode(): ?Element
|
||||
{
|
||||
return (this.$root.$app
|
||||
.getPopup()
|
||||
.getTitleContainer()
|
||||
.querySelector('[data-role="titlebar-search"]')
|
||||
.getPopup()
|
||||
.getTitleContainer()
|
||||
.querySelector('[data-role="titlebar-search"]')
|
||||
);
|
||||
},
|
||||
stopPropagation(event)
|
||||
@@ -215,11 +272,10 @@ export const Application = {
|
||||
template: `
|
||||
<div class="ui-entity-catalog__main">
|
||||
<MainGroups
|
||||
:recent-group-data="this.recentGroupData"
|
||||
:groups="this.shownGroups"
|
||||
:show-recent-group="showRecentGroup"
|
||||
:searching="searching"
|
||||
@group-selected="handleGroupSelected"
|
||||
:selected-group="selectedGroup"
|
||||
>
|
||||
<template #group-list-header>
|
||||
<slot name="group-list-header"/>
|
||||
@@ -237,7 +293,7 @@ export const Application = {
|
||||
</MainGroups>
|
||||
<MainContent
|
||||
:items="itemsBySelectedGroupId"
|
||||
:items-to-show="shownItems"
|
||||
:items-to-show="computedShownItems"
|
||||
:group="selectedGroup"
|
||||
:searching="searching"
|
||||
>
|
||||
@@ -288,4 +344,4 @@ export const Application = {
|
||||
</Teleport>
|
||||
</div>
|
||||
`,
|
||||
}
|
||||
};
|
||||
@@ -11,11 +11,42 @@ export const GroupList = {
|
||||
Group,
|
||||
},
|
||||
props: {
|
||||
/** @type Array<Array<GroupData>> */
|
||||
groups: {
|
||||
type: Array,
|
||||
required: true,
|
||||
},
|
||||
},
|
||||
computed: {
|
||||
groupLists(): Array<Array<GroupData>>
|
||||
{
|
||||
if (!this.groups || this.groups.length === 0)
|
||||
{
|
||||
return [];
|
||||
}
|
||||
|
||||
if (Array.isArray(this.groups[0]))
|
||||
{
|
||||
return this.groups;
|
||||
}
|
||||
|
||||
return [this.groups];
|
||||
},
|
||||
|
||||
headerLists(): Array<Array<GroupData>>
|
||||
{
|
||||
return this.groupLists
|
||||
.map(list => list.filter(g => !!g.isHeaderGroup))
|
||||
.filter(list => list.length > 0);
|
||||
},
|
||||
|
||||
mainLists(): Array<Array<GroupData>>
|
||||
{
|
||||
return this.groupLists
|
||||
.map(list => list.filter(g => !g.isHeaderGroup))
|
||||
.filter(list => list.length > 0);
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
handleGroupSelected(group: GroupData)
|
||||
{
|
||||
@@ -24,25 +55,60 @@ export const GroupList = {
|
||||
handleGroupUnselected(group: GroupData)
|
||||
{
|
||||
this.$emit('groupUnselected', group);
|
||||
}
|
||||
},
|
||||
},
|
||||
template: `
|
||||
<ul class="ui-entity-catalog__menu">
|
||||
<Group
|
||||
:group-data="group"
|
||||
:key="group.id"
|
||||
v-for="group in groups"
|
||||
@selected="handleGroupSelected"
|
||||
@unselected="handleGroupUnselected"
|
||||
<div>
|
||||
<div
|
||||
class="ui-entity-catalog__header-groups-content"
|
||||
v-if="headerLists && headerLists.length"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
<slot
|
||||
name="group"
|
||||
v-bind:groupData="groupSlotProps.groupData"
|
||||
v-bind:handleClick="groupSlotProps.handleClick"
|
||||
/>
|
||||
</template>
|
||||
</Group>
|
||||
</ul>
|
||||
<ul
|
||||
class="ui-entity-catalog__menu"
|
||||
v-for="(groupList, listIndex) in headerLists"
|
||||
:key="'header-'+listIndex"
|
||||
>
|
||||
<Group
|
||||
:group-data="group"
|
||||
:key="group.id"
|
||||
v-for="group in groupList"
|
||||
@selected="handleGroupSelected"
|
||||
@unselected="handleGroupUnselected"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
<slot
|
||||
name="group"
|
||||
v-bind:groupData="groupSlotProps.groupData"
|
||||
v-bind:handleClick="groupSlotProps.handleClick"
|
||||
/>
|
||||
</template>
|
||||
</Group>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<ul
|
||||
class="ui-entity-catalog__menu"
|
||||
v-for="(groupList, listIndex) in mainLists"
|
||||
:key="'main-'+listIndex"
|
||||
>
|
||||
<Group
|
||||
:group-data="group"
|
||||
:key="group.id"
|
||||
v-for="group in groupList"
|
||||
@selected="handleGroupSelected"
|
||||
@unselected="handleGroupUnselected"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
<slot
|
||||
name="group"
|
||||
v-bind:groupData="groupSlotProps.groupData"
|
||||
v-bind:handleClick="groupSlotProps.handleClick"
|
||||
/>
|
||||
</template>
|
||||
</Group>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
`,
|
||||
}
|
||||
};
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import { Type } from 'main.core';
|
||||
import { GroupData } from '@/types/group';
|
||||
import { CounterStyle } from 'ui.cnt';
|
||||
import { Counter } from 'ui.vue3.components.counter';
|
||||
|
||||
import '../css/group.css';
|
||||
|
||||
@@ -7,7 +9,11 @@ export const Group = {
|
||||
emits: ['selected', 'unselected'],
|
||||
|
||||
name: 'ui-entity-catalog-group',
|
||||
components: {
|
||||
Counter,
|
||||
},
|
||||
props: {
|
||||
/** @type GroupData */
|
||||
groupData: {
|
||||
type: GroupData,
|
||||
required: true,
|
||||
@@ -18,6 +24,18 @@ export const Group = {
|
||||
{
|
||||
return Type.isStringFilled(this.groupData.icon);
|
||||
},
|
||||
getCounterStyle(): string
|
||||
{
|
||||
return CounterStyle.FILLED_SUCCESS;
|
||||
},
|
||||
getCounterValue(): ?number
|
||||
{
|
||||
const custom = this.groupData?.customData ?? {};
|
||||
const value = custom.counterValue;
|
||||
const isValueInteger = Number.isInteger(value);
|
||||
|
||||
return isValueInteger && value > 0 ? value : null;
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
handleClick()
|
||||
@@ -34,16 +52,26 @@ export const Group = {
|
||||
},
|
||||
template: `
|
||||
<slot name="group" v-bind:groupData="groupData" v-bind:handleClick="handleClick">
|
||||
<li
|
||||
<li
|
||||
:class="{
|
||||
'ui-entity-catalog__menu_item': true,
|
||||
'--active': groupData.selected,
|
||||
'--disabled': groupData.disabled
|
||||
'--disabled': groupData.disabled,
|
||||
}"
|
||||
@click="handleClick"
|
||||
>
|
||||
<span class="ui-entity-catalog__menu_item-icon" v-if="hasIcon" v-html="groupData.icon"/>
|
||||
<span class="ui-entity-catalog__menu_item-text">{{ groupData.name }}</span>
|
||||
<span
|
||||
v-if="getCounterValue !== null"
|
||||
class="ui-entity-catalog__menu_item-entity-count"
|
||||
>
|
||||
<Counter
|
||||
:value="getCounterValue"
|
||||
:style="getCounterStyle"
|
||||
>
|
||||
</Counter>
|
||||
</span>
|
||||
</li>
|
||||
</slot>
|
||||
`,
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import { Item } from './item';
|
||||
import type { ItemData } from '@/type/item';
|
||||
|
||||
import '../css/item-list.css';
|
||||
|
||||
@@ -9,6 +10,7 @@ export const ItemList = {
|
||||
},
|
||||
props: {
|
||||
items: {
|
||||
/** @type Array<ItemData> */
|
||||
Type: Array,
|
||||
required: true,
|
||||
}
|
||||
|
||||
@@ -25,12 +25,31 @@ export const Item = {
|
||||
}
|
||||
|
||||
return this.itemData.button;
|
||||
},
|
||||
topText(): ?string
|
||||
{
|
||||
const custom = this.itemData?.customData ?? {};
|
||||
if (Type.isStringFilled(custom.topText))
|
||||
{
|
||||
return custom.topText;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
},
|
||||
template: `
|
||||
<slot name="item" v-bind:itemData="itemData">
|
||||
<div class="ui-entity-catalog__option">
|
||||
<div
|
||||
class="ui-entity-catalog__option"
|
||||
:data-item-id="String(itemData.id)"
|
||||
>
|
||||
<div class="ui-entity-catalog__option-info">
|
||||
<div
|
||||
v-if="topText"
|
||||
class="ui-entity-catalog__option-info_top_text"
|
||||
>
|
||||
{{ topText }}
|
||||
</div>
|
||||
<div class="ui-entity-catalog__option-info_name">
|
||||
<span>{{itemData.title}}</span>
|
||||
<span class="ui-entity-catalog__option-info_label" v-if="itemData.subtitle">{{itemData.subtitle}}</span>
|
||||
|
||||
@@ -18,10 +18,12 @@ export const MainContent = {
|
||||
},
|
||||
props: {
|
||||
items: {
|
||||
/** @type Array<ItemData> */
|
||||
type: Array,
|
||||
required: true
|
||||
},
|
||||
itemsToShow: {
|
||||
/** @type Array<ItemData> */
|
||||
type: Array,
|
||||
},
|
||||
group: {
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { Loc } from 'main.core';
|
||||
import { GroupList } from './group-list';
|
||||
|
||||
import { GroupData } from '@/type/group';
|
||||
@@ -13,95 +12,57 @@ export const MainGroups = {
|
||||
GroupList,
|
||||
},
|
||||
props: {
|
||||
recentGroupData: {
|
||||
type: GroupData,
|
||||
required: false,
|
||||
},
|
||||
groups: {
|
||||
/** @type Array<Array<GroupData>> */
|
||||
type: Array,
|
||||
required: true,
|
||||
},
|
||||
showRecentGroup: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
searching: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
}
|
||||
},
|
||||
data(): Object
|
||||
{
|
||||
const recentGroup = this.getRecentGroup();
|
||||
recentGroup[0] = Object.assign(recentGroup[0], this.recentGroupData ?? {});
|
||||
|
||||
let selectedGroup = this.groups.find(group => group.selected) ?? null;
|
||||
if (!selectedGroup)
|
||||
{
|
||||
selectedGroup = recentGroup.find(group => group.selected) ?? null;
|
||||
}
|
||||
|
||||
return {
|
||||
shownGroups: this.groups,
|
||||
selectedGroup: null,
|
||||
recentGroup,
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
selectedGroup(newGroup: ?GroupData)
|
||||
{
|
||||
const newGroupId = newGroup ? newGroup.id : null;
|
||||
|
||||
this.shownGroups = this.shownGroups.map(groupList => groupList.map((group) => ({
|
||||
...group,
|
||||
selected: group.id === newGroupId,
|
||||
})));
|
||||
|
||||
if (this.showRecentGroup && newGroupId !== this.recentGroup[0].id)
|
||||
{
|
||||
this.recentGroup = [Object.assign(this.recentGroup[0], {selected: false})];
|
||||
}
|
||||
|
||||
this.$emit('groupSelected', newGroup);
|
||||
},
|
||||
selectedGroup: {
|
||||
/** @type GroupData */
|
||||
type: Object,
|
||||
default: null,
|
||||
},
|
||||
},
|
||||
beforeUpdate()
|
||||
{
|
||||
if (this.searching)
|
||||
computed: {
|
||||
processedGroups()
|
||||
{
|
||||
this.shownGroups = this.shownGroups.map(groupList => groupList.map((group) => ({
|
||||
...group,
|
||||
selected: false,
|
||||
})));
|
||||
const selectedGroupId = this.searching ? null : (this.selectedGroup ? this.selectedGroup.id : null);
|
||||
|
||||
this.recentGroup = [Object.assign(this.recentGroup[0], {selected: false})];
|
||||
}
|
||||
},
|
||||
methods:{
|
||||
getRecentGroup(): Array<GroupData>
|
||||
{
|
||||
return [{
|
||||
id: 'recent',
|
||||
name: Loc.getMessage('UI_JS_ENTITY_CATALOG_GROUP_LIST_RECENT_GROUP_DEFAULT_NAME'),
|
||||
icon: `
|
||||
<svg width="18" height="14" viewBox="0 0 18 14" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path class="ui-entity-catalog__svg-icon-blue" fill-rule="evenodd" clip-rule="evenodd" d="M9.369 13.2593C13.0305 13.2593 15.9986 10.2911 15.9986 6.62965C15.9986 2.9682 13.0305 0 9.369 0C6.00693 0 3.22939 2.50263 2.79764 5.74663H0L3.69844 9.44506L7.39687 5.74663H4.48558C4.90213 3.4276 6.93006 1.66789 9.369 1.66789C12.1093 1.66789 14.3308 3.88935 14.3308 6.62965C14.3308 9.36995 12.1093 11.5914 9.369 11.5914C9.2435 11.5914 9.11909 11.5867 8.99593 11.5776V13.249C9.11941 13.2558 9.2438 13.2593 9.369 13.2593ZM10.0865 4.01429H8.41983V8.18096H9.65978H10.0865H12.1195V6.56367H10.0865V4.01429Z"></path>
|
||||
</svg>
|
||||
`,
|
||||
}];
|
||||
const groupsClone = BX.Runtime.clone(this.groups);
|
||||
|
||||
groupsClone.forEach(groupList => {
|
||||
groupList.forEach(group => {
|
||||
group.selected = (group.id === selectedGroupId);
|
||||
});
|
||||
});
|
||||
|
||||
return groupsClone;
|
||||
},
|
||||
headerLists(): Array<Array<GroupData>>
|
||||
{
|
||||
return this.processedGroups
|
||||
.map(list => list.filter(g => g.isHeaderGroup))
|
||||
.filter(list => list.length > 0);
|
||||
},
|
||||
mainLists(): Array<Array<GroupData>>
|
||||
{
|
||||
return this.processedGroups
|
||||
.map(list => list.filter(g => !g.isHeaderGroup))
|
||||
.filter(list => list.length > 0);
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
handleGroupSelected(group: GroupData)
|
||||
{
|
||||
this.selectedGroup = group;
|
||||
},
|
||||
handleRecentGroupSelected(group: GroupData)
|
||||
{
|
||||
group.selected = true;
|
||||
this.selectedGroup = group;
|
||||
this.$emit('groupSelected', group);
|
||||
},
|
||||
handleGroupUnselected()
|
||||
{
|
||||
this.selectedGroup = null;
|
||||
this.$emit('groupSelected', null);
|
||||
},
|
||||
},
|
||||
template: `
|
||||
@@ -109,10 +70,13 @@ export const MainGroups = {
|
||||
<div class="ui-entity-catalog__main-groups-head">
|
||||
<slot name="group-list-header"/>
|
||||
</div>
|
||||
<div class="ui-entity-catalog__recently" v-if="showRecentGroup">
|
||||
<div
|
||||
class="ui-entity-catalog__header-groups-content"
|
||||
v-if="headerLists && headerLists.length"
|
||||
>
|
||||
<GroupList
|
||||
:groups="recentGroup"
|
||||
@groupSelected="handleRecentGroupSelected"
|
||||
:groups="headerLists"
|
||||
@groupSelected="handleGroupSelected"
|
||||
@groupUnselected="handleGroupUnselected"
|
||||
>
|
||||
<template #group="groupSlotProps">
|
||||
@@ -126,8 +90,7 @@ export const MainGroups = {
|
||||
</div>
|
||||
<div class="ui-entity-catalog__main-groups-content">
|
||||
<GroupList
|
||||
:groups="groupList"
|
||||
v-for="groupList in shownGroups"
|
||||
:groups="mainLists"
|
||||
@groupSelected="handleGroupSelected"
|
||||
@groupUnselected="handleGroupUnselected"
|
||||
>
|
||||
@@ -145,4 +108,4 @@ export const MainGroups = {
|
||||
</div>
|
||||
</div>
|
||||
`,
|
||||
};
|
||||
};
|
||||
|
||||
@@ -90,4 +90,9 @@
|
||||
|
||||
.ui-entity-catalog__menu_item.--disabled .ui-entity-catalog__svg-icon-blue {
|
||||
fill: var(--ui-color-base-40, #bdc1c6);
|
||||
}
|
||||
|
||||
.ui-entity-catalog__menu_item-entity-count {
|
||||
position: absolute;
|
||||
right: calc(5px + 16px + 4px);
|
||||
}
|
||||
@@ -27,4 +27,13 @@
|
||||
font-size: var(--ui-font-size-md, 14px);
|
||||
line-height: var(--ui-font-line-height-xl, 1.62);
|
||||
opacity: 0.4;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__option-info_top_text {
|
||||
font-weight: var(--ui-font-weight-semi-bold, 500);
|
||||
font-size: var(--ui-font-size-5xs, 9px);
|
||||
line-height: 100%;
|
||||
letter-spacing: 0;
|
||||
color: var(--ui-color-palette-blue-50);
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
@@ -14,12 +14,6 @@
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__recently {
|
||||
padding-right: 12px;
|
||||
box-sizing: border-box;
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__main-groups-content {
|
||||
max-height: 100%;
|
||||
width: 100%;
|
||||
@@ -52,3 +46,21 @@
|
||||
padding-right: 12px;
|
||||
margin-top: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content li {
|
||||
box-sizing: border-box;
|
||||
border-radius: 8px;
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content ul {
|
||||
padding-right: 12px;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content .ui-entity-catalog__menu_item:not(.ui-entity-catalog__menu_item:first-child)::before {
|
||||
content: none;
|
||||
}
|
||||
|
||||
.ui-entity-catalog__header-groups-content .ui-entity-catalog__menu {
|
||||
overflow: hidden;
|
||||
}
|
||||
@@ -3,8 +3,8 @@ import { BaseEvent, EventEmitter } from 'main.core.events';
|
||||
import { Popup, PopupOptions } from 'main.popup';
|
||||
import { BitrixVue } from 'ui.vue3';
|
||||
import { createPinia } from 'ui.vue3.pinia';
|
||||
import { Hint } from "ui.vue3.components.hint";
|
||||
import { feedback} from "./directives/feedback";
|
||||
import { Hint } from 'ui.vue3.components.hint';
|
||||
import { feedback } from './directives/feedback';
|
||||
|
||||
import { Application } from './components/application';
|
||||
import { Button } from './components/button';
|
||||
@@ -15,7 +15,7 @@ import './css/popup.css';
|
||||
|
||||
import type { GroupData } from './types/group';
|
||||
import type { ItemData } from './types/item';
|
||||
import type { FilterData} from './types/filter';
|
||||
import type { FilterData } from './types/filter';
|
||||
|
||||
export type {
|
||||
GroupData,
|
||||
@@ -29,11 +29,11 @@ import { useGlobalState } from './stores/global-state';
|
||||
|
||||
export const Stubs = {
|
||||
EmptyContent,
|
||||
}
|
||||
};
|
||||
|
||||
export const States = {
|
||||
useGlobalState,
|
||||
}
|
||||
};
|
||||
|
||||
export class EntityCatalog extends EventEmitter
|
||||
{
|
||||
@@ -63,9 +63,7 @@ export class EntityCatalog extends EventEmitter
|
||||
|
||||
#groups: Array<Array<GroupData>> = [];
|
||||
#items: Array<Item> = [];
|
||||
#recentGroupData: ?GroupData;
|
||||
#showEmptyGroups: boolean = false;
|
||||
#showRecentGroup: boolean = false;
|
||||
#showSearch: boolean = false;
|
||||
#filterOptions: {
|
||||
filterItems: Array<FilterData>,
|
||||
@@ -78,13 +76,16 @@ export class EntityCatalog extends EventEmitter
|
||||
#slots: object;
|
||||
#customComponents: object;
|
||||
|
||||
// backward compatability
|
||||
#recentGroupData: ?GroupData;
|
||||
#showRecentGroup: boolean = false;
|
||||
#vueInstance: any;
|
||||
|
||||
constructor(props: {
|
||||
groups?: Array<Array<GroupData>>,
|
||||
items?: Array<ItemData>,
|
||||
recentGroupData?: GroupData,
|
||||
canDeselectGroups?: boolean,
|
||||
showEmptyGroups?: boolean,
|
||||
showRecentGroup?: boolean,
|
||||
showSearch?: boolean,
|
||||
filterOptions?: {
|
||||
filterItems: Array<FilterData>,
|
||||
@@ -96,6 +97,10 @@ export class EntityCatalog extends EventEmitter
|
||||
slots?: object,
|
||||
events?: { [eventName: string]: (event: BaseEvent) => void },
|
||||
customComponents?: object,
|
||||
|
||||
// backward compatability
|
||||
recentGroupData: ?GroupData,
|
||||
showRecentGroup: boolean,
|
||||
})
|
||||
{
|
||||
super();
|
||||
@@ -103,19 +108,21 @@ export class EntityCatalog extends EventEmitter
|
||||
|
||||
this.setGroups(Type.isArray(props.groups) ? props.groups : []);
|
||||
this.setItems(Type.isArray(props.items) ? props.items : []);
|
||||
this.#recentGroupData = props.recentGroupData;
|
||||
|
||||
// backward compatibility
|
||||
this.#recentGroupData = props.recentGroupData ?? null;
|
||||
this.#showRecentGroup = Type.isBoolean(props.showRecentGroup) ? props.showRecentGroup : false;
|
||||
|
||||
if (Type.isBoolean(props.canDeselectGroups))
|
||||
{
|
||||
this.#groups.forEach((groupList) => {
|
||||
groupList.forEach((group) => {
|
||||
group.deselectable = props.canDeselectGroups
|
||||
group.deselectable = props.canDeselectGroups;
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
this.#showEmptyGroups = Type.isBoolean(props.showEmptyGroups) ? props.showEmptyGroups : false;
|
||||
this.#showRecentGroup = Type.isBoolean(props.showRecentGroup) ? props.showRecentGroup : false;
|
||||
this.#showSearch = Type.isBoolean(props.showSearch) ? props.showSearch : false;
|
||||
|
||||
if (Type.isPlainObject(props.filterOptions))
|
||||
@@ -127,7 +134,7 @@ export class EntityCatalog extends EventEmitter
|
||||
this.#customTitleBar = props.customTitleBar ? props.customTitleBar : null;
|
||||
this.#popupOptions = Object.assign(
|
||||
this.#getDefaultPopupOptions(),
|
||||
Type.isObject(props.popupOptions) ? props.popupOptions : {}
|
||||
Type.isObject(props.popupOptions) ? props.popupOptions : {},
|
||||
);
|
||||
this.#slots = props.slots ?? {};
|
||||
this.#customComponents = props.customComponents ?? {};
|
||||
@@ -140,15 +147,116 @@ export class EntityCatalog extends EventEmitter
|
||||
this.#groups = groups.map((groupList) => {
|
||||
if (!Type.isArray(groupList))
|
||||
{
|
||||
groupList = [groupList]
|
||||
groupList = [groupList];
|
||||
}
|
||||
return groupList.map(group => ({ selected: false, deselectable: true, ...group }));
|
||||
});
|
||||
|
||||
if (!this.#vueInstance || !this.#vueInstance.localGroups)
|
||||
{
|
||||
return this;
|
||||
}
|
||||
|
||||
if (this.isGroupsStructureChanged(this.#groups))
|
||||
{
|
||||
try
|
||||
{
|
||||
this.#vueInstance.refreshGroups(this.#groups);
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
console.error(e);
|
||||
this.#vueInstance.localGroups = this.#groups;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
const countersMap = {};
|
||||
for (const list of this.#groups)
|
||||
{
|
||||
for (const g of list)
|
||||
{
|
||||
countersMap[String(g.id)] = g.customData?.counterValue ?? null;
|
||||
}
|
||||
}
|
||||
|
||||
return groupList.map(group => ({
|
||||
selected: false,
|
||||
deselectable: true,
|
||||
...group
|
||||
}));
|
||||
});
|
||||
this._updateCountersInGroupLists(this.#vueInstance.localGroups, countersMap);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
isGroupsStructureChanged(newGroups): boolean
|
||||
{
|
||||
if (!Array.isArray(this.#groups) || !Array.isArray(newGroups))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
if (this.#groups.length !== newGroups.length)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
for (let i = 0; i < newGroups.length; i++)
|
||||
{
|
||||
const oldList = this.#groups[i] || [];
|
||||
const newList = newGroups[i] || [];
|
||||
if (oldList.length !== newList.length)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
for (let j = 0; j < newList.length; j++)
|
||||
{
|
||||
if (String(oldList[j]?.id) !== String(newList[j]?.id))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
_updateCountersInGroupLists(groupLists, countersMap = {})
|
||||
{
|
||||
if (!Array.isArray(groupLists)) return;
|
||||
for (const list of groupLists)
|
||||
{
|
||||
for (const group of list)
|
||||
{
|
||||
const id = String(group.id);
|
||||
if (Object.prototype.hasOwnProperty.call(countersMap, id))
|
||||
{
|
||||
const custom = group.customData ?? {};
|
||||
group.customData = Object.assign({}, custom, { counterValue: countersMap[id] });
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
updateGroupCounter(groupId, counterValue): this
|
||||
{
|
||||
const idStr = String(groupId);
|
||||
const countersMap = { [idStr]: counterValue };
|
||||
|
||||
this._updateCountersInGroupLists(this.#groups, countersMap);
|
||||
|
||||
if (!this.#vueInstance)
|
||||
{
|
||||
return this;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
this._updateCountersInGroupLists(this.#vueInstance.localGroups, countersMap);
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
if (typeof this.#vueInstance.refreshGroups === 'function')
|
||||
{
|
||||
this.#vueInstance.refreshGroups(this.#groups);
|
||||
}
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
@@ -158,16 +266,53 @@ export class EntityCatalog extends EventEmitter
|
||||
return this.#items;
|
||||
}
|
||||
|
||||
setItems(items: Array<ItemData>): this
|
||||
setItems(items: Array<ItemData> = []): this
|
||||
{
|
||||
items = items.map(item => ({
|
||||
button: {},
|
||||
...item
|
||||
}));
|
||||
|
||||
this.#items.length = 0;
|
||||
this.#items.push(...items);
|
||||
|
||||
if (!this.#vueInstance || typeof this.#vueInstance.refreshItems !== 'function')
|
||||
{
|
||||
return this;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
this.#vueInstance.refreshItems(this.#items);
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
console.error(e);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
updateItemById(id, patch = {}): this
|
||||
{
|
||||
if (this.#vueInstance && typeof this.#vueInstance.updateItemById === 'function')
|
||||
{
|
||||
try
|
||||
{
|
||||
this.#vueInstance.updateItemById(id, patch);
|
||||
return this;
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
console.error(e);
|
||||
}
|
||||
}
|
||||
|
||||
const itemForUpdate = this.#items.find(item => String(item.id) === String(id));
|
||||
if (itemForUpdate)
|
||||
{
|
||||
Object.assign(itemForUpdate, patch);
|
||||
}
|
||||
else
|
||||
{
|
||||
this.#items.push(Object.assign({ id }, patch));
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
@@ -182,16 +327,73 @@ export class EntityCatalog extends EventEmitter
|
||||
return this.#popup && this.#popup.isShown();
|
||||
}
|
||||
|
||||
#resolveGroupsForTemplate(): Array<Array<GroupData>>
|
||||
{
|
||||
if (!this.#recentGroupData || !this.#showRecentGroup)
|
||||
{
|
||||
return this.#groups;
|
||||
}
|
||||
|
||||
// clone groups shallowly to avoid mutating original arrays
|
||||
const groupsClone = this.#groups.map(list => list.slice());
|
||||
|
||||
const recent = {
|
||||
isHeaderGroup: true,
|
||||
id: (this.#recentGroupData.id ?? 'recent'),
|
||||
name: this.#recentGroupData.name ?? '',
|
||||
icon: this.#recentGroupData.icon ?? '',
|
||||
tags: this.#recentGroupData.tags ?? [],
|
||||
adviceTitle: this.#recentGroupData.adviceTitle,
|
||||
adviceAvatar: this.#recentGroupData.adviceAvatar,
|
||||
selected: !!this.#recentGroupData.selected,
|
||||
disabled: !!this.#recentGroupData.disabled,
|
||||
deselectable: this.#recentGroupData.deselectable ?? true,
|
||||
compare: this.#recentGroupData.compare,
|
||||
customData: Object.assign(
|
||||
{},
|
||||
this.#recentGroupData.customData ?? {},
|
||||
{
|
||||
// prefer canonical name `counterValue`, fallback to legacy `newEntitiesCount`
|
||||
counterValue: (this.#recentGroupData.customData?.counterValue ?? this.#recentGroupData.customData?.newEntitiesCount)
|
||||
}
|
||||
),
|
||||
};
|
||||
|
||||
if (groupsClone.length > 0 && Array.isArray(groupsClone[0]) && groupsClone[0].some(g => g.isHeaderGroup))
|
||||
{
|
||||
groupsClone[0].unshift(recent);
|
||||
return groupsClone;
|
||||
}
|
||||
|
||||
return [[recent], ...groupsClone];
|
||||
}
|
||||
|
||||
#attachTemplate()
|
||||
{
|
||||
const container = this.getPopup().getContentContainer();
|
||||
|
||||
if (this.#application && typeof this.#application.unmount === 'function')
|
||||
{
|
||||
try
|
||||
{
|
||||
this.#application.unmount();
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
console.error(e);
|
||||
}
|
||||
this.#application = null;
|
||||
this.#vueInstance = null;
|
||||
}
|
||||
|
||||
const context = this;
|
||||
|
||||
const groupsToPass = this.#resolveGroupsForTemplate();
|
||||
|
||||
const rootProps = {
|
||||
recentGroupData: this.#recentGroupData,
|
||||
groups: this.#groups,
|
||||
groups: groupsToPass,
|
||||
items: this.#items,
|
||||
showEmptyGroups: this.#showEmptyGroups,
|
||||
showRecentGroups: this.#showRecentGroup,
|
||||
filterOptions: this.#filterOptions,
|
||||
};
|
||||
|
||||
@@ -204,27 +406,96 @@ export class EntityCatalog extends EventEmitter
|
||||
Button,
|
||||
}),
|
||||
directives: {
|
||||
feedback
|
||||
feedback,
|
||||
},
|
||||
props: {
|
||||
recentGroupData: Object,
|
||||
groups: Array,
|
||||
items: Array,
|
||||
showEmptyGroups: Boolean,
|
||||
showRecentGroups: Boolean,
|
||||
filterOptions: Object,
|
||||
},
|
||||
created()
|
||||
{
|
||||
this.$app = context;
|
||||
},
|
||||
data(): { localGroups: Array<Array<GroupData>>, localItems: Array<Item> }
|
||||
{
|
||||
return {
|
||||
localGroups: this.groups,
|
||||
localItems: this.items,
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
onItemsRendered()
|
||||
{
|
||||
this.$app.emit('onItemsRendered');
|
||||
},
|
||||
refreshGroups(groups: Array<GroupData>)
|
||||
{
|
||||
this.localGroups = groups;
|
||||
},
|
||||
refreshItems(newItems = [])
|
||||
{
|
||||
try
|
||||
{
|
||||
const existingMap = new Map(this.localItems.map(it => [String(it.id), it]));
|
||||
|
||||
newItems.forEach(newIt => {
|
||||
const id = String(newIt.id);
|
||||
if (existingMap.has(id))
|
||||
{
|
||||
Object.assign(existingMap.get(id), newIt);
|
||||
}
|
||||
else
|
||||
{
|
||||
this.localItems.push(newIt);
|
||||
existingMap.set(id, this.localItems[this.localItems.length - 1]);
|
||||
}
|
||||
});
|
||||
|
||||
const newIds = new Set(newItems.map(it => String(it.id)));
|
||||
for (let i = this.localItems.length - 1; i >= 0; i--)
|
||||
{
|
||||
if (!newIds.has(String(this.localItems[i].id)))
|
||||
{
|
||||
this.localItems.splice(i, 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
console.error(e);
|
||||
this.localItems.splice(0, this.localItems.length, ...newItems);
|
||||
}
|
||||
},
|
||||
|
||||
updateItemById(id, patch = {})
|
||||
{
|
||||
try
|
||||
{
|
||||
const it = this.localItems.find(x => String(x.id) === String(id));
|
||||
if (it)
|
||||
{
|
||||
Object.assign(it, patch);
|
||||
}
|
||||
else
|
||||
{
|
||||
this.localItems.push(Object.assign({ id }, patch));
|
||||
}
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
console.error(e);
|
||||
}
|
||||
},
|
||||
},
|
||||
template: `
|
||||
<Application
|
||||
:recent-group-data="recentGroupData"
|
||||
:groups="groups"
|
||||
:items="items"
|
||||
ref="application"
|
||||
@itemsRendered="onItemsRendered"
|
||||
:groups="localGroups"
|
||||
:items="localItems"
|
||||
:show-empty-groups="showEmptyGroups"
|
||||
:show-recent-group="showRecentGroups"
|
||||
:filter-options="filterOptions"
|
||||
>
|
||||
<template #group-list-header>
|
||||
@@ -276,10 +547,10 @@ export class EntityCatalog extends EventEmitter
|
||||
</Application>
|
||||
`,
|
||||
},
|
||||
rootProps
|
||||
rootProps,
|
||||
);
|
||||
|
||||
this.#application.use(createPinia()).mount(this.getPopup().getContentContainer());
|
||||
this.#vueInstance = this.#application.use(createPinia()).mount(container);
|
||||
}
|
||||
|
||||
getPopup(): Popup
|
||||
@@ -294,6 +565,21 @@ export class EntityCatalog extends EventEmitter
|
||||
return this.#popup;
|
||||
}
|
||||
|
||||
selectGroup(groupId: string | number): this
|
||||
{
|
||||
if (this.#vueInstance && this.#vueInstance.$refs.application)
|
||||
{
|
||||
const group = this.#vueInstance.localGroups.flat().find(g => String(g.id) === String(groupId));
|
||||
|
||||
if (group)
|
||||
{
|
||||
this.#vueInstance.$refs.application.handleGroupSelected(group);
|
||||
}
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
#getDefaultPopupOptions(): PopupOptions
|
||||
{
|
||||
return {
|
||||
@@ -331,7 +617,7 @@ export class EntityCatalog extends EventEmitter
|
||||
onclick="${this.#handleClose.bind(this)}"
|
||||
></span>
|
||||
</div>
|
||||
`
|
||||
`,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -342,7 +628,25 @@ export class EntityCatalog extends EventEmitter
|
||||
|
||||
close()
|
||||
{
|
||||
this.#application.unmount();
|
||||
this.getPopup().close();
|
||||
try
|
||||
{
|
||||
if (this.#application && typeof this.#application.unmount === 'function')
|
||||
{
|
||||
this.#application.unmount();
|
||||
}
|
||||
|
||||
if (this.#popup)
|
||||
{
|
||||
this.#popup.close();
|
||||
}
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
console.error(e);
|
||||
}
|
||||
|
||||
this.#application = null;
|
||||
this.#vueInstance = null;
|
||||
this.#popup = null;
|
||||
}
|
||||
}
|
||||
@@ -12,6 +12,7 @@ export type GroupData = {
|
||||
selected?: boolean,
|
||||
disabled?: boolean,
|
||||
compare?: (ItemData, ItemData) => number,
|
||||
isHeaderGroup?: boolean,
|
||||
}
|
||||
|
||||
export type GroupId = number | string;
|
||||
@@ -31,6 +31,7 @@ return [
|
||||
"/bitrix/js/ui/entity-editor/js/user-field.js",
|
||||
"/bitrix/js/ui/entity-editor/js/validator.js",
|
||||
"/bitrix/js/ui/entity-editor/js/pull.js",
|
||||
"/bitrix/js/ui/entity-editor/user-field-configurators/tooltip-configurator.js",
|
||||
],
|
||||
"rel" => [
|
||||
"ajax",
|
||||
@@ -52,6 +53,7 @@ return [
|
||||
"ui.entity-selector",
|
||||
"ui.design-tokens",
|
||||
"ui.fonts.opensans",
|
||||
"ui.entity-editor.user-field-configurators.tooltip-configurator",
|
||||
],
|
||||
'settings' => [
|
||||
'isFileUserFieldViewingModesAvailable' => method_exists(FileType::class, 'isAvailableDefaultView'),
|
||||
|
||||
@@ -329,6 +329,14 @@ input.ui-entity-editor-header-title-text {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.ui-entity-editor-new-field-visibility-wrapper {
|
||||
padding: 10px 0;
|
||||
}
|
||||
|
||||
.ui-entity-editor-user-field-setting-error-text {
|
||||
color: #d0011b;
|
||||
}
|
||||
|
||||
/* addiction step*/
|
||||
.ui-entity-new-field-addiction-label { white-space: nowrap; }
|
||||
|
||||
@@ -2057,6 +2065,19 @@ input.ui-entity-editor-header-title-text {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.ui-entity-editor-block-title-text .ui-hint {
|
||||
display: inline-flex;
|
||||
margin-left: 4px;
|
||||
width: fit-content;
|
||||
height: fit-content;
|
||||
}
|
||||
|
||||
.ui-entity-editor-block-title-text .ui-hint-icon {
|
||||
margin: 0;
|
||||
width: 1.2em;
|
||||
height: 1.2em;
|
||||
}
|
||||
|
||||
.ui-entity-editor-block-title-text-right-icon {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -1,3 +1,5 @@
|
||||
/* eslint-disable */
|
||||
|
||||
BX.namespace("BX.UI");
|
||||
|
||||
if(typeof BX.UI.EntityConfigType === "undefined")
|
||||
@@ -63,6 +65,9 @@ if(typeof BX.UI.EntityConfig === "undefined")
|
||||
|
||||
this.categoryName = '';
|
||||
this.moduleId = '';
|
||||
|
||||
this.onAddPostfix = 'on_add';
|
||||
this.onUpdatePostfix = 'on_update';
|
||||
};
|
||||
BX.UI.EntityConfig.prototype =
|
||||
{
|
||||
@@ -252,7 +257,7 @@ if(typeof BX.UI.EntityConfig === "undefined")
|
||||
{
|
||||
return this._scope;
|
||||
},
|
||||
setScope: function(scope, userScopeId, moduleId)
|
||||
setScope: function(scope, userScopeId, moduleId, entityId)
|
||||
{
|
||||
var promise = new BX.Promise();
|
||||
if(
|
||||
@@ -284,7 +289,8 @@ if(typeof BX.UI.EntityConfig === "undefined")
|
||||
moduleId: this.moduleId,
|
||||
guid: this._id,
|
||||
scope: this._scope,
|
||||
userScopeId: (this._userScopeId || 0)
|
||||
userScopeId: (this._userScopeId || 0),
|
||||
entityId,
|
||||
}
|
||||
}).then(function (response) {
|
||||
promise.fulfill();
|
||||
@@ -378,34 +384,54 @@ if(typeof BX.UI.EntityConfig === "undefined")
|
||||
|
||||
return promise;
|
||||
},
|
||||
reset: function(forAllUsers)
|
||||
reset(forAllUsers, entityId)
|
||||
{
|
||||
var data = { guid: this._id, params: { scope: this._scope }, categoryName: this.categoryName };
|
||||
if(forAllUsers)
|
||||
const data = { guid: this._id, params: { scope: this._scope }, categoryName: this.categoryName };
|
||||
if (forAllUsers)
|
||||
{
|
||||
data["params"]["forAllUsers"] = "Y";
|
||||
data.params.forAllUsers = 'Y';
|
||||
}
|
||||
data['signedConfigParams'] = this._signedParams;
|
||||
|
||||
var promise = new BX.Promise();
|
||||
if (!BX.Type.isUndefined(entityId) && BX.Type.isInteger(entityId))
|
||||
{
|
||||
data.params.type = entityId > 0 ? this.onUpdatePostfix : this.onAddPostfix;
|
||||
}
|
||||
data.signedConfigParams = this._signedParams;
|
||||
|
||||
const promise = new BX.Promise();
|
||||
|
||||
BX.ajax.runComponentAction(
|
||||
"bitrix:ui.form",
|
||||
"resetConfiguration",
|
||||
{ mode: "ajax", data: data }
|
||||
).then(function(){ promise.fulfill(); });
|
||||
'bitrix:ui.form',
|
||||
'resetConfiguration',
|
||||
{ mode: 'ajax', data },
|
||||
).then(() => {
|
||||
promise.fulfill();
|
||||
}).catch((response) => {});
|
||||
|
||||
return promise;
|
||||
},
|
||||
forceCommonScopeForAll: function()
|
||||
forceCommonScopeForAll(entityId)
|
||||
{
|
||||
var promise = new BX.Promise();
|
||||
const promise = new BX.Promise();
|
||||
|
||||
const data = {
|
||||
guid: this._id,
|
||||
categoryName: this.categoryName,
|
||||
signedConfigParams: this._signedParams
|
||||
};
|
||||
|
||||
if (!BX.Type.isUndefined(entityId) && BX.Type.isInteger(entityId))
|
||||
{
|
||||
data.type = entityId > 0 ? this.onUpdatePostfix : this.onAddPostfix;
|
||||
}
|
||||
|
||||
BX.ajax.runComponentAction(
|
||||
"bitrix:ui.form",
|
||||
"forceCommonScopeForAll",
|
||||
{ mode: "ajax", data: { guid: this._id, categoryName: this.categoryName, signedConfigParams: this._signedParams } }
|
||||
).then(function(){ promise.fulfill(); });
|
||||
'bitrix:ui.form',
|
||||
'forceCommonScopeForAll',
|
||||
{ mode: 'ajax', data },
|
||||
).then(() => {
|
||||
promise.fulfill();
|
||||
}).catch((response) => {});
|
||||
|
||||
return promise;
|
||||
},
|
||||
@@ -785,4 +811,4 @@ if(typeof BX.UI.EntityConfigField === "undefined")
|
||||
self.initialize(settings);
|
||||
return self;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
@@ -4705,13 +4705,14 @@ if(typeof BX.UI.EntityEditorSection === "undefined")
|
||||
fieldData["SETTINGS"] = settings;
|
||||
}
|
||||
|
||||
fieldData['HELP_MESSAGE'] = params?.HELP_MESSAGE ?? '';
|
||||
|
||||
var showAlways = BX.prop.getBoolean(params, "showAlways", null);
|
||||
var label = BX.prop.getString(params, "label", "");
|
||||
var field = BX.prop.get(params, "field", null);
|
||||
|
||||
if(field)
|
||||
{
|
||||
var previousLabel = field.getTitle();
|
||||
if(label !== "" || showAlways !== null)
|
||||
{
|
||||
field.setTitle(label);
|
||||
@@ -4738,9 +4739,17 @@ if(typeof BX.UI.EntityEditorSection === "undefined")
|
||||
fieldData["FIELD"] = field.getName();
|
||||
fieldData["ENTITY_VALUE_ID"] = field.getEntityValueId();
|
||||
|
||||
if(this._editor.getConfigScope() === BX.UI.EntityConfigScope.common && label !== '' && previousLabel !== label)
|
||||
if(this._editor.getConfigScope() === BX.UI.EntityConfigScope.common && label !== '')
|
||||
{
|
||||
fieldData["EDIT_FORM_LABEL"] = fieldData["LIST_COLUMN_LABEL"] = fieldData["LIST_FILTER_LABEL"] = label;
|
||||
fieldData['EDIT_FORM_LABEL'] = label;
|
||||
fieldData['LIST_COLUMN_LABEL'] = label;
|
||||
fieldData['LIST_FILTER_LABEL'] = label;
|
||||
}
|
||||
else
|
||||
{
|
||||
fieldData['EDIT_FORM_LABEL'] = field._schemeElement._originalTitle;
|
||||
fieldData['LIST_COLUMN_LABEL'] = field._schemeElement._originalTitle;
|
||||
fieldData['LIST_FILTER_LABEL'] = field._schemeElement._originalTitle;
|
||||
}
|
||||
|
||||
fieldData["VALUE"] = field.getFieldValue();
|
||||
|
||||
File diff suppressed because one or more lines are too long
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user