@datarailsshared/datarailsshared 1.3.24 → 1.3.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/styles/img/default-avatar.svg +5 -0
- package/bundles/datarailsshared-datarailsshared.umd.js +61 -20
- package/bundles/datarailsshared-datarailsshared.umd.js.map +1 -1
- package/datarailsshared-datarailsshared-1.3.27.tgz +0 -0
- package/datarailsshared-datarailsshared.metadata.json +1 -1
- package/esm2015/lib/dr-avatar/dr-avatar.component.js +1 -1
- package/esm2015/lib/dr-dropdown/dr-dropdown.component.js +3 -3
- package/esm2015/lib/dr-inputs/button/button.component.js +5 -13
- package/esm2015/lib/dr-inputs/dr-date-picker/dr-date-picker.component.js +17 -5
- package/esm2015/lib/dr-inputs/dr-input/dr-input.component.js +2 -1
- package/esm2015/lib/dr-inputs/dr-select/dr-select.component.js +25 -4
- package/esm2015/lib/models/datePicker.js +1 -1
- package/fesm2015/datarailsshared-datarailsshared.js +45 -20
- package/fesm2015/datarailsshared-datarailsshared.js.map +1 -1
- package/lib/dr-inputs/button/button.component.d.ts +0 -4
- package/lib/dr-inputs/dr-input/dr-input.component.d.ts +1 -0
- package/lib/dr-inputs/dr-select/dr-select.component.d.ts +5 -1
- package/package.json +1 -1
- package/assets/styles/img/default_avatar.svg +0 -4
- package/datarailsshared-datarailsshared-1.3.24.tgz +0 -0
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<rect width="24" height="24" rx="12" fill="#E5E6EA"/>
|
|
3
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M15 9.75C15 11.4069 13.6569 12.75 12 12.75C10.3431 12.75 9 11.4069 9 9.75C9 8.09315 10.3431 6.75 12 6.75C13.6569 6.75 15 8.09315 15 9.75ZM13.875 9.75C13.875 10.7855 13.0355 11.625 12 11.625C10.9645 11.625 10.125 10.7855 10.125 9.75C10.125 8.71447 10.9645 7.875 12 7.875C13.0355 7.875 13.875 8.71447 13.875 9.75Z" fill="#51566F"/>
|
|
4
|
+
<path d="M15.9968 16.7631C15.5425 15.3973 14.0368 14.25 12 14.25C9.9632 14.25 8.45748 15.3973 8.00319 16.7631C7.91242 17.0359 7.67416 17.25 7.38657 17.25C7.04536 17.25 6.77507 16.9539 6.86275 16.6241C7.39546 14.6206 9.49327 13.125 12 13.125C14.5067 13.125 16.6045 14.6206 17.1373 16.6241C17.2249 16.9539 16.9546 17.25 16.6134 17.25C16.3259 17.25 16.0876 17.0359 15.9968 16.7631Z" fill="#51566F"/>
|
|
5
|
+
</svg>
|
|
@@ -1636,6 +1636,7 @@
|
|
|
1636
1636
|
readonly: [{ type: i0.Input }],
|
|
1637
1637
|
clearable: [{ type: i0.Input }],
|
|
1638
1638
|
min: [{ type: i0.Input }],
|
|
1639
|
+
max: [{ type: i0.Input }],
|
|
1639
1640
|
step: [{ type: i0.Input }],
|
|
1640
1641
|
blur: [{ type: i0.Output }],
|
|
1641
1642
|
elementClass: [{ type: i0.HostBinding, args: ['class',] }],
|
|
@@ -1646,8 +1647,16 @@
|
|
|
1646
1647
|
tabindex: [{ type: i0.HostBinding, args: ['tabindex',] }]
|
|
1647
1648
|
};
|
|
1648
1649
|
|
|
1650
|
+
var SELECT_HOST_ATTRIBUTES = [
|
|
1651
|
+
'no-left-border',
|
|
1652
|
+
'no-left-border-radius',
|
|
1653
|
+
'no-right-border',
|
|
1654
|
+
'no-right-border-radius',
|
|
1655
|
+
];
|
|
1649
1656
|
var DrSelectComponent = /** @class */ (function () {
|
|
1650
|
-
function DrSelectComponent() {
|
|
1657
|
+
function DrSelectComponent(elementRef) {
|
|
1658
|
+
var e_1, _a;
|
|
1659
|
+
this.elementRef = elementRef;
|
|
1651
1660
|
this.items = [];
|
|
1652
1661
|
this.appendTo = 'body';
|
|
1653
1662
|
this.disabled = false;
|
|
@@ -1655,6 +1664,21 @@
|
|
|
1655
1664
|
this.change = new i0.EventEmitter();
|
|
1656
1665
|
this.onChange = function () { };
|
|
1657
1666
|
this.onTouched = function () { };
|
|
1667
|
+
try {
|
|
1668
|
+
for (var SELECT_HOST_ATTRIBUTES_1 = __values(SELECT_HOST_ATTRIBUTES), SELECT_HOST_ATTRIBUTES_1_1 = SELECT_HOST_ATTRIBUTES_1.next(); !SELECT_HOST_ATTRIBUTES_1_1.done; SELECT_HOST_ATTRIBUTES_1_1 = SELECT_HOST_ATTRIBUTES_1.next()) {
|
|
1669
|
+
var attr = SELECT_HOST_ATTRIBUTES_1_1.value;
|
|
1670
|
+
if (this.hasHostAttributes(attr)) {
|
|
1671
|
+
(this.getHostElement()).classList.add(attr);
|
|
1672
|
+
}
|
|
1673
|
+
}
|
|
1674
|
+
}
|
|
1675
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
1676
|
+
finally {
|
|
1677
|
+
try {
|
|
1678
|
+
if (SELECT_HOST_ATTRIBUTES_1_1 && !SELECT_HOST_ATTRIBUTES_1_1.done && (_a = SELECT_HOST_ATTRIBUTES_1.return)) _a.call(SELECT_HOST_ATTRIBUTES_1);
|
|
1679
|
+
}
|
|
1680
|
+
finally { if (e_1) throw e_1.error; }
|
|
1681
|
+
}
|
|
1658
1682
|
}
|
|
1659
1683
|
DrSelectComponent.prototype.writeValue = function (value) {
|
|
1660
1684
|
this.selectedItem = value;
|
|
@@ -1672,6 +1696,17 @@
|
|
|
1672
1696
|
DrSelectComponent.prototype.setDisabledState = function (isDisabled) {
|
|
1673
1697
|
this.disabled = isDisabled;
|
|
1674
1698
|
};
|
|
1699
|
+
DrSelectComponent.prototype.getHostElement = function () {
|
|
1700
|
+
return this.elementRef.nativeElement;
|
|
1701
|
+
};
|
|
1702
|
+
DrSelectComponent.prototype.hasHostAttributes = function () {
|
|
1703
|
+
var _this = this;
|
|
1704
|
+
var attributes = [];
|
|
1705
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
1706
|
+
attributes[_i] = arguments[_i];
|
|
1707
|
+
}
|
|
1708
|
+
return attributes.some(function (attribute) { return _this.getHostElement().hasAttribute(attribute); });
|
|
1709
|
+
};
|
|
1675
1710
|
return DrSelectComponent;
|
|
1676
1711
|
}());
|
|
1677
1712
|
DrSelectComponent.decorators = [
|
|
@@ -1683,9 +1718,12 @@
|
|
|
1683
1718
|
useExisting: DrSelectComponent,
|
|
1684
1719
|
multi: true
|
|
1685
1720
|
}],
|
|
1686
|
-
styles: [":host{width:100%;height:32px}:host ::ng-deep ng-select.ng-select .ng-select-container{min-height:32px;height:32px;width:100%;border-radius:6px!important;border:1px solid #C3C4CE;box-shadow:none!important}:host ::ng-deep ng-select.ng-select .ng-select-container:hover{border-color:#85889c}:host ::ng-deep ng-select.ng-select .ng-select-container:focus-within{border-color:#21b8f1}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-input{top:0!important;line-height:30px;padding:0 50px 0 8px!important;color:#151b3f;font-size:14px;font-weight:400}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-value-container{padding:0 0 0 8px;height:100%;overflow:auto}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-value-container .ng-value{line-height:1}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-value-container .ng-input{padding:0 0 0 3px!important}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container{max-height:58px;height:100%}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container{max-height:58px}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value{color:#151a41;height:24px;padding:2px 8px;font-size:12px;margin:2px 2px 2px 0;background:#E5E6EA;display:flex;flex-direction:row-reverse;align-items:center;border-radius:12px}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-label{line-height:20px;padding:0!important}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-icon{border:none!important;padding:0 0 0 9px!important;color:#51566f;font-size:16px;font-weight:bold}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-icon,:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-icon:hover{background:transparent!important}:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:hover,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:focus-within{background:#E5E6EA!important;border:1px solid #E5E6EA!important}:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container .ng-value,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:hover .ng-value,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:focus-within .ng-value{color:#bcbcbc!important}:host ::ng-deep ng-select.ng-select.ng-select-single.ng-invalid.ng-touched .ng-select-container,:host ::ng-deep ng-select.ng-select.ng-select-multiple.ng-invalid.ng-touched .ng-select-container{border-color:#de2833}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select{border:1px solid #DBDEE3;border-radius:6px!important;margin-top:8px!important;overflow:hidden}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option:empty{display:none}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option{display:flex;align-items:center;min-height:36px;padding:10px 12px}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option>.ng-option-label{text-overflow:ellipsis;overflow:hidden}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-marked{background:#fff}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected.ng-option-marked{background:#F3F7FF;color:#151b3f}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected span,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected.ng-option-marked span{font-weight:normal!important}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option:hover,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected:hover,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected.ng-option-marked:hover{background:#F6F7F8}\n"]
|
|
1721
|
+
styles: [":host{width:100%;height:32px}:host.no-left-border-radius ::ng-deep ng-select.ng-select .ng-select-container{border-bottom-left-radius:0!important;border-top-left-radius:0!important}:host.no-right-border-radius ::ng-deep ng-select.ng-select .ng-select-container{border-bottom-right-radius:0!important;border-top-right-radius:0!important}:host.no-right-border ::ng-deep ng-select.ng-select .ng-select-container{border-right:none!important}:host.no-left-border ::ng-deep ng-select.ng-select .ng-select-container{border-left:none!important}:host ::ng-deep ng-select.ng-select .ng-select-container{min-height:32px;height:32px;width:100%;border-radius:6px!important;border:1px solid #C3C4CE;box-shadow:none!important}:host ::ng-deep ng-select.ng-select .ng-select-container:hover{border-color:#85889c}:host ::ng-deep ng-select.ng-select .ng-select-container:focus-within{border-color:#21b8f1}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-input{top:0!important;line-height:30px;padding:0 50px 0 8px!important;color:#151b3f;font-size:14px;font-weight:400}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-value-container{padding:0 0 0 8px;height:100%;overflow:auto}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-value-container .ng-value{line-height:1}:host ::ng-deep ng-select.ng-select .ng-select-container .ng-value-container .ng-input{padding:0 0 0 3px!important}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container{max-height:58px;height:100%}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container{max-height:58px}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value{color:#151a41;height:24px;padding:2px 8px;font-size:12px;margin:2px 2px 2px 0;background:#E5E6EA;display:flex;flex-direction:row-reverse;align-items:center;border-radius:12px}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-label{line-height:20px;padding:0!important}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-icon{border:none!important;padding:0 0 0 9px!important;color:#51566f;font-size:16px;font-weight:bold}:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-icon,:host ::ng-deep ng-select.ng-select.ng-select-multiple .ng-select-container .ng-value-container .ng-value-icon:hover{background:transparent!important}:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:hover,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:focus-within{background:#E5E6EA!important;border:1px solid #E5E6EA!important}:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container .ng-value,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:hover .ng-value,:host ::ng-deep ng-select.ng-select.ng-select-disabled .ng-select-container:focus-within .ng-value{color:#bcbcbc!important}:host ::ng-deep ng-select.ng-select.ng-select-single.ng-invalid.ng-touched .ng-select-container,:host ::ng-deep ng-select.ng-select.ng-select-multiple.ng-invalid.ng-touched .ng-select-container{border-color:#de2833}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select{border:1px solid #DBDEE3;border-radius:6px!important;margin-top:8px!important;overflow:hidden}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option:empty{display:none}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option{display:flex;align-items:center;min-height:36px;padding:10px 12px}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option>.ng-option-label{text-overflow:ellipsis;overflow:hidden}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-marked{background:#fff}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected.ng-option-marked{background:#F3F7FF;color:#151b3f}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected span,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected.ng-option-marked span{font-weight:normal!important}::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option:hover,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected:hover,::ng-deep ng-dropdown-panel.ng-dropdown-panel.dr-select .ng-dropdown-panel-items .ng-option.ng-option-selected.ng-option-marked:hover{background:#F6F7F8}\n"]
|
|
1687
1722
|
},] }
|
|
1688
1723
|
];
|
|
1724
|
+
DrSelectComponent.ctorParameters = function () { return [
|
|
1725
|
+
{ type: i0.ElementRef }
|
|
1726
|
+
]; };
|
|
1689
1727
|
DrSelectComponent.propDecorators = {
|
|
1690
1728
|
className: [{ type: i0.Input }],
|
|
1691
1729
|
items: [{ type: i0.Input }],
|
|
@@ -1747,7 +1785,7 @@
|
|
|
1747
1785
|
selector: 'dr-avatar',
|
|
1748
1786
|
template: "<div class=\"users-section\">\r\n <div *ngIf=\"!parsedUsers.length\"\r\n class=\"users-section__default\">\r\n </div>\r\n\r\n <div *ngFor=\"let user of getFirstUsers()\"\r\n class=\"users-section__user\"\r\n [class]=\"'icon-' + user.colorNumber + ' ' + user.status\"\r\n (click)=\"userClicked.emit()\"\r\n [matTooltip]=\"user | drAvatar\"\r\n [matTooltipPosition]=\"'below'\">\r\n {{user | drAvatar: 'initials'}}\r\n </div>\r\n\r\n <div *ngIf=\"parsedUsers.length > 2\"\r\n class=\"users-section__user icon-2\"\r\n [drTooltip]=\"usersTemplate\"\r\n [drTooltipPosition]=\"'bottom'\">\r\n {{getLastUsers().length}}\r\n </div>\r\n</div>\r\n\r\n<ng-template #usersTemplate>\r\n <div *ngFor=\"let user of getLastUsers()\" class=\"users-popover-item\">\r\n <div class=\"users-section__user\"\r\n (click)=\"userClicked.emit()\"\r\n [class]=\"user.class\">\r\n {{user | drAvatar: 'initials'}}\r\n </div>\r\n <span class=\"username\">\r\n {{user | drAvatar}}\r\n </span>\r\n </div>\r\n</ng-template>\r\n",
|
|
1749
1787
|
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
1750
|
-
styles: [":host{width:auto}.users-section{display:flex;height:28px}.users-section__default{display:flex;height:28px;width:28px;border-radius:14px;background:url(\"data:image/svg+xml,%3Csvg width%3D%2224%22 height%3D%2224%22 viewBox%3D%220 0 24 24%22 fill%3D%22none%22 xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0D%3Crect width%3D%2224%22 height%3D%2224%22 rx%3D%2212%22 fill%3D%22%
|
|
1788
|
+
styles: [":host{width:auto}.users-section{display:flex;height:28px}.users-section__default{display:flex;height:28px;width:28px;border-radius:14px;background:url(\"data:image/svg+xml,%3Csvg width%3D%2224%22 height%3D%2224%22 viewBox%3D%220 0 24 24%22 fill%3D%22none%22 xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0D%3Crect width%3D%2224%22 height%3D%2224%22 rx%3D%2212%22 fill%3D%22%23E5E6EA%22%2F%3E%0D%3Cpath fill-rule%3D%22evenodd%22 clip-rule%3D%22evenodd%22 d%3D%22M15 9.75C15 11.4069 13.6569 12.75 12 12.75C10.3431 12.75 9 11.4069 9 9.75C9 8.09315 10.3431 6.75 12 6.75C13.6569 6.75 15 8.09315 15 9.75ZM13.875 9.75C13.875 10.7855 13.0355 11.625 12 11.625C10.9645 11.625 10.125 10.7855 10.125 9.75C10.125 8.71447 10.9645 7.875 12 7.875C13.0355 7.875 13.875 8.71447 13.875 9.75Z%22 fill%3D%22%2351566F%22%2F%3E%0D%3Cpath d%3D%22M15.9968 16.7631C15.5425 15.3973 14.0368 14.25 12 14.25C9.9632 14.25 8.45748 15.3973 8.00319 16.7631C7.91242 17.0359 7.67416 17.25 7.38657 17.25C7.04536 17.25 6.77507 16.9539 6.86275 16.6241C7.39546 14.6206 9.49327 13.125 12 13.125C14.5067 13.125 16.6045 14.6206 17.1373 16.6241C17.2249 16.9539 16.9546 17.25 16.6134 17.25C16.3259 17.25 16.0876 17.0359 15.9968 16.7631Z%22 fill%3D%22%2351566F%22%2F%3E%0D%3C%2Fsvg%3E%0D\") no-repeat;background-size:cover}.users-popover-item{display:flex;align-items:center;margin:12px}.users-popover-item .username{color:#51566f;font-size:14px}.users-popover-item .users-section__user{margin-right:8px}.users-section__user{position:relative;display:flex;justify-content:center;align-items:center;height:28px;width:28px;border-radius:14px;background:red;color:#fff;font-size:12px}.users-section__user.icon-0{background-color:#7b61ff}.users-section__user.icon-1{background-color:#21b8f1}.users-section__user.icon-2{background-color:#2969b0}.users-section__user.icon-3{background-color:#51566f}.users-section__user.icon-4{background-color:#0061ff}.users-section__user:hover{cursor:pointer}.users-section__user:not(:first-child){margin-left:4px}.users-section__user.online:after,.users-section__user.offline:after,.users-section__user.warning:after{content:\"\";display:flex;width:8px;height:8px;position:absolute;border-radius:4px;top:-2px;right:0}.users-section__user.online:after{background:#03A678}.users-section__user.offline:after{background:#DE2833}.users-section__user.warning:after{background:#FDA014}\n"]
|
|
1751
1789
|
},] }
|
|
1752
1790
|
];
|
|
1753
1791
|
DrAvatarComponent.ctorParameters = function () { return []; };
|
|
@@ -2225,23 +2263,16 @@
|
|
|
2225
2263
|
this.theme = 'primary';
|
|
2226
2264
|
this.isBold = false;
|
|
2227
2265
|
this.isLoading = false;
|
|
2228
|
-
this.click = new i0.EventEmitter();
|
|
2229
2266
|
}
|
|
2230
|
-
DrButtonComponent.prototype.onClick = function ($event) {
|
|
2231
|
-
$event.preventDefault();
|
|
2232
|
-
$event.stopPropagation();
|
|
2233
|
-
this.click.emit($event);
|
|
2234
|
-
};
|
|
2235
2267
|
return DrButtonComponent;
|
|
2236
2268
|
}());
|
|
2237
2269
|
DrButtonComponent.decorators = [
|
|
2238
2270
|
{ type: i0.Component, args: [{
|
|
2239
2271
|
selector: 'dr-button',
|
|
2240
|
-
template: "<button
|
|
2241
|
-
styles: [":host{display:inline-block}:host button[theme]{cursor:pointer;border-radius:16px;padding:5px 16px;font-family:\"Poppins\";font-style:normal;font-weight:400;font-size:14px;line-height:22px;color:#4e566c;border:1px solid #7F7FDD;display:flex;justify-content:space-between;align-items:center;height:32px}:host button[theme] .dr{padding:0;margin-left:5.35px;margin-right:8.64px}:host button[theme] .dr-spinner{animation-name:rotate;animation-iteration-count:infinite;animation-duration:1s}@keyframes rotate{0%{transform:rotate()}to{transform:rotate(360deg)}}:host button[theme][theme~=split-secondary-first],:host button[theme][theme~=split-secondary-last],:host button[theme][theme~=secondary]{padding:5px 16px;background:#FFFFFF;border-radius:16px;min-width:90px}:host button[theme][theme~=split-secondary-first]:hover:not([disabled]),:host button[theme][theme~=split-secondary-last]:hover:not([disabled]),:host button[theme][theme~=secondary]:hover:not([disabled]){color:#4e566c;transition:.2ms ease-in all;background:#F2F2FB;box-shadow:0 4px 14px #0000001a;border:1px solid #4646CE}:host button[theme][theme~=split-secondary-first]:active,:host button[theme][theme~=split-secondary-last]:active,:host button[theme][theme~=secondary]:active{box-shadow:none;background:#F2F2FB}:host button[theme][theme~=split-secondary-first][disabled],:host button[theme][theme~=split-secondary-last][disabled],:host button[theme][theme~=secondary][disabled]{background:#F0F1F4;color:#727583;border:none;cursor:default}:host button[theme][theme~=split-secondary-first][is-loading=true],:host button[theme][theme~=split-secondary-last][is-loading=true],:host button[theme][theme~=secondary][is-loading=true]{justify-content:center;padding:5px 16px}:host button[theme][theme~=split-primary-first],:host button[theme][theme~=split-primary-last],:host button[theme][theme~=primary]{background:#4646CE;color:#fff;border:none;min-width:90px}:host button[theme][theme~=split-primary-first]:hover:not([disabled]),:host button[theme][theme~=split-primary-last]:hover:not([disabled]),:host button[theme][theme~=primary]:hover:not([disabled]){transition:.2ms ease-in all;background:linear-gradient(96.89deg,#25258C 0%,#4646CE 100%);box-shadow:0 4px 14px #0000001a;border:none}:host button[theme][theme~=split-primary-first]:active,:host button[theme][theme~=split-primary-last]:active,:host button[theme][theme~=primary]:active{background:#25258C}:host button[theme][theme~=split-primary-first][disabled],:host button[theme][theme~=split-primary-last][disabled],:host button[theme][theme~=primary][disabled]{background:#F0F1F4;color:#727583;border:none;cursor:default}:host button[theme][theme~=split-primary-first][is-loading=true],:host button[theme][theme~=split-primary-last][is-loading=true],:host button[theme][theme~=primary][is-loading=true]{justify-content:center;padding:5px 16px}:host button[theme][theme~=split-primary-first] .dr,:host button[theme][theme~=split-primary-last] .dr,:host button[theme][theme~=primary] .dr{margin:0}:host button[theme][theme~=split-secondary-first],:host button[theme][theme~=split-secondary-first]:hover,:host button[theme][theme~=split-primary-first],:host button[theme][theme~=split-primary-first]:hover{min-width:unset;border-bottom-right-radius:0;border-top-right-radius:0;padding-left:10px;padding-right:8px}:host button[theme][theme~=split-secondary-first][icon=true],:host button[theme][theme~=split-secondary-first]:hover[icon=true],:host button[theme][theme~=split-primary-first][icon=true],:host button[theme][theme~=split-primary-first]:hover[icon=true]{padding-left:6px;padding-right:2px}:host button[theme][theme~=split-primary-first],:host button[theme][theme~=split-primary-first]:hover{border-right:1px solid #fff!important}:host button[theme][theme~=split-secondary-first],:host button[theme][theme~=split-secondary-first]:hover{border-right:none!important}:host button[theme][theme~=split-secondary-last],:host button[theme][theme~=split-secondary-last]:hover,:host button[theme][theme~=split-primary-last],:host button[theme][theme~=split-primary-last]:hover{min-width:unset;border-bottom-left-radius:0;border-top-left-radius:0;padding-left:8px;padding-right:10px}:host button[theme][theme~=split-secondary-last][icon=true],:host button[theme][theme~=split-secondary-last]:hover[icon=true],:host button[theme][theme~=split-primary-last][icon=true],:host button[theme][theme~=split-primary-last]:hover[icon=true]{padding-left:2px;padding-right:6px}:host button[theme][theme~=split-secondary-last] .dr,:host button[theme][theme~=split-secondary-last]:hover .dr,:host button[theme][theme~=split-primary-last] .dr,:host button[theme][theme~=split-primary-last]:hover .dr{margin:0}:host button[theme][theme~=split-primary-last],:host button[theme][theme~=split-primary-last]:hover{border-left:none}:host button[theme][theme~=split-secondary-last],:host button[theme][theme~=split-secondary-last]:hover{margin-left:-1px}:host button[theme][theme~=danger]{background:#BF1D30;color:#fff;border:none;min-width:90px}:host button[theme][theme~=danger]:hover:not([disabled]){transition:.2ms ease-in all;background:linear-gradient(96.89deg,#740e1a 0%,#BF1D30 100%);box-shadow:0 4px 14px #0000001a;border-radius:16px;border:none}:host button[theme][theme~=danger]:active{background:#740e1a}:host button[theme][theme~=danger][disabled]{background:#F0F1F4;color:#727583;border:none;cursor:default}:host button[theme][theme~=danger][is-loading=true]{justify-content:center;padding:5px 16px}:host button[theme][theme~=ghost]{background:none;border:none;color:#151b3f;padding:4px 8px}:host button[theme][theme~=ghost] .dr{margin-left:4.5px;margin-right:12.5px}:host button[theme][theme~=ghost]:hover:not([disabled]){color:#4646ce;background:#F2F2FB;border-radius:4px}:host button[theme][theme~=ghost][disabled]{color:#727583;cursor:default}:host button[theme][theme~=text-link]{background:none;border:none;color:#0b5af9
|
|
2272
|
+
template: "<button [disabled]=\"disabled\" [attr.is-loading]=\"isLoading\" [attr.bold]=\"isBold\"\r\n [attr.icon]=\"!!icon\" [attr.theme]=\"theme\">\r\n <ng-container *ngIf=\"!isLoading\">\r\n <i *ngIf=\"icon\" class=\"dr\" [class]=\"icon\" [style.color]=\"iconColor || 'inherit'\"></i>\r\n <ng-content></ng-content>\r\n <i *ngIf=\"theme === 'dropdown'\" class=\"dr-icon-arrow-down\"></i>\r\n </ng-container>\r\n <i *ngIf=\"isLoading\" class=\"dr dr-spinner dr-icon-load\"></i>\r\n</button>\r\n",
|
|
2273
|
+
styles: [":host{display:inline-block}:host[ng-reflect-disabled=true],:host[ng-reflect-is-loading=true]{pointer-events:none}:host button[theme]{cursor:pointer;border-radius:16px;padding:5px 16px;font-family:\"Poppins\";font-style:normal;font-weight:400;font-size:14px;line-height:22px;color:#4e566c;border:1px solid #7F7FDD;display:flex;justify-content:space-between;align-items:center;height:32px}:host button[theme] .dr{padding:0;margin-left:5.35px;margin-right:8.64px}:host button[theme] .dr-spinner{animation-name:rotate;animation-iteration-count:infinite;animation-duration:1s}@keyframes rotate{0%{transform:rotate()}to{transform:rotate(360deg)}}:host button[theme][theme~=split-secondary-first],:host button[theme][theme~=split-secondary-last],:host button[theme][theme~=secondary]{padding:5px 16px;background:#FFFFFF;border-radius:16px;min-width:90px}:host button[theme][theme~=split-secondary-first]:hover:not([disabled]),:host button[theme][theme~=split-secondary-last]:hover:not([disabled]),:host button[theme][theme~=secondary]:hover:not([disabled]){color:#4e566c;transition:.2ms ease-in all;background:#F2F2FB;box-shadow:0 4px 14px #0000001a;border:1px solid #4646CE}:host button[theme][theme~=split-secondary-first]:active,:host button[theme][theme~=split-secondary-last]:active,:host button[theme][theme~=secondary]:active{box-shadow:none;background:#F2F2FB}:host button[theme][theme~=split-secondary-first][disabled],:host button[theme][theme~=split-secondary-last][disabled],:host button[theme][theme~=secondary][disabled]{background:#F0F1F4;color:#727583;border:none;cursor:default;pointer-events:none}:host button[theme][theme~=split-secondary-first][is-loading=true],:host button[theme][theme~=split-secondary-last][is-loading=true],:host button[theme][theme~=secondary][is-loading=true]{justify-content:center;padding:5px 16px;pointer-events:none}:host button[theme][theme~=split-primary-first],:host button[theme][theme~=split-primary-last],:host button[theme][theme~=primary]{background:#4646CE;color:#fff;border:none;min-width:90px}:host button[theme][theme~=split-primary-first]:hover:not([disabled]),:host button[theme][theme~=split-primary-last]:hover:not([disabled]),:host button[theme][theme~=primary]:hover:not([disabled]){transition:.2ms ease-in all;background:linear-gradient(96.89deg,#25258C 0%,#4646CE 100%);box-shadow:0 4px 14px #0000001a;border:none}:host button[theme][theme~=split-primary-first]:active,:host button[theme][theme~=split-primary-last]:active,:host button[theme][theme~=primary]:active{background:#25258C}:host button[theme][theme~=split-primary-first][disabled],:host button[theme][theme~=split-primary-last][disabled],:host button[theme][theme~=primary][disabled]{background:#F0F1F4;color:#727583;border:none;cursor:default;pointer-events:none}:host button[theme][theme~=split-primary-first][is-loading=true],:host button[theme][theme~=split-primary-last][is-loading=true],:host button[theme][theme~=primary][is-loading=true]{justify-content:center;padding:5px 16px;pointer-events:none}:host button[theme][theme~=split-primary-first] .dr,:host button[theme][theme~=split-primary-last] .dr,:host button[theme][theme~=primary] .dr{margin:0}:host button[theme][theme~=split-secondary-first],:host button[theme][theme~=split-secondary-first]:hover,:host button[theme][theme~=split-primary-first],:host button[theme][theme~=split-primary-first]:hover{min-width:unset;border-bottom-right-radius:0;border-top-right-radius:0;padding-left:10px;padding-right:8px}:host button[theme][theme~=split-secondary-first][icon=true],:host button[theme][theme~=split-secondary-first]:hover[icon=true],:host button[theme][theme~=split-primary-first][icon=true],:host button[theme][theme~=split-primary-first]:hover[icon=true]{padding-left:6px;padding-right:2px}:host button[theme][theme~=split-primary-first],:host button[theme][theme~=split-primary-first]:hover{border-right:1px solid #fff!important}:host button[theme][theme~=split-secondary-first],:host button[theme][theme~=split-secondary-first]:hover{border-right:none!important}:host button[theme][theme~=split-secondary-last],:host button[theme][theme~=split-secondary-last]:hover,:host button[theme][theme~=split-primary-last],:host button[theme][theme~=split-primary-last]:hover{min-width:unset;border-bottom-left-radius:0;border-top-left-radius:0;padding-left:8px;padding-right:10px}:host button[theme][theme~=split-secondary-last][icon=true],:host button[theme][theme~=split-secondary-last]:hover[icon=true],:host button[theme][theme~=split-primary-last][icon=true],:host button[theme][theme~=split-primary-last]:hover[icon=true]{padding-left:2px;padding-right:6px}:host button[theme][theme~=split-secondary-last] .dr,:host button[theme][theme~=split-secondary-last]:hover .dr,:host button[theme][theme~=split-primary-last] .dr,:host button[theme][theme~=split-primary-last]:hover .dr{margin:0}:host button[theme][theme~=split-primary-last],:host button[theme][theme~=split-primary-last]:hover{border-left:none}:host button[theme][theme~=split-secondary-last],:host button[theme][theme~=split-secondary-last]:hover{margin-left:-1px}:host button[theme][theme~=danger]{background:#BF1D30;color:#fff;border:none;min-width:90px}:host button[theme][theme~=danger]:hover:not([disabled]){transition:.2ms ease-in all;background:linear-gradient(96.89deg,#740e1a 0%,#BF1D30 100%);box-shadow:0 4px 14px #0000001a;border-radius:16px;border:none}:host button[theme][theme~=danger]:active{background:#740e1a}:host button[theme][theme~=danger][disabled]{background:#F0F1F4;color:#727583;border:none;cursor:default;pointer-events:none}:host button[theme][theme~=danger][is-loading=true]{justify-content:center;padding:5px 16px;pointer-events:none}:host button[theme][theme~=ghost]{background:none;border:none;color:#151b3f;padding:4px 8px}:host button[theme][theme~=ghost] .dr{margin-left:4.5px;margin-right:12.5px}:host button[theme][theme~=ghost]:hover:not([disabled]){color:#4646ce;background:#F2F2FB;border-radius:4px}:host button[theme][theme~=ghost][disabled]{color:#727583;cursor:default;pointer-events:none}:host button[theme][theme~=text-link]{background:none;border:none;color:#0b5af9}:host button[theme][theme~=text-link][disabled]{color:#727583;pointer-events:none}:host button[theme][theme~=primary-icon]{padding:8px;width:28px;height:28px;justify-content:center;color:#fff;background:#4646CE;border:none}:host button[theme][theme~=primary-icon]:hover,:host button[theme][theme~=primary-icon]:active{background:linear-gradient(96.89deg,#131318 0%,#4646CE 100%)}:host button[theme][theme~=primary-icon][disabled]{color:#bcbcbc;background:#E5E6EA;cursor:default;pointer-events:none}:host button[theme][theme~=primary-icon] .dr{margin:0}:host button[theme][theme~=secondary-icon]{background:white;padding:8px;width:28px;height:28px;justify-content:center;color:#4e566c;border:1px solid #7F7FDD}:host button[theme][theme~=secondary-icon]:hover,:host button[theme][theme~=secondary-icon]:active{color:#4646ce;background:#F2F2FB}:host button[theme][theme~=secondary-icon][disabled]{color:#bcbcbc;background:#E5E6EA;border:none;cursor:default;pointer-events:none}:host button[theme][theme~=secondary-icon] .dr{margin:0}:host button[theme][theme~=icon]{background:none;padding:8px;width:28px;height:28px;justify-content:center;color:#4e566c;border:none}:host button[theme][theme~=icon]:hover,:host button[theme][theme~=icon]:active{background:#F0F3FC;color:#4646ce}:host button[theme][theme~=icon][disabled]{color:#bcbcbc;border:none;cursor:default;pointer-events:none}:host button[theme][theme~=icon][disabled]:hover,:host button[theme][theme~=icon][disabled]:active{background:none}:host button[theme][theme~=icon] .dr{margin:0}:host button[theme][theme~=dropdown]{padding:0 8px;background:#FFFFFF;border-radius:6px;border:1px solid #C3C4CE;min-width:unset;box-shadow:none}:host button[theme][theme~=dropdown]:hover{border-color:#85889c}:host button[theme][theme~=dropdown]:active{border-color:#4646ce}:host button[theme][theme~=dropdown] i:first-child{margin-right:3px}:host button[theme][theme~=dropdown] i:last-child{margin-left:3px}:host button[theme][bold=true]{font-weight:600}:host button[theme][icon=true]{padding-left:8px}:host button[theme][icon=false]{justify-content:center}\n"]
|
|
2242
2274
|
},] }
|
|
2243
2275
|
];
|
|
2244
|
-
DrButtonComponent.ctorParameters = function () { return []; };
|
|
2245
2276
|
DrButtonComponent.propDecorators = {
|
|
2246
2277
|
title: [{ type: i0.Input }],
|
|
2247
2278
|
theme: [{ type: i0.Input }],
|
|
@@ -2249,8 +2280,7 @@
|
|
|
2249
2280
|
icon: [{ type: i0.Input }],
|
|
2250
2281
|
isBold: [{ type: i0.Input }],
|
|
2251
2282
|
isLoading: [{ type: i0.Input }],
|
|
2252
|
-
iconColor: [{ type: i0.Input }]
|
|
2253
|
-
click: [{ type: i0.Output }]
|
|
2283
|
+
iconColor: [{ type: i0.Input }]
|
|
2254
2284
|
};
|
|
2255
2285
|
// Examples:
|
|
2256
2286
|
/*
|
|
@@ -2356,6 +2386,12 @@
|
|
|
2356
2386
|
Object.defineProperty(DrDatePickerComponent.prototype, "format", {
|
|
2357
2387
|
set: function (value) {
|
|
2358
2388
|
if (value) {
|
|
2389
|
+
if (value.includes('d')) {
|
|
2390
|
+
value = value.replace(/d/g, 'D');
|
|
2391
|
+
}
|
|
2392
|
+
else if (value.includes('D')) {
|
|
2393
|
+
value = value.replace(/D/g, 'd');
|
|
2394
|
+
}
|
|
2359
2395
|
this._format = value;
|
|
2360
2396
|
this.cdr.markForCheck();
|
|
2361
2397
|
}
|
|
@@ -2404,7 +2440,12 @@
|
|
|
2404
2440
|
};
|
|
2405
2441
|
DrDatePickerComponent.prototype.writeValue = function (value) {
|
|
2406
2442
|
if (value !== this.innerValue) {
|
|
2407
|
-
|
|
2443
|
+
if (value && typeof value === 'number') {
|
|
2444
|
+
this.innerValue = momentImported__namespace.unix(value);
|
|
2445
|
+
}
|
|
2446
|
+
else {
|
|
2447
|
+
this.innerValue = value;
|
|
2448
|
+
}
|
|
2408
2449
|
this.cdr.markForCheck();
|
|
2409
2450
|
}
|
|
2410
2451
|
};
|
|
@@ -2426,13 +2467,13 @@
|
|
|
2426
2467
|
}());
|
|
2427
2468
|
DrDatePickerComponent.decorators = [
|
|
2428
2469
|
{ type: i0.Component, args: [{
|
|
2429
|
-
selector: '
|
|
2430
|
-
template: "
|
|
2470
|
+
selector: 'dr-date-picker',
|
|
2471
|
+
template: "<i class=\"dr-icon-schedule\"></i>\r\n<input [(ngModel)]=\"value\"\r\n (click)=\"datePicker.open()\"\r\n [matDatepicker]=\"datePicker\"\r\n [placeholder]=\"placeholder\"\r\n [drDatePickerFormat]=\"_format\"\r\n [readonly]=\"readonly\"\r\n [min]=\"min\"\r\n [max]=\"max\"\r\n/>\r\n <mat-datepicker #datePicker\r\n startView=\"{{_lastView}}\"\r\n (yearSelected)=\"chosenYearHandler($event, datePicker)\"\r\n (monthSelected)=\"chosenMonthHandler($event, datePicker)\">\r\n </mat-datepicker>\r\n\r\n",
|
|
2431
2472
|
changeDetection: i0.ChangeDetectionStrategy.OnPush,
|
|
2432
2473
|
providers: [
|
|
2433
2474
|
{ provide: forms.NG_VALUE_ACCESSOR, useExisting: DrDatePickerComponent, multi: true }
|
|
2434
2475
|
],
|
|
2435
|
-
styles: ["
|
|
2476
|
+
styles: [":host{position:relative;width:100%;display:flex;flex-direction:row;min-height:32px;height:32px;font-size:14px;font-family:\"Poppins\",sans-serif;background:#fff;border:1px solid #C3C4CE;border-radius:6px;color:#85889c;overflow:hidden;outline:none;cursor:pointer}:host:hover{border-color:#85889c}:host:focus-within{border-color:#21b8f1!important;color:#151b3f}:host.disabled{pointer-events:none;border:none;color:#85889c;background:#E5E6EA}:host.ng-valid.ng-dirty{border-color:#03a678}:host.ng-invalid.ng-dirty:not(:focus-within){border-color:#de2833!important}:host.ng-untouched.ng-valid{border-color:#c3c4ce}:host:after,:host:before{position:absolute;display:flex;border-color:#999 transparent transparent;color:#999}:host:after{content:\"\";height:0;width:0;border-style:solid;border-width:5px 5px 2.5px;right:11px;top:13px}:host i{position:absolute;color:#999;left:8px;top:3px}:host input{display:flex;flex-grow:1;height:100%;border:none;text-align:left;padding-left:35px;padding-right:25px;cursor:pointer!important}:host input:disabled{border:none;color:#85889c;background:transparent}:host input::-webkit-search-decoration,:host input::-webkit-search-cancel-button,:host input::-webkit-search-results-button,:host input::-webkit-search-results-decoration{-webkit-appearance:none}::ng-deep .mat-datepicker-content{margin:7px 0;box-shadow:0 4px 8px 1px #00000040;border-radius:12px!important}::ng-deep .mat-datepicker-content button[disabled]{border:inherit;color:inherit;background-color:inherit}::ng-deep .mat-datepicker-content button[disabled]:hover{border:inherit}::ng-deep .mat-calendar-body-cell:not(.mat-calendar-body-disabled):hover>.mat-calendar-body-cell-content:not(.mat-calendar-body-selected):not(.mat-calendar-body-comparison-identical){background:#F3F7FF}::ng-deep .mat-calendar-body-selected{background-color:#579bf2}::ng-deep .mat-calendar-body-today.mat-calendar-body-selected{box-shadow:none}::ng-deep .mat-button-focus-overlay{background:#F3F7FF}::ng-deep .mat-calendar-controls .mat-icon-button:hover .mat-button-focus-overlay{opacity:1!important;background:#F3F7FF;transition:opacity .2s cubic-bezier(.35,0,.25,1)}::ng-deep .mat-calendar-controls .mat-calendar-period-button:hover{background:#F3F7FF;transition:background .2s cubic-bezier(.35,0,.25,1)}\n"]
|
|
2436
2477
|
},] }
|
|
2437
2478
|
];
|
|
2438
2479
|
DrDatePickerComponent.ctorParameters = function () { return [
|
|
@@ -2820,11 +2861,11 @@
|
|
|
2820
2861
|
this.containerClass = data.class;
|
|
2821
2862
|
this.list = data.list || [];
|
|
2822
2863
|
this.list.forEach(function (item) {
|
|
2823
|
-
var _a;
|
|
2864
|
+
var _a, _b;
|
|
2824
2865
|
if ((_a = item.children) === null || _a === void 0 ? void 0 : _a.length) {
|
|
2825
2866
|
item.childOptions = {
|
|
2826
2867
|
list: item.children,
|
|
2827
|
-
class: item.childOptions.class,
|
|
2868
|
+
class: ((_b = item === null || item === void 0 ? void 0 : item.childOptions) === null || _b === void 0 ? void 0 : _b.class) || '',
|
|
2828
2869
|
position: 'child'
|
|
2829
2870
|
};
|
|
2830
2871
|
}
|