@ng-atomic/common 0.0.1

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.
Files changed (206) hide show
  1. package/README.md +7 -0
  2. package/bundles/ng-atomic-common-directives.umd.js +95 -0
  3. package/bundles/ng-atomic-common-directives.umd.js.map +1 -0
  4. package/bundles/ng-atomic-common-directives.umd.min.js +2 -0
  5. package/bundles/ng-atomic-common-directives.umd.min.js.map +1 -0
  6. package/bundles/ng-atomic-common-models.umd.js +11 -0
  7. package/bundles/ng-atomic-common-models.umd.js.map +1 -0
  8. package/bundles/ng-atomic-common-models.umd.min.js +2 -0
  9. package/bundles/ng-atomic-common-models.umd.min.js.map +1 -0
  10. package/bundles/ng-atomic-common-pipes.umd.js +266 -0
  11. package/bundles/ng-atomic-common-pipes.umd.js.map +1 -0
  12. package/bundles/ng-atomic-common-pipes.umd.min.js +2 -0
  13. package/bundles/ng-atomic-common-pipes.umd.min.js.map +1 -0
  14. package/bundles/ng-atomic-common-services.umd.js +429 -0
  15. package/bundles/ng-atomic-common-services.umd.js.map +1 -0
  16. package/bundles/ng-atomic-common-services.umd.min.js +16 -0
  17. package/bundles/ng-atomic-common-services.umd.min.js.map +1 -0
  18. package/bundles/ng-atomic-common-store.umd.js +435 -0
  19. package/bundles/ng-atomic-common-store.umd.js.map +1 -0
  20. package/bundles/ng-atomic-common-store.umd.min.js +16 -0
  21. package/bundles/ng-atomic-common-store.umd.min.js.map +1 -0
  22. package/bundles/ng-atomic-common-utils.umd.js +727 -0
  23. package/bundles/ng-atomic-common-utils.umd.js.map +1 -0
  24. package/bundles/ng-atomic-common-utils.umd.min.js +2 -0
  25. package/bundles/ng-atomic-common-utils.umd.min.js.map +1 -0
  26. package/bundles/ng-atomic-common.umd.js +11 -0
  27. package/bundles/ng-atomic-common.umd.js.map +1 -0
  28. package/bundles/ng-atomic-common.umd.min.js +2 -0
  29. package/bundles/ng-atomic-common.umd.min.js.map +1 -0
  30. package/directives/index.d.ts +1 -0
  31. package/directives/ios-safari-scroll-buggyfill/index.d.ts +2 -0
  32. package/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.directive.d.ts +10 -0
  33. package/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.module.d.ts +8 -0
  34. package/directives/ng-atomic-common-directives.d.ts +5 -0
  35. package/directives/package.json +10 -0
  36. package/esm2015/directives/index.js +2 -0
  37. package/esm2015/directives/index.js.map +1 -0
  38. package/esm2015/directives/ios-safari-scroll-buggyfill/index.js +3 -0
  39. package/esm2015/directives/ios-safari-scroll-buggyfill/index.js.map +1 -0
  40. package/esm2015/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.directive.js +27 -0
  41. package/esm2015/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.directive.js.map +1 -0
  42. package/esm2015/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.module.js +27 -0
  43. package/esm2015/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.module.js.map +1 -0
  44. package/esm2015/directives/ng-atomic-common-directives.js +5 -0
  45. package/esm2015/directives/ng-atomic-common-directives.js.map +1 -0
  46. package/esm2015/index.js +2 -0
  47. package/esm2015/index.js.map +1 -0
  48. package/esm2015/models/action-item.js +2 -0
  49. package/esm2015/models/action-item.js.map +1 -0
  50. package/esm2015/models/index.js +2 -0
  51. package/esm2015/models/index.js.map +1 -0
  52. package/esm2015/models/menu-item.js +2 -0
  53. package/esm2015/models/menu-item.js.map +1 -0
  54. package/esm2015/models/ng-atomic-common-models.js +5 -0
  55. package/esm2015/models/ng-atomic-common-models.js.map +1 -0
  56. package/esm2015/models/public_api.js +3 -0
  57. package/esm2015/models/public_api.js.map +1 -0
  58. package/esm2015/ng-atomic-common.js +5 -0
  59. package/esm2015/ng-atomic-common.js.map +1 -0
  60. package/esm2015/pipes/domain/domain.module.js +27 -0
  61. package/esm2015/pipes/domain/domain.module.js.map +1 -0
  62. package/esm2015/pipes/domain/domain.pipe.js +29 -0
  63. package/esm2015/pipes/domain/domain.pipe.js.map +1 -0
  64. package/esm2015/pipes/domain/index.js +3 -0
  65. package/esm2015/pipes/domain/index.js.map +1 -0
  66. package/esm2015/pipes/index.js +5 -0
  67. package/esm2015/pipes/index.js.map +1 -0
  68. package/esm2015/pipes/ng-atomic-common-pipes.js +5 -0
  69. package/esm2015/pipes/ng-atomic-common-pipes.js.map +1 -0
  70. package/esm2015/pipes/smart-exp/index.js +3 -0
  71. package/esm2015/pipes/smart-exp/index.js.map +1 -0
  72. package/esm2015/pipes/smart-exp/smart-exp.module.js +17 -0
  73. package/esm2015/pipes/smart-exp/smart-exp.module.js.map +1 -0
  74. package/esm2015/pipes/smart-exp/smart-exp.pipe.js +28 -0
  75. package/esm2015/pipes/smart-exp/smart-exp.pipe.js.map +1 -0
  76. package/esm2015/pipes/smart-field/index.js +3 -0
  77. package/esm2015/pipes/smart-field/index.js.map +1 -0
  78. package/esm2015/pipes/smart-field/smart-field.module.js +27 -0
  79. package/esm2015/pipes/smart-field/smart-field.module.js.map +1 -0
  80. package/esm2015/pipes/smart-field/smart-field.pipe.js +33 -0
  81. package/esm2015/pipes/smart-field/smart-field.pipe.js.map +1 -0
  82. package/esm2015/pipes/yen/index.js +3 -0
  83. package/esm2015/pipes/yen/index.js.map +1 -0
  84. package/esm2015/pipes/yen/yen.module.js +27 -0
  85. package/esm2015/pipes/yen/yen.module.js.map +1 -0
  86. package/esm2015/pipes/yen/yen.pipe.js +17 -0
  87. package/esm2015/pipes/yen/yen.pipe.js.map +1 -0
  88. package/esm2015/services/index.js +3 -0
  89. package/esm2015/services/index.js.map +1 -0
  90. package/esm2015/services/loading/index.js +2 -0
  91. package/esm2015/services/loading/index.js.map +1 -0
  92. package/esm2015/services/loading/loading.service.js +32 -0
  93. package/esm2015/services/loading/loading.service.js.map +1 -0
  94. package/esm2015/services/ng-atomic-common-services.js +5 -0
  95. package/esm2015/services/ng-atomic-common-services.js.map +1 -0
  96. package/esm2015/services/snack-bar/index.js +3 -0
  97. package/esm2015/services/snack-bar/index.js.map +1 -0
  98. package/esm2015/services/snack-bar/snack-bar.module.js +25 -0
  99. package/esm2015/services/snack-bar/snack-bar.module.js.map +1 -0
  100. package/esm2015/services/snack-bar/snack-bar.service.js +23 -0
  101. package/esm2015/services/snack-bar/snack-bar.service.js.map +1 -0
  102. package/esm2015/store/entities.page.store.js +30 -0
  103. package/esm2015/store/entities.page.store.js.map +1 -0
  104. package/esm2015/store/entity.page.store.js +41 -0
  105. package/esm2015/store/entity.page.store.js.map +1 -0
  106. package/esm2015/store/index.js +3 -0
  107. package/esm2015/store/index.js.map +1 -0
  108. package/esm2015/store/ng-atomic-common-store.js +5 -0
  109. package/esm2015/store/ng-atomic-common-store.js.map +1 -0
  110. package/esm2015/utils/comma/comma.js +4 -0
  111. package/esm2015/utils/comma/comma.js.map +1 -0
  112. package/esm2015/utils/comma/index.js +2 -0
  113. package/esm2015/utils/comma/index.js.map +1 -0
  114. package/esm2015/utils/compare-by-id/compare-by-id.js +2 -0
  115. package/esm2015/utils/compare-by-id/compare-by-id.js.map +1 -0
  116. package/esm2015/utils/compare-by-id/index.js +2 -0
  117. package/esm2015/utils/compare-by-id/index.js.map +1 -0
  118. package/esm2015/utils/index.js +6 -0
  119. package/esm2015/utils/index.js.map +1 -0
  120. package/esm2015/utils/mat-dayjs-date/dayjs-date.adapter.js +189 -0
  121. package/esm2015/utils/mat-dayjs-date/dayjs-date.adapter.js.map +1 -0
  122. package/esm2015/utils/mat-dayjs-date/dayjs-date.formats.js +15 -0
  123. package/esm2015/utils/mat-dayjs-date/dayjs-date.formats.js.map +1 -0
  124. package/esm2015/utils/mat-dayjs-date/dayjs-date.module.js +42 -0
  125. package/esm2015/utils/mat-dayjs-date/dayjs-date.module.js.map +1 -0
  126. package/esm2015/utils/mat-dayjs-date/dayjs-jp-providers.js +20 -0
  127. package/esm2015/utils/mat-dayjs-date/dayjs-jp-providers.js.map +1 -0
  128. package/esm2015/utils/mat-dayjs-date/index.js +5 -0
  129. package/esm2015/utils/mat-dayjs-date/index.js.map +1 -0
  130. package/esm2015/utils/ng-atomic-common-utils.js +5 -0
  131. package/esm2015/utils/ng-atomic-common-utils.js.map +1 -0
  132. package/esm2015/utils/query/index.js +2 -0
  133. package/esm2015/utils/query/index.js.map +1 -0
  134. package/esm2015/utils/query/query.resolver.js +59 -0
  135. package/esm2015/utils/query/query.resolver.js.map +1 -0
  136. package/esm2015/utils/to-object/index.js +2 -0
  137. package/esm2015/utils/to-object/index.js.map +1 -0
  138. package/esm2015/utils/to-object/to-object.js +10 -0
  139. package/esm2015/utils/to-object/to-object.js.map +1 -0
  140. package/fesm2015/ng-atomic-common-directives.js +58 -0
  141. package/fesm2015/ng-atomic-common-directives.js.map +1 -0
  142. package/fesm2015/ng-atomic-common-models.js +4 -0
  143. package/fesm2015/ng-atomic-common-models.js.map +1 -0
  144. package/fesm2015/ng-atomic-common-pipes.js +191 -0
  145. package/fesm2015/ng-atomic-common-pipes.js.map +1 -0
  146. package/fesm2015/ng-atomic-common-services.js +80 -0
  147. package/fesm2015/ng-atomic-common-services.js.map +1 -0
  148. package/fesm2015/ng-atomic-common-store.js +74 -0
  149. package/fesm2015/ng-atomic-common-store.js.map +1 -0
  150. package/fesm2015/ng-atomic-common-utils.js +340 -0
  151. package/fesm2015/ng-atomic-common-utils.js.map +1 -0
  152. package/fesm2015/ng-atomic-common.js +4 -0
  153. package/fesm2015/ng-atomic-common.js.map +1 -0
  154. package/index.d.ts +1 -0
  155. package/models/action-item.d.ts +6 -0
  156. package/models/index.d.ts +1 -0
  157. package/models/menu-item.d.ts +4 -0
  158. package/models/ng-atomic-common-models.d.ts +5 -0
  159. package/models/package.json +10 -0
  160. package/models/public_api.d.ts +2 -0
  161. package/ng-atomic-common.d.ts +5 -0
  162. package/package.json +21 -0
  163. package/pipes/domain/domain.module.d.ts +8 -0
  164. package/pipes/domain/domain.pipe.d.ts +11 -0
  165. package/pipes/domain/index.d.ts +2 -0
  166. package/pipes/index.d.ts +4 -0
  167. package/pipes/ng-atomic-common-pipes.d.ts +5 -0
  168. package/pipes/package.json +10 -0
  169. package/pipes/smart-exp/index.d.ts +2 -0
  170. package/pipes/smart-exp/smart-exp.module.d.ts +7 -0
  171. package/pipes/smart-exp/smart-exp.pipe.d.ts +7 -0
  172. package/pipes/smart-field/index.d.ts +2 -0
  173. package/pipes/smart-field/smart-field.module.d.ts +8 -0
  174. package/pipes/smart-field/smart-field.pipe.d.ts +31 -0
  175. package/pipes/yen/index.d.ts +2 -0
  176. package/pipes/yen/yen.module.d.ts +8 -0
  177. package/pipes/yen/yen.pipe.d.ts +7 -0
  178. package/services/index.d.ts +2 -0
  179. package/services/loading/index.d.ts +1 -0
  180. package/services/loading/loading.service.d.ts +14 -0
  181. package/services/ng-atomic-common-services.d.ts +5 -0
  182. package/services/package.json +10 -0
  183. package/services/snack-bar/index.d.ts +2 -0
  184. package/services/snack-bar/snack-bar.module.d.ts +8 -0
  185. package/services/snack-bar/snack-bar.service.d.ts +9 -0
  186. package/store/entities.page.store.d.ts +32 -0
  187. package/store/entity.page.store.d.ts +28 -0
  188. package/store/index.d.ts +2 -0
  189. package/store/ng-atomic-common-store.d.ts +5 -0
  190. package/store/package.json +10 -0
  191. package/utils/comma/comma.d.ts +3 -0
  192. package/utils/comma/index.d.ts +1 -0
  193. package/utils/compare-by-id/compare-by-id.d.ts +4 -0
  194. package/utils/compare-by-id/index.d.ts +1 -0
  195. package/utils/index.d.ts +5 -0
  196. package/utils/mat-dayjs-date/dayjs-date.adapter.d.ts +60 -0
  197. package/utils/mat-dayjs-date/dayjs-date.formats.d.ts +5 -0
  198. package/utils/mat-dayjs-date/dayjs-date.module.d.ts +11 -0
  199. package/utils/mat-dayjs-date/dayjs-jp-providers.d.ts +10 -0
  200. package/utils/mat-dayjs-date/index.d.ts +4 -0
  201. package/utils/ng-atomic-common-utils.d.ts +5 -0
  202. package/utils/package.json +10 -0
  203. package/utils/query/index.d.ts +1 -0
  204. package/utils/query/query.resolver.d.ts +1 -0
  205. package/utils/to-object/index.d.ts +1 -0
  206. package/utils/to-object/to-object.d.ts +1 -0
