@wizishop/angular-components 0.0.102 → 0.0.103

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.
@@ -969,7 +969,6 @@
969
969
  };
970
970
  ButtonComponent.prototype.addMaxWidthDelete = function () {
971
971
  this.buttonMaxWidthDelete = this.buttonWidthDelete + 'px';
972
- console.log('here', this.buttonMaxWidthDelete);
973
972
  };
974
973
  ButtonComponent.prototype.resetMaxWidthDelete = function () {
975
974
  this.buttonMaxWidthDelete = '0px';
@@ -1000,7 +999,6 @@
1000
999
  }
1001
1000
  if (_this.confirmDelete) {
1002
1001
  _this.buttonWidthDelete = _this.calculWidthDelete.nativeElement.offsetWidth;
1003
- console.log('here2', _this.buttonWidthDelete);
1004
1002
  }
1005
1003
  }, 1000);
1006
1004
  };
@@ -1909,24 +1907,57 @@
1909
1907
  };
1910
1908
 
1911
1909
  var LinkComponent = /** @class */ (function () {
1912
- function LinkComponent() {
1910
+ function LinkComponent(renderer2) {
1911
+ this.renderer2 = renderer2;
1913
1912
  this.target = '_self';
1914
1913
  }
1914
+ Object.defineProperty(LinkComponent.prototype, "href", {
1915
+ get: function () {
1916
+ return this._link;
1917
+ },
1918
+ set: function (link) {
1919
+ this._link = link;
1920
+ if (link && this.renderer2) {
1921
+ this.setAttributesLink();
1922
+ }
1923
+ },
1924
+ enumerable: false,
1925
+ configurable: true
1926
+ });
1915
1927
  LinkComponent.prototype.ngOnInit = function () { };
1928
+ LinkComponent.prototype.ngAfterViewInit = function () {
1929
+ this.setAttributesLink();
1930
+ };
1931
+ LinkComponent.prototype.setAttributesLink = function () {
1932
+ if (!this.linkComponent) {
1933
+ return;
1934
+ }
1935
+ if (this.href) {
1936
+ this.renderer2.setAttribute(this.linkComponent.nativeElement, "href", this.href);
1937
+ this.renderer2.setAttribute(this.linkComponent.nativeElement, "target", this.target);
1938
+ }
1939
+ else {
1940
+ this.renderer2.removeAttribute(this.linkComponent.nativeElement, "href");
1941
+ this.renderer2.removeAttribute(this.linkComponent.nativeElement, "target");
1942
+ }
1943
+ };
1916
1944
  return LinkComponent;
1917
1945
  }());
1918
1946
  LinkComponent.decorators = [
1919
1947
  { type: i0.Component, args: [{
1920
1948
  selector: 'wac-link',
1921
- template: "<a class=\"wac-link\" [href]=\"href\" [target]=\"target\" [ngClass]=\"{ class: class }\" [id]=\"{ id: id }\"><ng-content></ng-content></a>\n"
1949
+ template: "<a #linkComponent class=\"wac-link\" [ngClass]=\"{ class: class }\" [id]=\"{ id: id }\"><ng-content></ng-content></a>\n"
1922
1950
  },] }
1923
1951
  ];
1924
- LinkComponent.ctorParameters = function () { return []; };
1952
+ LinkComponent.ctorParameters = function () { return [
1953
+ { type: i0.Renderer2 }
1954
+ ]; };
1925
1955
  LinkComponent.propDecorators = {
1926
1956
  href: [{ type: i0.Input }],
1927
1957
  target: [{ type: i0.Input }],
1928
1958
  id: [{ type: i0.Input }],
1929
- class: [{ type: i0.Input }]
1959
+ class: [{ type: i0.Input }],
1960
+ linkComponent: [{ type: i0.ViewChild, args: ['linkComponent',] }]
1930
1961
  };
1931
1962
 
1932
1963
  var ProgressBarComponent = /** @class */ (function () {