tab-dxi.js 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215
  1. "use strict";
  2. var __extends = (this && this.__extends) || (function () {
  3. var extendStatics = Object.setPrototypeOf ||
  4. ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
  5. function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
  6. return function (d, b) {
  7. extendStatics(d, b);
  8. function __() { this.constructor = d; }
  9. d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  10. };
  11. })();
  12. /*!
  13. * devextreme-angular
  14. * Version: 19.1.16
  15. * Build date: Tue Oct 18 2022
  16. *
  17. * Copyright (c) 2012 - 2022 Developer Express Inc. ALL RIGHTS RESERVED
  18. *
  19. * This software may be modified and distributed under the terms
  20. * of the MIT license. See the LICENSE file in the root of the project for details.
  21. *
  22. * https://github.com/DevExpress/devextreme-angular
  23. */
  24. Object.defineProperty(exports, "__esModule", { value: true });
  25. var core_1 = require("@angular/core");
  26. var common_1 = require("@angular/common");
  27. var nested_option_1 = require("../../core/nested-option");
  28. var template_host_1 = require("../../core/template-host");
  29. var nested_option_2 = require("../../core/nested-option");
  30. var item_dxi_1 = require("./item-dxi");
  31. var DxiTabComponent = (function (_super) {
  32. __extends(DxiTabComponent, _super);
  33. function DxiTabComponent(parentOptionHost, optionHost, renderer, document, templateHost, element) {
  34. var _this = _super.call(this) || this;
  35. _this.renderer = renderer;
  36. _this.document = document;
  37. _this.element = element;
  38. parentOptionHost.setNestedOption(_this);
  39. optionHost.setHost(_this, _this._fullOptionPath.bind(_this));
  40. templateHost.setHost(_this);
  41. return _this;
  42. }
  43. Object.defineProperty(DxiTabComponent.prototype, "alignItemLabels", {
  44. get: function () {
  45. return this._getOption('alignItemLabels');
  46. },
  47. set: function (value) {
  48. this._setOption('alignItemLabels', value);
  49. },
  50. enumerable: true,
  51. configurable: true
  52. });
  53. Object.defineProperty(DxiTabComponent.prototype, "badge", {
  54. get: function () {
  55. return this._getOption('badge');
  56. },
  57. set: function (value) {
  58. this._setOption('badge', value);
  59. },
  60. enumerable: true,
  61. configurable: true
  62. });
  63. Object.defineProperty(DxiTabComponent.prototype, "colCount", {
  64. get: function () {
  65. return this._getOption('colCount');
  66. },
  67. set: function (value) {
  68. this._setOption('colCount', value);
  69. },
  70. enumerable: true,
  71. configurable: true
  72. });
  73. Object.defineProperty(DxiTabComponent.prototype, "colCountByScreen", {
  74. get: function () {
  75. return this._getOption('colCountByScreen');
  76. },
  77. set: function (value) {
  78. this._setOption('colCountByScreen', value);
  79. },
  80. enumerable: true,
  81. configurable: true
  82. });
  83. Object.defineProperty(DxiTabComponent.prototype, "disabled", {
  84. get: function () {
  85. return this._getOption('disabled');
  86. },
  87. set: function (value) {
  88. this._setOption('disabled', value);
  89. },
  90. enumerable: true,
  91. configurable: true
  92. });
  93. Object.defineProperty(DxiTabComponent.prototype, "icon", {
  94. get: function () {
  95. return this._getOption('icon');
  96. },
  97. set: function (value) {
  98. this._setOption('icon', value);
  99. },
  100. enumerable: true,
  101. configurable: true
  102. });
  103. Object.defineProperty(DxiTabComponent.prototype, "items", {
  104. get: function () {
  105. return this._getOption('items');
  106. },
  107. set: function (value) {
  108. this._setOption('items', value);
  109. },
  110. enumerable: true,
  111. configurable: true
  112. });
  113. Object.defineProperty(DxiTabComponent.prototype, "tabTemplate", {
  114. get: function () {
  115. return this._getOption('tabTemplate');
  116. },
  117. set: function (value) {
  118. this._setOption('tabTemplate', value);
  119. },
  120. enumerable: true,
  121. configurable: true
  122. });
  123. Object.defineProperty(DxiTabComponent.prototype, "template", {
  124. get: function () {
  125. return this._getOption('template');
  126. },
  127. set: function (value) {
  128. this._setOption('template', value);
  129. },
  130. enumerable: true,
  131. configurable: true
  132. });
  133. Object.defineProperty(DxiTabComponent.prototype, "title", {
  134. get: function () {
  135. return this._getOption('title');
  136. },
  137. set: function (value) {
  138. this._setOption('title', value);
  139. },
  140. enumerable: true,
  141. configurable: true
  142. });
  143. Object.defineProperty(DxiTabComponent.prototype, "_optionPath", {
  144. get: function () {
  145. return 'tabs';
  146. },
  147. enumerable: true,
  148. configurable: true
  149. });
  150. Object.defineProperty(DxiTabComponent.prototype, "itemsChildren", {
  151. get: function () {
  152. return this._getOption('items');
  153. },
  154. set: function (value) {
  155. this.setChildren('items', value);
  156. },
  157. enumerable: true,
  158. configurable: true
  159. });
  160. DxiTabComponent.prototype.setTemplate = function (template) {
  161. this.template = template;
  162. };
  163. DxiTabComponent.prototype.ngAfterViewInit = function () {
  164. nested_option_1.extractTemplate(this, this.element, this.renderer, this.document);
  165. };
  166. DxiTabComponent.decorators = [
  167. { type: core_1.Component, args: [{
  168. selector: 'dxi-tab',
  169. template: '<ng-content></ng-content>',
  170. styles: [':host { display: block; }'],
  171. providers: [nested_option_1.NestedOptionHost, template_host_1.DxTemplateHost]
  172. },] },
  173. ];
  174. /** @nocollapse */
  175. DxiTabComponent.ctorParameters = function () { return [
  176. { type: nested_option_1.NestedOptionHost, decorators: [{ type: core_1.SkipSelf }, { type: core_1.Host },] },
  177. { type: nested_option_1.NestedOptionHost, decorators: [{ type: core_1.Host },] },
  178. { type: core_1.Renderer2, },
  179. { type: undefined, decorators: [{ type: core_1.Inject, args: [common_1.DOCUMENT,] },] },
  180. { type: template_host_1.DxTemplateHost, decorators: [{ type: core_1.Host },] },
  181. { type: core_1.ElementRef, },
  182. ]; };
  183. DxiTabComponent.propDecorators = {
  184. "alignItemLabels": [{ type: core_1.Input },],
  185. "badge": [{ type: core_1.Input },],
  186. "colCount": [{ type: core_1.Input },],
  187. "colCountByScreen": [{ type: core_1.Input },],
  188. "disabled": [{ type: core_1.Input },],
  189. "icon": [{ type: core_1.Input },],
  190. "items": [{ type: core_1.Input },],
  191. "tabTemplate": [{ type: core_1.Input },],
  192. "template": [{ type: core_1.Input },],
  193. "title": [{ type: core_1.Input },],
  194. "itemsChildren": [{ type: core_1.ContentChildren, args: [core_1.forwardRef(function () { return item_dxi_1.DxiItemComponent; }),] },],
  195. };
  196. return DxiTabComponent;
  197. }(nested_option_2.CollectionNestedOption));
  198. exports.DxiTabComponent = DxiTabComponent;
  199. var DxiTabModule = (function () {
  200. function DxiTabModule() {
  201. }
  202. DxiTabModule.decorators = [
  203. { type: core_1.NgModule, args: [{
  204. declarations: [
  205. DxiTabComponent
  206. ],
  207. exports: [
  208. DxiTabComponent
  209. ],
  210. },] },
  211. ];
  212. return DxiTabModule;
  213. }());
  214. exports.DxiTabModule = DxiTabModule;
  215. //# sourceMappingURL=tab-dxi.js.map