package/README.md ADDED
@@ -0,0 +1,7 @@
1
+ # common
2
+
3
+ This library was generated with [Nx](https://nx.dev).
4
+
5
+ ## Running unit tests
6
+
7
+ Run `nx test common` to execute the unit tests.
@@ -0,0 +1,95 @@
1
+ (function (global, factory) {
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common')) :
3
+ typeof define === 'function' && define.amd ? define('@ng-atomic/common/directives', ['exports', '@angular/core', '@angular/common'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global['ng-atomic'] = global['ng-atomic'] || {}, global['ng-atomic'].common = global['ng-atomic'].common || {}, global['ng-atomic'].common.directives = {}), global.ng.core, global.ng.common));
5
+ }(this, (function (exports, i0, common) { 'use strict';
6
+
7
+ function _interopNamespace(e) {
8
+ if (e && e.__esModule) return e;
9
+ var n = Object.create(null);
10
+ if (e) {
11
+ Object.keys(e).forEach(function (k) {
12
+ if (k !== 'default') {
13
+ var d = Object.getOwnPropertyDescriptor(e, k);
14
+ Object.defineProperty(n, k, d.get ? d : {
15
+ enumerable: true,
16
+ get: function () {
17
+ return e[k];
18
+ }
19
+ });
20
+ }
21
+ });
22
+ }
23
+ n['default'] = e;
24
+ return Object.freeze(n);
25
+ }
26
+
27
+ var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
28
+
29
+ var IosSafariScrollBuggyfillDirective = /** @class */ (function () {
30
+ function IosSafariScrollBuggyfillDirective(el) {
31
+ this.el = el;
32
+ }
33
+ IosSafariScrollBuggyfillDirective.prototype.ngAfterViewInit = function () {
34
+ // this.el.nativeElement.addEventListener('touchmove', (e: Event) => {
35
+ // e.preventDefault();
36
+ // }, {passive: false});
37
+ };
38
+ IosSafariScrollBuggyfillDirective.prototype.onTouchmove = function (event) {
39
+ event.preventDefault();
40
+ };
41
+ return IosSafariScrollBuggyfillDirective;
42
+ }());
43
+ IosSafariScrollBuggyfillDirective.ɵfac = function IosSafariScrollBuggyfillDirective_Factory(t) { return new (t || IosSafariScrollBuggyfillDirective)(i0.ɵɵdirectiveInject(i0.ElementRef)); };
44
+ IosSafariScrollBuggyfillDirective.ɵdir = i0.ɵɵngDeclareDirective({ version: "11.2.14", type: IosSafariScrollBuggyfillDirective, selector: "[iosSafariScrollBuggyfill]", host: { listeners: { "touchmove": "onTouchmove($event)" } }, ngImport: i0__namespace });
45
+ (function () {
46
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(IosSafariScrollBuggyfillDirective, [{
47
+ type: i0.Directive,
48
+ args: [{
49
+ selector: '[iosSafariScrollBuggyfill]'
50
+ }]
51
+ }], function () { return [{ type: i0.ElementRef }]; }, { onTouchmove: [{
52
+ type: i0.HostListener,
53
+ args: ['touchmove', ['$event']]
54
+ }] });
55
+ })();
56
+
57
+ var IosSafariScrollBuggyfillModule = /** @class */ (function () {
58
+ function IosSafariScrollBuggyfillModule() {
59
+ }
60
+ return IosSafariScrollBuggyfillModule;
61
+ }());
62
+ IosSafariScrollBuggyfillModule.ɵfac = function IosSafariScrollBuggyfillModule_Factory(t) { return new (t || IosSafariScrollBuggyfillModule)(); };
63
+ IosSafariScrollBuggyfillModule.ɵmod = i0.ɵɵdefineNgModule({ type: IosSafariScrollBuggyfillModule });
64
+ IosSafariScrollBuggyfillModule.ɵinj = i0.ɵɵdefineInjector({ imports: [[
65
+ common.CommonModule,
66
+ ]] });
67
+ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(IosSafariScrollBuggyfillModule, { declarations: [IosSafariScrollBuggyfillDirective], imports: [common.CommonModule], exports: [IosSafariScrollBuggyfillDirective] }); })();
68
+ (function () {
69
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(IosSafariScrollBuggyfillModule, [{
70
+ type: i0.NgModule,
71
+ args: [{
72
+ declarations: [
73
+ IosSafariScrollBuggyfillDirective,
74
+ ],
75
+ imports: [
76
+ common.CommonModule,
77
+ ],
78
+ exports: [
79
+ IosSafariScrollBuggyfillDirective,
80
+ ]
81
+ }]
82
+ }], null, null);
83
+ })();
84
+
85
+ /**
86
+ * Generated bundle index. Do not edit.
87
+ */
88
+
89
+ exports.IosSafariScrollBuggyfillDirective = IosSafariScrollBuggyfillDirective;
90
+ exports.IosSafariScrollBuggyfillModule = IosSafariScrollBuggyfillModule;
91
+
92
+ Object.defineProperty(exports, '__esModule', { value: true });
93
+
94
+ })));
95
+ //# sourceMappingURL=ng-atomic-common-directives.umd.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ng-atomic-common-directives.umd.js","sources":["../../../../libs/common/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.directive.ts","../../../../libs/common/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.module.ts","../../../../libs/common/directives/ng-atomic-common-directives.ts"],"sourcesContent":["import { AfterViewInit, Directive, ElementRef, HostListener } from '@angular/core';\n\n@Directive({\n selector: '[iosSafariScrollBuggyfill]'\n})\nexport class IosSafariScrollBuggyfillDirective implements AfterViewInit {\n\n constructor(private el: ElementRef) { }\n\n ngAfterViewInit(): void {\n // this.el.nativeElement.addEventListener('touchmove', (e: Event) => {\n // e.preventDefault();\n // }, {passive: false});\n }\n\n @HostListener('touchmove', ['$event'])\n onTouchmove(event: Event) {\n event.preventDefault();\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { IosSafariScrollBuggyfillDirective } from './ios-safari-scroll-buggyfill.directive';\n\n\n\n@NgModule({\n declarations: [\n IosSafariScrollBuggyfillDirective,\n ],\n imports: [\n CommonModule,\n ],\n exports: [\n IosSafariScrollBuggyfillDirective,\n ]\n})\nexport class IosSafariScrollBuggyfillModule { }\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["Directive","HostListener","CommonModule","NgModule"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAOE,2CAAoB,EAAc;YAAd,OAAE,GAAF,EAAE,CAAY;SAAK;QAEvC,2DAAe,GAAf;;;;SAIC;QAGD,uDAAW,GAAX,UAAY,KAAY;YACtB,KAAK,CAAC,cAAc,EAAE,CAAC;SACxB;;;sHAbU,iCAAiC;iGAAjC,iCAAiC;;gFAAjC,iCAAiC;sBAH7CA,YAAS;uBAAC;wBACT,QAAQ,EAAE,4BAA4B;qBACvC;qEAYC,WAAW;0BADVC,eAAY;2BAAC,WAAW,EAAE,CAAC,QAAQ,CAAC;;;;;QCEvC;;;;gHAAa,8BAA8B;sEAA9B,8BAA8B;0EAPhC;gBACPC,mBAAY;aACb;4FAKU,8BAA8B,mBATvC,iCAAiC,aAGjCA,mBAAY,aAGZ,iCAAiC;;gFAGxB,8BAA8B;sBAX1CC,WAAQ;uBAAC;wBACR,YAAY,EAAE;4BACZ,iCAAiC;yBAClC;wBACD,OAAO,EAAE;4BACPD,mBAAY;yBACb;wBACD,OAAO,EAAE;4BACP,iCAAiC;yBAClC;qBACF;;;;IChBD;;;;;;;;;;;;;"}
@@ -0,0 +1,2 @@
1
+ !function(e,o){"object"==typeof exports&&"undefined"!=typeof module?o(exports,require("@angular/core"),require("@angular/common")):"function"==typeof define&&define.amd?define("@ng-atomic/common/directives",["exports","@angular/core","@angular/common"],o):o(((e="undefined"!=typeof globalThis?globalThis:e||self)["ng-atomic"]=e["ng-atomic"]||{},e["ng-atomic"].common=e["ng-atomic"].common||{},e["ng-atomic"].common.directives={}),e.ng.core,e.ng.common)}(this,(function(e,o,t){"use strict";function n(e){if(e&&e.__esModule)return e;var o=Object.create(null);return e&&Object.keys(e).forEach((function(t){if("default"!==t){var n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(o,t,n.get?n:{enumerable:!0,get:function(){return e[t]}})}})),o.default=e,Object.freeze(o)}var r=n(o),i=function(){function e(e){this.el=e}return e.prototype.ngAfterViewInit=function(){},e.prototype.onTouchmove=function(e){e.preventDefault()},e}();i.ɵfac=function(e){return new(e||i)(o.ɵɵdirectiveInject(o.ElementRef))},i.ɵdir=o.ɵɵngDeclareDirective({version:"11.2.14",type:i,selector:"[iosSafariScrollBuggyfill]",host:{listeners:{touchmove:"onTouchmove($event)"}},ngImport:r}),("undefined"==typeof ngDevMode||ngDevMode)&&o.ɵsetClassMetadata(i,[{type:o.Directive,args:[{selector:"[iosSafariScrollBuggyfill]"}]}],(function(){return[{type:o.ElementRef}]}),{onTouchmove:[{type:o.HostListener,args:["touchmove",["$event"]]}]});var c=function(){};c.ɵfac=function(e){return new(e||c)},c.ɵmod=o.ɵɵdefineNgModule({type:c}),c.ɵinj=o.ɵɵdefineInjector({imports:[[t.CommonModule]]}),("undefined"==typeof ngJitMode||ngJitMode)&&o.ɵɵsetNgModuleScope(c,{declarations:[i],imports:[t.CommonModule],exports:[i]}),("undefined"==typeof ngDevMode||ngDevMode)&&o.ɵsetClassMetadata(c,[{type:o.NgModule,args:[{declarations:[i],imports:[t.CommonModule],exports:[i]}]}],null,null),e.IosSafariScrollBuggyfillDirective=i,e.IosSafariScrollBuggyfillModule=c,Object.defineProperty(e,"__esModule",{value:!0})}));
2
+ //# sourceMappingURL=ng-atomic-common-directives.umd.min.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../libs/common/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.directive.ts","../../../../libs/common/directives/ios-safari-scroll-buggyfill/ios-safari-scroll-buggyfill.module.ts"],"names":["IosSafariScrollBuggyfillDirective","el","this","prototype","ngAfterViewInit","onTouchmove","event","preventDefault","i0","ɵɵdirectiveInject","ElementRef","selector","host","listeners","touchmove","ngImport","i0__namespace","Directive","HostListener","IosSafariScrollBuggyfillModule","CommonModule","declarations","imports","exports","NgModule"],"mappings":"gyBAOE,SAAAA,EAAoBC,GAAAC,KAAAD,GAAAA,SAEpBD,EAAAG,UAAAC,gBAAA,aAOAJ,EAAAG,UAAAE,YAAA,SAAYC,GACVA,EAAMC,wDAZGP,GAAiCQ,EAAAC,kBAAAD,EAAAE,oEAAjCV,EAAiCW,SAAA,6BAAAC,KAAA,CAAAC,UAAA,CAAAC,UAAA,wBAAAC,SAAAC,oEAAjChB,EAAiC,CAAA,MAH7CiB,EAAAA,gBAAU,CACTN,SAAU,4EAaVN,YAAW,CAAA,MADVa,EAAAA,mBAAa,YAAa,CAAC,qBCE9B,8CAAaC,oCAAAA,wCAPF,CACPC,EAAAA,kFAMSD,EAA8B,CAAAE,aAAA,CATvCrB,GAAiCsB,QAAA,CAGjCF,EAAAA,cAAYG,QAAA,CAGZvB,qEAGSmB,EAA8B,CAAA,MAX1CK,EAAAA,eAAS,CACRH,aAAc,CACZrB,GAEFsB,QAAS,CACPF,EAAAA,cAEFG,QAAS,CACPvB","sourcesContent":["import { AfterViewInit, Directive, ElementRef, HostListener } from '@angular/core';\n\n@Directive({\n selector: '[iosSafariScrollBuggyfill]'\n})\nexport class IosSafariScrollBuggyfillDirective implements AfterViewInit {\n\n constructor(private el: ElementRef) { }\n\n ngAfterViewInit(): void {\n // this.el.nativeElement.addEventListener('touchmove', (e: Event) => {\n // e.preventDefault();\n // }, {passive: false});\n }\n\n @HostListener('touchmove', ['$event'])\n onTouchmove(event: Event) {\n event.preventDefault();\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { IosSafariScrollBuggyfillDirective } from './ios-safari-scroll-buggyfill.directive';\n\n\n\n@NgModule({\n declarations: [\n IosSafariScrollBuggyfillDirective,\n ],\n imports: [\n CommonModule,\n ],\n exports: [\n IosSafariScrollBuggyfillDirective,\n ]\n})\nexport class IosSafariScrollBuggyfillModule { }\n"]}
@@ -0,0 +1,11 @@
1
+ (function (factory) {
2
+ typeof define === 'function' && define.amd ? define('@ng-atomic/common/models', factory) :
3
+ factory();
4
+ }((function () { 'use strict';
5
+
6
+ /**
7
+ * Generated bundle index. Do not edit.
8
+ */
9
+
10
+ })));
11
+ //# sourceMappingURL=ng-atomic-common-models.umd.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ng-atomic-common-models.umd.js","sources":["../../../../libs/common/models/ng-atomic-common-models.ts"],"sourcesContent":["/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;CAAA;;;;;;;;"}
@@ -0,0 +1,2 @@
1
+ !function(n){"function"==typeof define&&define.amd?define("@ng-atomic/common/models",n):n()}((function(){}));
2
+ //# sourceMappingURL=ng-atomic-common-models.umd.min.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":"","sourcesContent":[]}
@@ -0,0 +1,266 @@
1
+ (function (global, factory) {
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('dayjs'), require('@ng-atomic/common/utils')) :
3
+ typeof define === 'function' && define.amd ? define('@ng-atomic/common/pipes', ['exports', '@angular/core', '@angular/common', 'dayjs', '@ng-atomic/common/utils'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global['ng-atomic'] = global['ng-atomic'] || {}, global['ng-atomic'].common = global['ng-atomic'].common || {}, global['ng-atomic'].common.pipes = {}), global.ng.core, global.ng.common, global.dayjs, global['ng-atomic'].common.utils));
5
+ }(this, (function (exports, i0, common, dayjs, utils) { 'use strict';
6
+
7
+ function _interopNamespace(e) {
8
+ if (e && e.__esModule) return e;
9
+ var n = Object.create(null);
10
+ if (e) {
11
+ Object.keys(e).forEach(function (k) {
12
+ if (k !== 'default') {
13
+ var d = Object.getOwnPropertyDescriptor(e, k);
14
+ Object.defineProperty(n, k, d.get ? d : {
15
+ enumerable: true,
16
+ get: function () {
17
+ return e[k];
18
+ }
19
+ });
20
+ }
21
+ });
22
+ }
23
+ n['default'] = e;
24
+ return Object.freeze(n);
25
+ }
26
+
27
+ var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
28
+
29
+ var DOMAIN_LANG_MAP = new i0.InjectionToken('domain lang map');
30
+ var DomainPipe = /** @class */ (function () {
31
+ function DomainPipe(map) {
32
+ var _a;
33
+ this.map = map;
34
+ (_a = this.map) !== null && _a !== void 0 ? _a : (this.map = {});
35
+ }
36
+ DomainPipe.prototype.transform = function (input) {
37
+ var _a, _b;
38
+ return (_b = (_a = this.map) === null || _a === void 0 ? void 0 : _a[input]) !== null && _b !== void 0 ? _b : input;
39
+ };
40
+ return DomainPipe;
41
+ }());
42
+ DomainPipe.ɵfac = function DomainPipe_Factory(t) { return new (t || DomainPipe)(i0.ɵɵdirectiveInject(DOMAIN_LANG_MAP, 8)); };
43
+ DomainPipe.ɵpipe = i0.ɵɵngDeclarePipe({ version: "11.2.14", ngImport: i0__namespace, type: DomainPipe, name: "D" });
44
+ (function () {
45
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DomainPipe, [{
46
+ type: i0.Pipe,
47
+ args: [{
48
+ name: 'D',
49
+ pure: true,
50
+ }]
51
+ }], function () {
52
+ return [{ type: undefined, decorators: [{
53
+ type: i0.Optional
54
+ }, {
55
+ type: i0.Inject,
56
+ args: [DOMAIN_LANG_MAP]
57
+ }] }];
58
+ }, null);
59
+ })();
60
+
61
+ var DomainModule = /** @class */ (function () {
62
+ function DomainModule() {
63
+ }
64
+ return DomainModule;
65
+ }());
66
+ DomainModule.ɵfac = function DomainModule_Factory(t) { return new (t || DomainModule)(); };
67
+ DomainModule.ɵmod = i0.ɵɵdefineNgModule({ type: DomainModule });
68
+ DomainModule.ɵinj = i0.ɵɵdefineInjector({ imports: [[
69
+ common.CommonModule
70
+ ]] });
71
+ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(DomainModule, { declarations: [DomainPipe], imports: [common.CommonModule], exports: [DomainPipe] }); })();
72
+ (function () {
73
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DomainModule, [{
74
+ type: i0.NgModule,
75
+ args: [{
76
+ declarations: [
77
+ DomainPipe
78
+ ],
79
+ imports: [
80
+ common.CommonModule
81
+ ],
82
+ exports: [
83
+ DomainPipe
84
+ ]
85
+ }]
86
+ }], null, null);
87
+ })();
88
+
89
+ var YenPipe = /** @class */ (function () {
90
+ function YenPipe() {
91
+ }
92
+ YenPipe.prototype.transform = function (value, _unit) {
93
+ return value < 1 ? utils.comma(value * 100) + "%" : utils.comma(value) + "\u5186";
94
+ };
95
+ return YenPipe;
96
+ }());
97
+ YenPipe.ɵfac = function YenPipe_Factory(t) { return new (t || YenPipe)(); };
98
+ YenPipe.ɵpipe = i0.ɵɵngDeclarePipe({ version: "11.2.14", ngImport: i0__namespace, type: YenPipe, name: "yen" });
99
+ (function () {
100
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(YenPipe, [{
101
+ type: i0.Pipe,
102
+ args: [{
103
+ name: 'yen'
104
+ }]
105
+ }], null, null);
106
+ })();
107
+
108
+ var SmartExpPipe = /** @class */ (function () {
109
+ function SmartExpPipe() {
110
+ }
111
+ SmartExpPipe.prototype.transform = function (input, key) {
112
+ if (dayjs.isDayjs(input)) {
113
+ return input.format('YY/MM/DD');
114
+ }
115
+ else if (Array.isArray(input)) {
116
+ return input.length + "\u500B\u306E\u30A2\u30A4\u30C6\u30E0";
117
+ }
118
+ else if (typeof input === 'number' && input > 10000) {
119
+ return new YenPipe().transform(input);
120
+ }
121
+ return input;
122
+ };
123
+ return SmartExpPipe;
124
+ }());
125
+ SmartExpPipe.ɵfac = function SmartExpPipe_Factory(t) { return new (t || SmartExpPipe)(); };
126
+ SmartExpPipe.ɵpipe = i0.ɵɵngDeclarePipe({ version: "11.2.14", ngImport: i0__namespace, type: SmartExpPipe, name: "smartExp" });
127
+ (function () {
128
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SmartExpPipe, [{
129
+ type: i0.Pipe,
130
+ args: [{
131
+ name: 'smartExp',
132
+ pure: true,
133
+ }]
134
+ }], null, null);
135
+ })();
136
+
137
+ var SmartExpModule = /** @class */ (function () {
138
+ function SmartExpModule() {
139
+ }
140
+ return SmartExpModule;
141
+ }());
142
+ SmartExpModule.ɵfac = function SmartExpModule_Factory(t) { return new (t || SmartExpModule)(); };
143
+ SmartExpModule.ɵmod = i0.ɵɵdefineNgModule({ type: SmartExpModule });
144
+ SmartExpModule.ɵinj = i0.ɵɵdefineInjector({});
145
+ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(SmartExpModule, { declarations: [SmartExpPipe], exports: [SmartExpPipe] }); })();
146
+ (function () {
147
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SmartExpModule, [{
148
+ type: i0.NgModule,
149
+ args: [{
150
+ declarations: [SmartExpPipe],
151
+ exports: [SmartExpPipe]
152
+ }]
153
+ }], null, null);
154
+ })();
155
+
156
+ var FORM_FIELD_MAP = new i0.InjectionToken('[@ng-atomic] Smart Form Field');
157
+ var SmartFieldPipe = /** @class */ (function () {
158
+ function SmartFieldPipe(map) {
159
+ var _a;
160
+ this.map = map;
161
+ (_a = this.map) !== null && _a !== void 0 ? _a : (this.map = {
162
+ createdAt: { type: 'date' },
163
+ updatedAt: { type: 'date' },
164
+ deletedAt: { type: 'date' },
165
+ });
166
+ }
167
+ SmartFieldPipe.prototype.transform = function (key) {
168
+ var _a;
169
+ return (_a = this.map[key]) !== null && _a !== void 0 ? _a : { type: 'input' };
170
+ };
171
+ return SmartFieldPipe;
172
+ }());
173
+ SmartFieldPipe.ɵfac = function SmartFieldPipe_Factory(t) { return new (t || SmartFieldPipe)(i0.ɵɵdirectiveInject(FORM_FIELD_MAP, 8)); };
174
+ SmartFieldPipe.ɵpipe = i0.ɵɵngDeclarePipe({ version: "11.2.14", ngImport: i0__namespace, type: SmartFieldPipe, name: "smartField" });
175
+ (function () {
176
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SmartFieldPipe, [{
177
+ type: i0.Pipe,
178
+ args: [{
179
+ name: 'smartField',
180
+ pure: true,
181
+ }]
182
+ }], function () {
183
+ return [{ type: undefined, decorators: [{
184
+ type: i0.Optional
185
+ }, {
186
+ type: i0.Inject,
187
+ args: [FORM_FIELD_MAP]
188
+ }] }];
189
+ }, null);
190
+ })();
191
+
192
+ var SmartFieldModule = /** @class */ (function () {
193
+ function SmartFieldModule() {
194
+ }
195
+ return SmartFieldModule;
196
+ }());
197
+ SmartFieldModule.ɵfac = function SmartFieldModule_Factory(t) { return new (t || SmartFieldModule)(); };
198
+ SmartFieldModule.ɵmod = i0.ɵɵdefineNgModule({ type: SmartFieldModule });
199
+ SmartFieldModule.ɵinj = i0.ɵɵdefineInjector({ imports: [[
200
+ common.CommonModule
201
+ ]] });
202
+ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(SmartFieldModule, { declarations: [SmartFieldPipe], imports: [common.CommonModule], exports: [SmartFieldPipe] }); })();
203
+ (function () {
204
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SmartFieldModule, [{
205
+ type: i0.NgModule,
206
+ args: [{
207
+ declarations: [
208
+ SmartFieldPipe
209
+ ],
210
+ imports: [
211
+ common.CommonModule
212
+ ],
213
+ exports: [
214
+ SmartFieldPipe
215
+ ]
216
+ }]
217
+ }], null, null);
218
+ })();
219
+
220
+ var YenModule = /** @class */ (function () {
221
+ function YenModule() {
222
+ }
223
+ return YenModule;
224
+ }());
225
+ YenModule.ɵfac = function YenModule_Factory(t) { return new (t || YenModule)(); };
226
+ YenModule.ɵmod = i0.ɵɵdefineNgModule({ type: YenModule });
227
+ YenModule.ɵinj = i0.ɵɵdefineInjector({ imports: [[
228
+ common.CommonModule
229
+ ]] });
230
+ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(YenModule, { declarations: [YenPipe], imports: [common.CommonModule], exports: [YenPipe] }); })();
231
+ (function () {
232
+ (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(YenModule, [{
233
+ type: i0.NgModule,
234
+ args: [{
235
+ declarations: [
236
+ YenPipe
237
+ ],
238
+ imports: [
239
+ common.CommonModule
240
+ ],
241
+ exports: [
242
+ YenPipe
243
+ ]
244
+ }]
245
+ }], null, null);
246
+ })();
247
+
248
+ /**
249
+ * Generated bundle index. Do not edit.
250
+ */
251
+
252
+ exports.DOMAIN_LANG_MAP = DOMAIN_LANG_MAP;
253
+ exports.DomainModule = DomainModule;
254
+ exports.DomainPipe = DomainPipe;
255
+ exports.FORM_FIELD_MAP = FORM_FIELD_MAP;
256
+ exports.SmartExpModule = SmartExpModule;
257
+ exports.SmartExpPipe = SmartExpPipe;
258
+ exports.SmartFieldModule = SmartFieldModule;
259
+ exports.SmartFieldPipe = SmartFieldPipe;
260
+ exports.YenModule = YenModule;
261
+ exports.YenPipe = YenPipe;
262
+
263
+ Object.defineProperty(exports, '__esModule', { value: true });
264
+
265
+ })));
266
+ //# sourceMappingURL=ng-atomic-common-pipes.umd.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ng-atomic-common-pipes.umd.js","sources":["../../../../libs/common/pipes/domain/domain.pipe.ts","../../../../libs/common/pipes/domain/domain.module.ts","../../../../libs/common/pipes/yen/yen.pipe.ts","../../../../libs/common/pipes/smart-exp/smart-exp.pipe.ts","../../../../libs/common/pipes/smart-exp/smart-exp.module.ts","../../../../libs/common/pipes/smart-field/smart-field.pipe.ts","../../../../libs/common/pipes/smart-field/smart-field.module.ts","../../../../libs/common/pipes/yen/yen.module.ts","../../../../libs/common/pipes/ng-atomic-common-pipes.ts"],"sourcesContent":["import { Inject, InjectionToken, Optional, Pipe } from '@angular/core';\n\nexport type DomainLangMap = Record<string, string>;\nexport const DOMAIN_LANG_MAP = new InjectionToken<DomainLangMap>('domain lang map');\n\n@Pipe({\n name: 'D',\n pure: true,\n})\nexport class DomainPipe {\n constructor(@Optional() @Inject(DOMAIN_LANG_MAP) private map: DomainLangMap) {\n this.map ??= {};\n }\n\n transform(input: string) {\n return this.map?.[input] ?? input;\n }\n}\n\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { DomainPipe } from './domain.pipe';\n\n\n\n@NgModule({\n declarations: [\n DomainPipe\n ],\n imports: [\n CommonModule\n ],\n exports: [\n DomainPipe\n ]\n})\nexport class DomainModule { }\n","import { Pipe, PipeTransform } from '@angular/core';\nimport { comma } from '@ng-atomic/common/utils';\n\n@Pipe({\n name: 'yen'\n})\nexport class YenPipe implements PipeTransform {\n\n transform(value: number, _unit?: string): string {\n return value < 1 ? `${comma(value * 100)}%` : `${comma(value)}円`;\n }\n\n}\n","import { Pipe } from '@angular/core';\nimport * as dayjs from 'dayjs';\nimport { YenPipe } from '../yen/yen.pipe';\n\n@Pipe({\n name: 'smartExp',\n pure: true,\n})\nexport class SmartExpPipe {\n transform(input: string | number | dayjs.Dayjs | any, key?: string): string {\n if (dayjs.isDayjs(input)) {\n return input.format('YY/MM/DD');\n } else if (Array.isArray(input)) {\n return `${input.length}個のアイテム`;\n } else if (typeof input === 'number' && input > 10_000) {\n return new YenPipe().transform(input);\n }\n return input;\n }\n}","import { NgModule } from \"@angular/core\";\nimport { SmartExpPipe } from \"./smart-exp.pipe\";\n\n@NgModule({\n declarations: [SmartExpPipe],\n exports: [SmartExpPipe]\n})\nexport class SmartExpModule { }","import { Inject, InjectionToken, Optional, Pipe, PipeTransform } from '@angular/core';\n\ninterface Option<T> {\n name: string;\n value: T;\n}\n\ninterface InputField {\n type: 'input';\n}\n\ninterface DateInputField {\n type: 'date';\n}\n\ninterface SelectField<T> {\n type: 'select';\n options: Option<T>[];\n}\n\ninterface MultiSelectField<T> {\n type: 'multi-select';\n options: Option<T>[];\n}\n\ntype FormField<V> = InputField\n | DateInputField\n | SelectField<V>\n | MultiSelectField<V>;\n\nexport type FormFieldMap = Record<string, FormField<any>>;\n\nexport const FORM_FIELD_MAP = new InjectionToken<FormFieldMap>('[@ng-atomic] Smart Form Field');\n\n@Pipe({\n name: 'smartField',\n pure: true,\n})\nexport class SmartFieldPipe implements PipeTransform {\n\n constructor(\n @Optional() @Inject(FORM_FIELD_MAP) private map: Record<string, FormField<any>>\n ) {\n this.map ??= {\n createdAt: { type: 'date' },\n updatedAt: { type: 'date' },\n deletedAt: { type: 'date' },\n };\n }\n\n transform(key: string): FormField<any> {\n return this.map[key] ?? {type: 'input'};\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { SmartFieldPipe } from './smart-field.pipe';\n\n\n\n@NgModule({\n declarations: [\n SmartFieldPipe\n ],\n imports: [\n CommonModule\n ],\n exports: [\n SmartFieldPipe\n ]\n})\nexport class SmartFieldModule { }\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { YenPipe } from './yen.pipe';\n\n\n\n@NgModule({\n declarations: [\n YenPipe\n ],\n imports: [\n CommonModule\n ],\n exports: [\n YenPipe\n ]\n})\nexport class YenModule { }\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["InjectionToken","Pipe","Optional","Inject","CommonModule","NgModule","comma","dayjs.isDayjs"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;QAGa,eAAe,GAAG,IAAIA,iBAAc,CAAgB,iBAAiB,EAAE;;QAOlF,oBAAyD,GAAkB;;YAAlB,QAAG,GAAH,GAAG,CAAe;YACzE,MAAA,IAAI,CAAC,GAAG,oCAAR,IAAI,CAAC,GAAG,GAAK,EAAE,EAAC;SACjB;QAED,8BAAS,GAAT,UAAU,KAAa;;YACrB,mBAAO,IAAI,CAAC,GAAG,0CAAG,KAAK,oCAAK,KAAK,CAAC;SACnC;;;wEAPU,UAAU,uBACW,eAAe;+FADpC,UAAU;;gFAAV,UAAU;sBAJtBC,OAAI;uBAAC;wBACJ,IAAI,EAAE,GAAG;wBACT,IAAI,EAAE,IAAI;qBACX;;;kCAEcC,WAAQ;;kCAAI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wBACR,YAAY,EAAE;4BACZ,OAAO;yBACR;wBACD,OAAO,EAAE;4BACPD,mBAAY;yBACb;wBACD,OAAO,EAAE;4BACP,OAAO;yBACR;qBACF;;;;IChBD;;;;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,2 @@
1
+ !function(e,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports,require("@angular/core"),require("@angular/common"),require("dayjs"),require("@ng-atomic/common/utils")):"function"==typeof define&&define.amd?define("@ng-atomic/common/pipes",["exports","@angular/core","@angular/common","dayjs","@ng-atomic/common/utils"],n):n(((e="undefined"!=typeof globalThis?globalThis:e||self)["ng-atomic"]=e["ng-atomic"]||{},e["ng-atomic"].common=e["ng-atomic"].common||{},e["ng-atomic"].common.pipes={}),e.ng.core,e.ng.common,e.dayjs,e["ng-atomic"].common.utils)}(this,(function(e,n,t,o,r){"use strict";function i(e){if(e&&e.__esModule)return e;var n=Object.create(null);return e&&Object.keys(e).forEach((function(t){if("default"!==t){var o=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,o.get?o:{enumerable:!0,get:function(){return e[t]}})}})),n.default=e,Object.freeze(n)}var a=i(n),d=new n.InjectionToken("domain lang map"),u=function(){function e(e){var n;this.map=e,null!==(n=this.map)&&void 0!==n||(this.map={})}return e.prototype.transform=function(e){var n,t;return null!==(t=null===(n=this.map)||void 0===n?void 0:n[e])&&void 0!==t?t:e},e}();u.ɵfac=function(e){return new(e||u)(n.ɵɵdirectiveInject(d,8))},u.ɵpipe=n.ɵɵngDeclarePipe({version:"11.2.14",ngImport:a,type:u,name:"D"}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(u,[{type:n.Pipe,args:[{name:"D",pure:!0}]}],(function(){return[{type:void 0,decorators:[{type:n.Optional},{type:n.Inject,args:[d]}]}]}),null);var p=function(){};p.ɵfac=function(e){return new(e||p)},p.ɵmod=n.ɵɵdefineNgModule({type:p}),p.ɵinj=n.ɵɵdefineInjector({imports:[[t.CommonModule]]}),("undefined"==typeof ngJitMode||ngJitMode)&&n.ɵɵsetNgModuleScope(p,{declarations:[u],imports:[t.CommonModule],exports:[u]}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(p,[{type:n.NgModule,args:[{declarations:[u],imports:[t.CommonModule],exports:[u]}]}],null,null);var l=function(){function e(){}return e.prototype.transform=function(e,n){return e<1?r.comma(100*e)+"%":r.comma(e)+"円"},e}();l.ɵfac=function(e){return new(e||l)},l.ɵpipe=n.ɵɵngDeclarePipe({version:"11.2.14",ngImport:a,type:l,name:"yen"}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(l,[{type:n.Pipe,args:[{name:"yen"}]}],null,null);var s=function(){function e(){}return e.prototype.transform=function(e,n){return o.isDayjs(e)?e.format("YY/MM/DD"):Array.isArray(e)?e.length+"個のアイテム":"number"==typeof e&&e>1e4?(new l).transform(e):e},e}();s.ɵfac=function(e){return new(e||s)},s.ɵpipe=n.ɵɵngDeclarePipe({version:"11.2.14",ngImport:a,type:s,name:"smartExp"}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(s,[{type:n.Pipe,args:[{name:"smartExp",pure:!0}]}],null,null);var m=function(){};m.ɵfac=function(e){return new(e||m)},m.ɵmod=n.ɵɵdefineNgModule({type:m}),m.ɵinj=n.ɵɵdefineInjector({}),("undefined"==typeof ngJitMode||ngJitMode)&&n.ɵɵsetNgModuleScope(m,{declarations:[s],exports:[s]}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(m,[{type:n.NgModule,args:[{declarations:[s],exports:[s]}]}],null,null);var c=new n.InjectionToken("[@ng-atomic] Smart Form Field"),f=function(){function e(e){var n;this.map=e,null!==(n=this.map)&&void 0!==n||(this.map={createdAt:{type:"date"},updatedAt:{type:"date"},deletedAt:{type:"date"}})}return e.prototype.transform=function(e){var n;return null!==(n=this.map[e])&&void 0!==n?n:{type:"input"}},e}();f.ɵfac=function(e){return new(e||f)(n.ɵɵdirectiveInject(c,8))},f.ɵpipe=n.ɵɵngDeclarePipe({version:"11.2.14",ngImport:a,type:f,name:"smartField"}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(f,[{type:n.Pipe,args:[{name:"smartField",pure:!0}]}],(function(){return[{type:void 0,decorators:[{type:n.Optional},{type:n.Inject,args:[c]}]}]}),null);var g=function(){};g.ɵfac=function(e){return new(e||g)},g.ɵmod=n.ɵɵdefineNgModule({type:g}),g.ɵinj=n.ɵɵdefineInjector({imports:[[t.CommonModule]]}),("undefined"==typeof ngJitMode||ngJitMode)&&n.ɵɵsetNgModuleScope(g,{declarations:[f],imports:[t.CommonModule],exports:[f]}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(g,[{type:n.NgModule,args:[{declarations:[f],imports:[t.CommonModule],exports:[f]}]}],null,null);var M=function(){};M.ɵfac=function(e){return new(e||M)},M.ɵmod=n.ɵɵdefineNgModule({type:M}),M.ɵinj=n.ɵɵdefineInjector({imports:[[t.CommonModule]]}),("undefined"==typeof ngJitMode||ngJitMode)&&n.ɵɵsetNgModuleScope(M,{declarations:[l],imports:[t.CommonModule],exports:[l]}),("undefined"==typeof ngDevMode||ngDevMode)&&n.ɵsetClassMetadata(M,[{type:n.NgModule,args:[{declarations:[l],imports:[t.CommonModule],exports:[l]}]}],null,null),e.DOMAIN_LANG_MAP=d,e.DomainModule=p,e.DomainPipe=u,e.FORM_FIELD_MAP=c,e.SmartExpModule=m,e.SmartExpPipe=s,e.SmartFieldModule=g,e.SmartFieldPipe=f,e.YenModule=M,e.YenPipe=l,Object.defineProperty(e,"__esModule",{value:!0})}));
2
+ //# sourceMappingURL=ng-atomic-common-pipes.umd.min.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../../libs/common/pipes/domain/domain.pipe.ts","../../../../libs/common/pipes/domain/domain.module.ts","../../../../libs/common/pipes/yen/yen.pipe.ts","../../../../libs/common/pipes/smart-exp/smart-exp.pipe.ts","../../../../libs/common/pipes/smart-exp/smart-exp.module.ts","../../../../libs/common/pipes/smart-field/smart-field.pipe.ts","../../../../libs/common/pipes/smart-field/smart-field.module.ts","../../../../libs/common/pipes/yen/yen.module.ts"],"names":["DOMAIN_LANG_MAP","InjectionToken","DomainPipe","map","this","_a","prototype","transform","input","_b","i0","ɵɵdirectiveInject","name","Pipe","pure","Optional","Inject","DomainModule","CommonModule","declarations","imports","exports","NgModule","YenPipe","value","_unit","comma","SmartExpPipe","key","dayjs.isDayjs","format","Array","isArray","length","SmartExpModule","FORM_FIELD_MAP","SmartFieldPipe","createdAt","type","updatedAt","deletedAt","SmartFieldModule","YenModule"],"mappings":"u4BAGaA,EAAkB,IAAIC,EAAAA,eAA8B,gCAO/D,SAAAC,EAAyDC,SAAAC,KAAAD,IAAAA,EAC/C,QAARE,EAAAD,KAAKD,WAAG,IAAAE,IAARD,KAAKD,IAAQ,WAGfD,EAAAI,UAAAC,UAAA,SAAUC,WACR,OAAuB,QAAvBC,EAAe,QAAfJ,EAAOD,KAAKD,WAAG,IAAAE,OAAA,EAAAA,EAAGG,UAAK,IAAAC,EAAAA,EAAKD,yCANnBN,GAAUQ,EAAAC,kBACWX,EAAe,kEADpCE,EAAUU,KAAA,sEAAVV,EAAU,CAAA,MAJtBW,EAAAA,WAAK,CACJD,KAAM,IACNE,MAAM,wDAGOC,EAAAA,gBAAYC,EAAAA,aAAOhB,qBCOlC,8CAAaiB,oCAAAA,wCAPF,CACPC,EAAAA,kFAMSD,EAAY,CAAAE,aAAA,CATrBjB,GAAUkB,QAAA,CAGVF,EAAAA,cAAYG,QAAA,CAGZnB,qEAGSe,EAAY,CAAA,MAXxBK,EAAAA,eAAS,CACRH,aAAc,CACZjB,GAEFkB,QAAS,CACPF,EAAAA,cAEFG,QAAS,CACPnB,mCCRJ,SAAAqB,YAEEA,EAAAjB,UAAAC,UAAA,SAAUiB,EAAeC,GACvB,OAAOD,EAAQ,EAAOE,EAAAA,MAAc,IA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,EAAAA,cAAYG,QAAA,CAGZe,qEAGSK,EAAgB,CAAA,MAX5BnB,EAAAA,eAAS,CACRH,aAAc,CACZiB,GAEFhB,QAAS,CACPF,EAAAA,cAEFG,QAAS,CACPe,wBCGJ,8CAAaM,oCAAAA,wCAPF,CACPxB,EAAAA,kFAMSwB,EAAS,CAAAvB,aAAA,CATlBI,GAAOH,QAAA,CAGPF,EAAAA,cAAYG,QAAA,CAGZE,qEAGSmB,EAAS,CAAA,MAXrBpB,EAAAA,eAAS,CACRH,aAAc,CACZI,GAEFH,QAAS,CACPF,EAAAA,cAEFG,QAAS,CACPE","sourcesContent":["import { Inject, InjectionToken, Optional, Pipe } from '@angular/core';\n\nexport type DomainLangMap = Record<string, string>;\nexport const DOMAIN_LANG_MAP = new InjectionToken<DomainLangMap>('domain lang map');\n\n@Pipe({\n name: 'D',\n pure: true,\n})\nexport class DomainPipe {\n constructor(@Optional() @Inject(DOMAIN_LANG_MAP) private map: DomainLangMap) {\n this.map ??= {};\n }\n\n transform(input: string) {\n return this.map?.[input] ?? input;\n }\n}\n\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { DomainPipe } from './domain.pipe';\n\n\n\n@NgModule({\n declarations: [\n DomainPipe\n ],\n imports: [\n CommonModule\n ],\n exports: [\n DomainPipe\n ]\n})\nexport class DomainModule { }\n","import { Pipe, PipeTransform } from '@angular/core';\nimport { comma } from '@ng-atomic/common/utils';\n\n@Pipe({\n name: 'yen'\n})\nexport class YenPipe implements PipeTransform {\n\n transform(value: number, _unit?: string): string {\n return value < 1 ? `${comma(value * 100)}%` : `${comma(value)}円`;\n }\n\n}\n","import { Pipe } from '@angular/core';\nimport * as dayjs from 'dayjs';\nimport { YenPipe } from '../yen/yen.pipe';\n\n@Pipe({\n name: 'smartExp',\n pure: true,\n})\nexport class SmartExpPipe {\n transform(input: string | number | dayjs.Dayjs | any, key?: string): string {\n if (dayjs.isDayjs(input)) {\n return input.format('YY/MM/DD');\n } else if (Array.isArray(input)) {\n return `${input.length}個のアイテム`;\n } else if (typeof input === 'number' && input > 10_000) {\n return new YenPipe().transform(input);\n }\n return input;\n }\n}","import { NgModule } from \"@angular/core\";\nimport { SmartExpPipe } from \"./smart-exp.pipe\";\n\n@NgModule({\n declarations: [SmartExpPipe],\n exports: [SmartExpPipe]\n})\nexport class SmartExpModule { }","import { Inject, InjectionToken, Optional, Pipe, PipeTransform } from '@angular/core';\n\ninterface Option<T> {\n name: string;\n value: T;\n}\n\ninterface InputField {\n type: 'input';\n}\n\ninterface DateInputField {\n type: 'date';\n}\n\ninterface SelectField<T> {\n type: 'select';\n options: Option<T>[];\n}\n\ninterface MultiSelectField<T> {\n type: 'multi-select';\n options: Option<T>[];\n}\n\ntype FormField<V> = InputField\n | DateInputField\n | SelectField<V>\n | MultiSelectField<V>;\n\nexport type FormFieldMap = Record<string, FormField<any>>;\n\nexport const FORM_FIELD_MAP = new InjectionToken<FormFieldMap>('[@ng-atomic] Smart Form Field');\n\n@Pipe({\n name: 'smartField',\n pure: true,\n})\nexport class SmartFieldPipe implements PipeTransform {\n\n constructor(\n @Optional() @Inject(FORM_FIELD_MAP) private map: Record<string, FormField<any>>\n ) {\n this.map ??= {\n createdAt: { type: 'date' },\n updatedAt: { type: 'date' },\n deletedAt: { type: 'date' },\n };\n }\n\n transform(key: string): FormField<any> {\n return this.map[key] ?? {type: 'input'};\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { SmartFieldPipe } from './smart-field.pipe';\n\n\n\n@NgModule({\n declarations: [\n SmartFieldPipe\n ],\n imports: [\n CommonModule\n ],\n exports: [\n SmartFieldPipe\n ]\n})\nexport class SmartFieldModule { }\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { YenPipe } from './yen.pipe';\n\n\n\n@NgModule({\n declarations: [\n YenPipe\n ],\n imports: [\n CommonModule\n ],\n exports: [\n YenPipe\n ]\n})\nexport class YenModule { }\n"]}