ps-toolkit-ui 0.0.91 → 0.0.95

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.
@@ -812,6 +812,10 @@
812
812
  PermissionTypeEnum[PermissionTypeEnum["OptionModal"] = 7] = "OptionModal";
813
813
  PermissionTypeEnum[PermissionTypeEnum["OptionConfirm"] = 8] = "OptionConfirm";
814
814
  })(exports.PermissionTypeEnum || (exports.PermissionTypeEnum = {}));
815
+ (function (PermissionOptionTypeEnum) {
816
+ PermissionOptionTypeEnum[PermissionOptionTypeEnum["Icon"] = 0] = "Icon";
817
+ PermissionOptionTypeEnum[PermissionOptionTypeEnum["Button"] = 1] = "Button";
818
+ })(exports.PermissionOptionTypeEnum || (exports.PermissionOptionTypeEnum = {}));
815
819
  (function (VehicleType) {
816
820
  VehicleType[VehicleType["Car"] = 1] = "Car";
817
821
  VehicleType[VehicleType["Motorcycle"] = 2] = "Motorcycle";
@@ -3855,7 +3859,9 @@
3855
3859
  function FormLabelComponent() {
3856
3860
  }
3857
3861
  FormLabelComponent.prototype.ngOnInit = function () {
3862
+ var _this = this;
3858
3863
  this.inp.setValue = function (v) {
3864
+ _this.inp.value = v;
3859
3865
  };
3860
3866
  this.inp.isValid = function () {
3861
3867
  return true;
@@ -5077,10 +5083,11 @@
5077
5083
  };
5078
5084
 
5079
5085
  var PermissionClass = /** @class */ (function () {
5080
- function PermissionClass(Name, Icon, Type, Area, Controller, Action, Condition, Accesses) {
5086
+ function PermissionClass(Name, Icon, Type, OptionType, Area, Controller, Action, Condition, Accesses) {
5081
5087
  if (Name === void 0) { Name = ''; }
5082
5088
  if (Icon === void 0) { Icon = ''; }
5083
5089
  if (Type === void 0) { Type = null; }
5090
+ if (OptionType === void 0) { OptionType = null; }
5084
5091
  if (Area === void 0) { Area = ''; }
5085
5092
  if (Controller === void 0) { Controller = ''; }
5086
5093
  if (Action === void 0) { Action = ''; }
@@ -5089,6 +5096,7 @@
5089
5096
  this.Name = Name;
5090
5097
  this.Icon = Icon;
5091
5098
  this.Type = Type;
5099
+ this.OptionType = OptionType;
5092
5100
  this.Area = Area;
5093
5101
  this.Controller = Controller;
5094
5102
  this.Action = Action;
@@ -6948,7 +6956,7 @@
6948
6956
  return p.length > 0 ? this.getPermissionClass(p[0]) : null;
6949
6957
  };
6950
6958
  BaseComponent.prototype.getPermissionClass = function (p) {
6951
- return new PermissionClass(p.Name, p.Icon, p.Type, this.app.area, p.Controller, p.Action, p.Condition, this.getPermissionAccessesClass(p.Id));
6959
+ return new PermissionClass(p.Name, p.Icon, p.Type, p.OptionType, this.app.area, p.Controller, p.Action, p.Condition, this.getPermissionAccessesClass(p.Id));
6952
6960
  };
6953
6961
  BaseComponent.prototype.getPermissionAccessesClass = function (parentId) {
6954
6962
  var _this = this;
@@ -7183,7 +7191,7 @@
7183
7191
  if (this_1.options.filter(function (x) { return x.name === option.Name; }).length > 0) {
7184
7192
  return "continue";
7185
7193
  }
7186
- var opt = new InputClass(this_1.environment, this_1.l, option.Name, option.Icon, exports.InputType.Icon, 'blue h-25 m-h-5 d-ib va-m f-u');
7194
+ var opt = new InputClass(this_1.environment, this_1.l, option.Name, option.Icon, option.OptionType === exports.PermissionOptionTypeEnum.Icon ? exports.InputType.Icon : exports.InputType.Button, 'blue h-25 m-h-5 d-ib va-m f-u');
7187
7195
  opt.condition = option.Condition;
7188
7196
  if (option.Type === exports.PermissionTypeEnum.OptionLink || option.Type === exports.PermissionTypeEnum.OptionLinkNewTab) {
7189
7197
  var p = new PermissionClass();