@duetds/cli 2.6.13 → 2.7.0

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 (249) hide show
  1. package/package.json +7 -8
  2. package/src/index.js +21 -0
  3. package/src/main.js +19 -19
  4. package/templates/angular/12.2.16/.browserlistrc +16 -0
  5. package/templates/angular/12.2.16/.depcheckrc +2 -0
  6. package/templates/angular/12.2.16/.editorconfig +16 -0
  7. package/templates/angular/12.2.16/.eslintrc.json +51 -0
  8. package/templates/angular/{.prettierignore → 12.2.16/.prettierignore} +0 -0
  9. package/templates/angular/12.2.16/.prettierrc +14 -0
  10. package/templates/angular/12.2.16/LICENSE.md +29 -0
  11. package/templates/angular/{README.md → 12.2.16/README.md} +5 -3
  12. package/templates/angular/{angular.json → 12.2.16/angular.json} +15 -4
  13. package/templates/angular/12.2.16/config/jest.base.ts +17 -0
  14. package/templates/angular/12.2.16/config/jest.setup.ts +24 -0
  15. package/templates/angular/12.2.16/package.file +58 -0
  16. package/templates/angular/12.2.16/playwright.config.ts +26 -0
  17. package/templates/angular/12.2.16/src/app/agreement.model.ts +3 -0
  18. package/templates/angular/12.2.16/src/app/app-routing.module.ts +11 -0
  19. package/templates/angular/{src → 12.2.16/src}/app/app.component.html +0 -0
  20. package/templates/angular/{src → 12.2.16/src}/app/app.component.scss +0 -0
  21. package/templates/angular/{src → 12.2.16/src}/app/app.component.ts +1 -1
  22. package/templates/angular/{src → 12.2.16/src}/app/app.module.ts +5 -11
  23. package/templates/angular/12.2.16/src/app/currency-formatter.service.ts +12 -0
  24. package/templates/angular/12.2.16/src/app/footer/footer.component.html +22 -0
  25. package/templates/angular/{src → 12.2.16/src}/app/footer/footer.component.scss +0 -0
  26. package/templates/angular/{src → 12.2.16/src}/app/footer/footer.component.ts +1 -1
  27. package/templates/angular/12.2.16/src/app/header/header.component.html +1 -0
  28. package/templates/angular/{src/app/index-page/index-page.component.scss → 12.2.16/src/app/header/header.component.scss} +0 -0
  29. package/templates/angular/12.2.16/src/app/header/header.component.ts +10 -0
  30. package/templates/angular/12.2.16/src/app/index-page/index-page.component.html +49 -0
  31. package/templates/angular/{src/app/injuries-page/injuries-page.component.scss → 12.2.16/src/app/index-page/index-page.component.scss} +0 -0
  32. package/templates/angular/12.2.16/src/app/index-page/index-page.component.ts +61 -0
  33. package/templates/angular/12.2.16/src/app/investment-amount/investment-amount.component.html +87 -0
  34. package/templates/angular/{src/app/insurance-page/insurance-page.component.scss → 12.2.16/src/app/investment-amount/investment-amount.component.scss} +0 -0
  35. package/templates/angular/12.2.16/src/app/investment-amount/investment-amount.component.ts +31 -0
  36. package/templates/angular/12.2.16/src/app/investment-origin/investment-origin.component.html +12 -0
  37. package/templates/angular/{src/assets/.gitkeep → 12.2.16/src/app/investment-origin/investment-origin.component.scss} +0 -0
  38. package/templates/angular/12.2.16/src/app/investment-origin/investment-origin.component.ts +24 -0
  39. package/templates/angular/12.2.16/src/app/summary/summary.component.html +74 -0
  40. package/templates/angular/12.2.16/src/app/summary/summary.component.scss +0 -0
  41. package/templates/angular/12.2.16/src/app/summary/summary.component.ts +16 -0
  42. package/templates/angular/12.2.16/src/assets/.gitkeep +0 -0
  43. package/templates/angular/{src → 12.2.16/src}/assets/img/android-chrome-192x192.png +0 -0
  44. package/templates/angular/{src → 12.2.16/src}/assets/img/apple-touch-icon-180x180.png +0 -0
  45. package/templates/angular/{src → 12.2.16/src}/assets/img/splash-screen-icon-512x512.png +0 -0
  46. package/templates/angular/{src → 12.2.16/src}/environments/environment.prod.ts +1 -1
  47. package/templates/angular/{src → 12.2.16/src}/environments/environment.ts +1 -1
  48. package/templates/angular/{src → 12.2.16/src}/favicon.ico +0 -0
  49. package/templates/angular/{src → 12.2.16/src}/index.html +1 -1
  50. package/templates/angular/{src → 12.2.16/src}/main.ts +0 -0
  51. package/templates/angular/{src → 12.2.16/src}/manifest.json +0 -0
  52. package/templates/angular/{src → 12.2.16/src}/polyfills.ts +0 -0
  53. package/templates/angular/{src → 12.2.16/src}/styles.scss +0 -0
  54. package/templates/angular/12.2.16/src/tests/app.test.ts +13 -0
  55. package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts +54 -0
  56. package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-1-chromium-darwin.png +0 -0
  57. package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-2-chromium-darwin.png +0 -0
  58. package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-3-chromium-darwin.png +0 -0
  59. package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-4-chromium-darwin.png +0 -0
  60. package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-5-chromium-darwin.png +0 -0
  61. package/templates/angular/12.2.16/src/tests/playwright/playwright.test.ts-snapshots/code-chromium-darwin.json +16 -0
  62. package/templates/angular/12.2.16/src/utils/string.utils.ts +1 -0
  63. package/templates/angular/{tsconfig.app.json → 12.2.16/tsconfig.app.json} +0 -1
  64. package/templates/angular/{tsconfig.base.json → 12.2.16/tsconfig.base.json} +1 -1
  65. package/templates/angular/12.2.16/tsconfig.json +8 -0
  66. package/templates/angular/12.2.16/tsconfig.spec.json +15 -0
  67. package/templates/angular/{tslint.json → 12.2.16/tslint.json} +0 -0
  68. package/templates/angular/13.2.4/.browserlistrc +16 -0
  69. package/templates/angular/13.2.4/.depcheckrc +2 -0
  70. package/templates/angular/13.2.4/.editorconfig +16 -0
  71. package/templates/angular/13.2.4/.eslintrc.json +51 -0
  72. package/templates/{html → angular/13.2.4}/.prettierignore +0 -0
  73. package/templates/angular/13.2.4/.prettierrc +14 -0
  74. package/templates/angular/13.2.4/LICENSE.md +29 -0
  75. package/templates/angular/13.2.4/README.md +32 -0
  76. package/templates/angular/13.2.4/angular.json +122 -0
  77. package/templates/angular/13.2.4/config/jest.base.ts +17 -0
  78. package/templates/angular/13.2.4/config/jest.setup.ts +24 -0
  79. package/templates/angular/13.2.4/package.file +59 -0
  80. package/templates/angular/13.2.4/playwright.config.ts +26 -0
  81. package/templates/angular/13.2.4/src/app/agreement.model.ts +3 -0
  82. package/templates/angular/13.2.4/src/app/app-routing.module.ts +11 -0
  83. package/templates/angular/13.2.4/src/app/app.component.html +5 -0
  84. package/templates/angular/13.2.4/src/app/app.component.scss +0 -0
  85. package/templates/angular/13.2.4/src/app/app.component.ts +10 -0
  86. package/templates/angular/13.2.4/src/app/app.module.ts +21 -0
  87. package/templates/angular/13.2.4/src/app/currency-formatter.service.ts +12 -0
  88. package/templates/angular/13.2.4/src/app/footer/footer.component.html +22 -0
  89. package/templates/angular/13.2.4/src/app/footer/footer.component.scss +0 -0
  90. package/templates/angular/13.2.4/src/app/footer/footer.component.ts +10 -0
  91. package/templates/angular/13.2.4/src/app/header/header.component.html +1 -0
  92. package/templates/angular/13.2.4/src/app/header/header.component.scss +0 -0
  93. package/templates/angular/13.2.4/src/app/header/header.component.ts +10 -0
  94. package/templates/angular/13.2.4/src/app/index-page/index-page.component.html +49 -0
  95. package/templates/angular/13.2.4/src/app/index-page/index-page.component.scss +0 -0
  96. package/templates/angular/13.2.4/src/app/index-page/index-page.component.ts +61 -0
  97. package/templates/angular/13.2.4/src/app/investment-amount/investment-amount.component.html +87 -0
  98. package/templates/angular/13.2.4/src/app/investment-amount/investment-amount.component.scss +0 -0
  99. package/templates/angular/13.2.4/src/app/investment-amount/investment-amount.component.ts +31 -0
  100. package/templates/angular/13.2.4/src/app/investment-origin/investment-origin.component.html +12 -0
  101. package/templates/angular/13.2.4/src/app/investment-origin/investment-origin.component.scss +0 -0
  102. package/templates/angular/13.2.4/src/app/investment-origin/investment-origin.component.ts +24 -0
  103. package/templates/angular/13.2.4/src/app/summary/summary.component.html +74 -0
  104. package/templates/angular/13.2.4/src/app/summary/summary.component.scss +0 -0
  105. package/templates/angular/13.2.4/src/app/summary/summary.component.ts +16 -0
  106. package/templates/angular/13.2.4/src/assets/.gitkeep +0 -0
  107. package/templates/{eleventy-ssr → angular/13.2.4}/src/assets/img/android-chrome-192x192.png +0 -0
  108. package/templates/{eleventy-ssr → angular/13.2.4}/src/assets/img/apple-touch-icon-180x180.png +0 -0
  109. package/templates/{eleventy-ssr → angular/13.2.4}/src/assets/img/splash-screen-icon-512x512.png +0 -0
  110. package/templates/angular/13.2.4/src/environments/environment.prod.ts +3 -0
  111. package/templates/angular/13.2.4/src/environments/environment.ts +16 -0
  112. package/templates/{eleventy-ssr → angular/13.2.4}/src/favicon.ico +0 -0
  113. package/templates/angular/13.2.4/src/index.html +24 -0
  114. package/templates/angular/13.2.4/src/main.ts +13 -0
  115. package/templates/{react/public → angular/13.2.4/src}/manifest.json +0 -0
  116. package/templates/angular/13.2.4/src/polyfills.ts +62 -0
  117. package/templates/angular/13.2.4/src/styles.scss +3 -0
  118. package/templates/angular/13.2.4/src/tests/app.test.ts +13 -0
  119. package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts +54 -0
  120. package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-1-chromium-darwin.png +0 -0
  121. package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-2-chromium-darwin.png +0 -0
  122. package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-3-chromium-darwin.png +0 -0
  123. package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-4-chromium-darwin.png +0 -0
  124. package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts-snapshots/angular-13-2-4-5-chromium-darwin.png +0 -0
  125. package/templates/angular/13.2.4/src/tests/playwright/playwright.test.ts-snapshots/code-chromium-darwin.json +16 -0
  126. package/templates/angular/13.2.4/src/utils/string.utils.ts +1 -0
  127. package/templates/angular/13.2.4/tsconfig.app.json +9 -0
  128. package/templates/angular/13.2.4/tsconfig.base.json +17 -0
  129. package/templates/angular/13.2.4/tsconfig.json +8 -0
  130. package/templates/angular/13.2.4/tsconfig.spec.json +15 -0
  131. package/templates/eleventy/{.eleventy.js → 0.10.0/.eleventy.js} +0 -0
  132. package/templates/eleventy/{.prettierignore → 0.10.0/.prettierignore} +0 -0
  133. package/templates/eleventy/{README.md → 0.10.0/README.md} +0 -0
  134. package/templates/eleventy/{gulpfile.js → 0.10.0/gulpfile.js} +0 -0
  135. package/templates/eleventy/{package.file → 0.10.0/package.file} +0 -0
  136. package/templates/{react/public → eleventy/0.10.0/src}/assets/img/android-chrome-192x192.png +0 -0
  137. package/templates/{react/public → eleventy/0.10.0/src}/assets/img/apple-touch-icon-180x180.png +0 -0
  138. package/templates/{react/public → eleventy/0.10.0/src}/assets/img/splash-screen-icon-512x512.png +0 -0
  139. package/templates/eleventy/{src → 0.10.0/src}/css/main.scss +0 -0
  140. package/templates/eleventy/{src → 0.10.0/src}/css/partials/_example.scss +0 -0
  141. package/templates/eleventy/{src → 0.10.0/src}/data/duet.js +0 -0
  142. package/templates/{html → eleventy/0.10.0}/src/favicon.ico +0 -0
  143. package/templates/eleventy/{src → 0.10.0/src}/includes/footer.njk +0 -0
  144. package/templates/eleventy/{src → 0.10.0/src}/includes/header.njk +0 -0
  145. package/templates/eleventy/{src → 0.10.0/src}/includes/layout.njk +0 -0
  146. package/templates/eleventy/{src → 0.10.0/src}/index.njk +0 -0
  147. package/templates/eleventy/{src → 0.10.0/src}/js/scripts.js +0 -0
  148. package/templates/eleventy/{src → 0.10.0/src}/manifest.json +0 -0
  149. package/templates/eleventy/{src → 0.10.0/src}/robots.txt +0 -0
  150. package/templates/eleventy/{src → 0.10.0/src}/vahinkoasiat.njk +0 -0
  151. package/templates/eleventy/{src → 0.10.0/src}/vakuutukset.njk +0 -0
  152. package/templates/eleventy-ssr/{.eleventy.js → 0.10.0/.eleventy.js} +0 -0
  153. package/templates/eleventy-ssr/{.prettierignore → 0.10.0/.prettierignore} +0 -0
  154. package/templates/eleventy-ssr/{README.md → 0.10.0/README.md} +0 -0
  155. package/templates/eleventy-ssr/{gulpfile.js → 0.10.0/gulpfile.js} +0 -0
  156. package/templates/eleventy-ssr/{package.file → 0.10.0/package.file} +0 -0
  157. package/templates/{eleventy → eleventy-ssr/0.10.0}/src/assets/img/android-chrome-192x192.png +0 -0
  158. package/templates/{eleventy → eleventy-ssr/0.10.0}/src/assets/img/apple-touch-icon-180x180.png +0 -0
  159. package/templates/{eleventy → eleventy-ssr/0.10.0}/src/assets/img/splash-screen-icon-512x512.png +0 -0
  160. package/templates/eleventy-ssr/{src → 0.10.0/src}/css/main.scss +0 -0
  161. package/templates/eleventy-ssr/{src → 0.10.0/src}/css/partials/_example.scss +0 -0
  162. package/templates/eleventy-ssr/{src → 0.10.0/src}/data/duet.js +0 -0
  163. package/templates/{eleventy → eleventy-ssr/0.10.0}/src/favicon.ico +0 -0
  164. package/templates/eleventy-ssr/{src → 0.10.0/src}/includes/footer.njk +0 -0
  165. package/templates/eleventy-ssr/{src → 0.10.0/src}/includes/header.njk +0 -0
  166. package/templates/eleventy-ssr/{src → 0.10.0/src}/includes/layout.njk +0 -0
  167. package/templates/eleventy-ssr/{src → 0.10.0/src}/index.njk +0 -0
  168. package/templates/eleventy-ssr/{src → 0.10.0/src}/js/scripts.js +0 -0
  169. package/templates/eleventy-ssr/{src → 0.10.0/src}/manifest.json +0 -0
  170. package/templates/eleventy-ssr/{src → 0.10.0/src}/robots.txt +0 -0
  171. package/templates/eleventy-ssr/{src → 0.10.0/src}/vahinkoasiat.njk +0 -0
  172. package/templates/eleventy-ssr/{src → 0.10.0/src}/vakuutukset.njk +0 -0
  173. package/templates/{react → html/2.0.0}/.prettierignore +0 -0
  174. package/templates/html/{README.md → 2.0.0/README.md} +0 -0
  175. package/templates/html/{package.file → 2.0.0/package.file} +0 -0
  176. package/templates/{react/public → html/2.0.0/src}/favicon.ico +0 -0
  177. package/templates/html/{src → 2.0.0/src}/index.html +0 -0
  178. package/templates/react/16.14.0/.prettierignore +3 -0
  179. package/templates/react/16.14.0/LICENSE.md +29 -0
  180. package/templates/react/{README.md → 16.14.0/README.md} +2 -2
  181. package/templates/react/16.14.0/package-lock.json +15324 -0
  182. package/templates/react/16.14.0/package.file +39 -0
  183. package/templates/react/16.14.0/playwright.config.mjs +26 -0
  184. package/templates/react/16.14.0/public/assets/img/android-chrome-192x192.png +0 -0
  185. package/templates/react/16.14.0/public/assets/img/apple-touch-icon-180x180.png +0 -0
  186. package/templates/react/16.14.0/public/assets/img/splash-screen-icon-512x512.png +0 -0
  187. package/templates/react/16.14.0/public/favicon.ico +0 -0
  188. package/templates/react/{public → 16.14.0/public}/index.html +1 -1
  189. package/templates/react/16.14.0/public/manifest.json +19 -0
  190. package/templates/react/16.14.0/src/App.js +138 -0
  191. package/templates/react/16.14.0/src/components/Footer.js +24 -0
  192. package/templates/react/16.14.0/src/components/Header.js +7 -0
  193. package/templates/react/16.14.0/src/components/InvestmentAmount.js +139 -0
  194. package/templates/react/16.14.0/src/components/InvestmentOrigin.js +89 -0
  195. package/templates/react/16.14.0/src/components/Summary.js +96 -0
  196. package/templates/react/{src → 16.14.0/src}/index.js +0 -0
  197. package/templates/react/{src → 16.14.0/src}/index.scss +0 -0
  198. package/templates/react/{src → 16.14.0/src}/serviceWorker.js +0 -0
  199. package/templates/react/16.14.0/src/tests/playwright/playwright.test.mjs +54 -0
  200. package/templates/react/16.14.0/src/tests/playwright/playwright.test.mjs-snapshots/app-1-chromium-darwin.png +0 -0
  201. package/templates/react/16.14.0/src/tests/playwright/playwright.test.mjs-snapshots/app-2-chromium-darwin.png +0 -0
  202. package/templates/react/16.14.0/src/tests/playwright/playwright.test.mjs-snapshots/app-3-chromium-darwin.png +0 -0
  203. package/templates/react/16.14.0/src/tests/playwright/playwright.test.mjs-snapshots/app-4-chromium-darwin.png +0 -0
  204. package/templates/react/16.14.0/src/tests/playwright/playwright.test.mjs-snapshots/app-5-chromium-darwin.png +0 -0
  205. package/templates/react/16.14.0/src/tests/playwright/playwright.test.mjs-snapshots/code-chromium-darwin.json +16 -0
  206. package/templates/react/17.0.2/LICENSE.md +29 -0
  207. package/templates/react/17.0.2/README.md +54 -0
  208. package/templates/react/17.0.2/package-lock.json +10713 -0
  209. package/templates/react/17.0.2/package.file +39 -0
  210. package/templates/react/17.0.2/playwright.config.mjs +26 -0
  211. package/templates/react/17.0.2/public/assets/img/android-chrome-192x192.png +0 -0
  212. package/templates/react/17.0.2/public/assets/img/apple-touch-icon-180x180.png +0 -0
  213. package/templates/react/17.0.2/public/assets/img/splash-screen-icon-512x512.png +0 -0
  214. package/templates/react/17.0.2/public/favicon.ico +0 -0
  215. package/templates/react/17.0.2/public/index.html +48 -0
  216. package/templates/react/17.0.2/public/manifest.json +19 -0
  217. package/templates/react/17.0.2/src/App.js +138 -0
  218. package/templates/react/17.0.2/src/components/Footer.js +24 -0
  219. package/templates/react/17.0.2/src/components/Header.js +7 -0
  220. package/templates/react/17.0.2/src/components/InvestmentAmount.js +139 -0
  221. package/templates/react/17.0.2/src/components/InvestmentOrigin.js +89 -0
  222. package/templates/react/17.0.2/src/components/Summary.js +96 -0
  223. package/templates/react/17.0.2/src/index.js +17 -0
  224. package/templates/react/17.0.2/src/index.scss +2 -0
  225. package/templates/react/17.0.2/src/serviceWorker.js +141 -0
  226. package/templates/react/17.0.2/src/tests/playwright/playwright.test.mjs +54 -0
  227. package/templates/react/17.0.2/src/tests/playwright/playwright.test.mjs-snapshots/app-1-chromium-darwin.png +0 -0
  228. package/templates/react/17.0.2/src/tests/playwright/playwright.test.mjs-snapshots/app-2-chromium-darwin.png +0 -0
  229. package/templates/react/17.0.2/src/tests/playwright/playwright.test.mjs-snapshots/app-3-chromium-darwin.png +0 -0
  230. package/templates/react/17.0.2/src/tests/playwright/playwright.test.mjs-snapshots/app-4-chromium-darwin.png +0 -0
  231. package/templates/react/17.0.2/src/tests/playwright/playwright.test.mjs-snapshots/app-5-chromium-darwin.png +0 -0
  232. package/templates/react/17.0.2/src/tests/playwright/playwright.test.mjs-snapshots/code-chromium-darwin.json +16 -0
  233. package/templates/angular/package.file +0 -49
  234. package/templates/angular/src/app/app-routing.module.ts +0 -17
  235. package/templates/angular/src/app/footer/footer.component.html +0 -15
  236. package/templates/angular/src/app/header/header.component.html +0 -22
  237. package/templates/angular/src/app/header/header.component.scss +0 -3
  238. package/templates/angular/src/app/header/header.component.ts +0 -54
  239. package/templates/angular/src/app/index-page/index-page.component.html +0 -53
  240. package/templates/angular/src/app/index-page/index-page.component.ts +0 -30
  241. package/templates/angular/src/app/injuries-page/injuries-page.component.html +0 -37
  242. package/templates/angular/src/app/injuries-page/injuries-page.component.ts +0 -18
  243. package/templates/angular/src/app/insurance-page/insurance-page.component.html +0 -43
  244. package/templates/angular/src/app/insurance-page/insurance-page.component.ts +0 -18
  245. package/templates/angular/tsconfig.json +0 -14
  246. package/templates/react/package.file +0 -48
  247. package/templates/react/src/App.js +0 -67
  248. package/templates/react/src/components/Footer.js +0 -17
  249. package/templates/react/src/components/Header.js +0 -38
@@ -0,0 +1,141 @@
1
+ // This optional code is used to register a service worker.
2
+ // register() is not called by default.
3
+
4
+ // This lets the app load faster on subsequent visits in production, and gives
5
+ // it offline capabilities. However, it also means that developers (and users)
6
+ // will only see deployed updates on subsequent visits to a page, after all the
7
+ // existing tabs open on the page have been closed, since previously cached
8
+ // resources are updated in the background.
9
+
10
+ // To learn more about the benefits of this model and instructions on how to
11
+ // opt-in, read https://bit.ly/CRA-PWA
12
+
13
+ const isLocalhost = Boolean(
14
+ window.location.hostname === 'localhost' ||
15
+ // [::1] is the IPv6 localhost address.
16
+ window.location.hostname === '[::1]' ||
17
+ // 127.0.0.0/8 are considered localhost for IPv4.
18
+ window.location.hostname.match(
19
+ /^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/
20
+ )
21
+ );
22
+
23
+ export function register(config) {
24
+ if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {
25
+ // The URL constructor is available in all browsers that support SW.
26
+ const publicUrl = new URL(process.env.PUBLIC_URL, window.location.href);
27
+ if (publicUrl.origin !== window.location.origin) {
28
+ // Our service worker won't work if PUBLIC_URL is on a different origin
29
+ // from what our page is served on. This might happen if a CDN is used to
30
+ // serve assets; see https://github.com/facebook/create-react-app/issues/2374
31
+ return;
32
+ }
33
+
34
+ window.addEventListener('load', () => {
35
+ const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;
36
+
37
+ if (isLocalhost) {
38
+ // This is running on localhost. Let's check if a service worker still exists or not.
39
+ checkValidServiceWorker(swUrl, config);
40
+
41
+ // Add some additional logging to localhost, pointing developers to the
42
+ // service worker/PWA documentation.
43
+ navigator.serviceWorker.ready.then(() => {
44
+ console.log(
45
+ 'This web app is being served cache-first by a service ' +
46
+ 'worker. To learn more, visit https://bit.ly/CRA-PWA'
47
+ );
48
+ });
49
+ } else {
50
+ // Is not localhost. Just register service worker
51
+ registerValidSW(swUrl, config);
52
+ }
53
+ });
54
+ }
55
+ }
56
+
57
+ function registerValidSW(swUrl, config) {
58
+ navigator.serviceWorker
59
+ .register(swUrl)
60
+ .then(registration => {
61
+ registration.onupdatefound = () => {
62
+ const installingWorker = registration.installing;
63
+ if (installingWorker == null) {
64
+ return;
65
+ }
66
+ installingWorker.onstatechange = () => {
67
+ if (installingWorker.state === 'installed') {
68
+ if (navigator.serviceWorker.controller) {
69
+ // At this point, the updated precached content has been fetched,
70
+ // but the previous service worker will still serve the older
71
+ // content until all client tabs are closed.
72
+ console.log(
73
+ 'New content is available and will be used when all ' +
74
+ 'tabs for this page are closed. See https://bit.ly/CRA-PWA.'
75
+ );
76
+
77
+ // Execute callback
78
+ if (config && config.onUpdate) {
79
+ config.onUpdate(registration);
80
+ }
81
+ } else {
82
+ // At this point, everything has been precached.
83
+ // It's the perfect time to display a
84
+ // "Content is cached for offline use." message.
85
+ console.log('Content is cached for offline use.');
86
+
87
+ // Execute callback
88
+ if (config && config.onSuccess) {
89
+ config.onSuccess(registration);
90
+ }
91
+ }
92
+ }
93
+ };
94
+ };
95
+ })
96
+ .catch(error => {
97
+ console.error('Error during service worker registration:', error);
98
+ });
99
+ }
100
+
101
+ function checkValidServiceWorker(swUrl, config) {
102
+ // Check if the service worker can be found. If it can't reload the page.
103
+ fetch(swUrl, {
104
+ headers: { 'Service-Worker': 'script' },
105
+ })
106
+ .then(response => {
107
+ // Ensure service worker exists, and that we really are getting a JS file.
108
+ const contentType = response.headers.get('content-type');
109
+ if (
110
+ response.status === 404 ||
111
+ (contentType != null && contentType.indexOf('javascript') === -1)
112
+ ) {
113
+ // No service worker found. Probably a different app. Reload the page.
114
+ navigator.serviceWorker.ready.then(registration => {
115
+ registration.unregister().then(() => {
116
+ window.location.reload();
117
+ });
118
+ });
119
+ } else {
120
+ // Service worker found. Proceed as normal.
121
+ registerValidSW(swUrl, config);
122
+ }
123
+ })
124
+ .catch(() => {
125
+ console.log(
126
+ 'No internet connection found. App is running in offline mode.'
127
+ );
128
+ });
129
+ }
130
+
131
+ export function unregister() {
132
+ if ('serviceWorker' in navigator) {
133
+ navigator.serviceWorker.ready
134
+ .then(registration => {
135
+ registration.unregister();
136
+ })
137
+ .catch(error => {
138
+ console.error(error.message);
139
+ });
140
+ }
141
+ }
@@ -0,0 +1,54 @@
1
+ import { test, expect } from '@playwright/test';
2
+
3
+ test.use({
4
+ viewport: { width: 1800, height: 2500 },
5
+ bypassCSP: true,
6
+ deviceScaleFactor: 1,
7
+ })
8
+
9
+
10
+ test('app', async ({ page }, testInfo) => {
11
+ await page.waitForLoadState("networkidle") // This resolves after 'networkidle'
12
+ await page.waitForTimeout(1000 * testInfo.retry + 1)
13
+ await page.setViewportSize({ width: 1600, height: 1200 })
14
+
15
+
16
+ // initial loading
17
+ await page.goto("http://localhost:3000/");
18
+ await page.locator('select');
19
+ expect(await page.screenshot()).toMatchSnapshot("app_1.png");
20
+
21
+
22
+ // Select 2
23
+ await page.locator('select').selectOption('2');
24
+ await page.waitForLoadState("networkidle")
25
+ expect(await page.screenshot()).toMatchSnapshot("app_2.png");
26
+
27
+
28
+
29
+ // Click input[type="number"]
30
+ await page.locator('input[type="number"]').click();
31
+ await page.locator('input[type="number"]').fill('500');
32
+ await page.locator('#step1').click();
33
+ await page.waitForLoadState("networkidle")
34
+ expect(await page.screenshot()).toMatchSnapshot("app_3.png");
35
+
36
+
37
+ // summary loading
38
+ await page.locator('#step2').click();
39
+ await page.waitForLoadState("networkidle")
40
+ expect(await page.screenshot()).toMatchSnapshot("app_4.png");
41
+
42
+
43
+ // summary displaying
44
+ await page.locator('#step3').click();
45
+ await page.waitForLoadState("networkidle") // This resolves after 'networkidle'
46
+ expect(await page.screenshot()).toMatchSnapshot("app_5.png");
47
+
48
+
49
+
50
+ // Click code, store json
51
+ await page.locator('pre').click();
52
+ expect(await page.textContent('pre')).toMatchSnapshot('code.json');
53
+
54
+ });
@@ -0,0 +1,16 @@
1
+ {
2
+ "investmentAmount": {
3
+ "agreement": "2",
4
+ "additionalInvestment": 500
5
+ },
6
+ "investmentOrigin": {
7
+ "salary": false,
8
+ "gift": false,
9
+ "heritage": false,
10
+ "entrepreneurialIncome": false,
11
+ "assets": false,
12
+ "otherIncome": false,
13
+ "investment": false,
14
+ "extras": ""
15
+ }
16
+ }
@@ -1,49 +0,0 @@
1
- {
2
- "name": "duet-angular-template",
3
- "version": "0.0.0",
4
- "private": true,
5
- "scripts": {
6
- "ng": "ng",
7
- "start": "ng serve",
8
- "build": "ng build",
9
- "build:prototype": "npm-run-all --sequential build:clean build:prepare build:login build:template build:encrypt",
10
- "build:clean": "rm -rf ./dist",
11
- "build:prepare": "mkdir -p ./dist",
12
- "build:login": "ncp ./.github/workflows/login.template ./dist/index.html",
13
- "build:template": "ng build --prod --baseHref=/$DUET_PROJECT_NAME/$DUET_TOKEN/ --outputPath=dist/$DUET_TOKEN",
14
- "build:encrypt": "node ./.github/workflows/encrypt.js $DUET_TOKEN passphrase",
15
- "lint": "ng lint"
16
- },
17
- "dependencies": {
18
- "@angular/animations": "~10.0.5",
19
- "@angular/common": "~10.0.5",
20
- "@angular/compiler": "~10.0.5",
21
- "@angular/core": "~10.0.5",
22
- "@angular/forms": "~10.0.5",
23
- "@angular/platform-browser": "~10.0.5",
24
- "@angular/platform-browser-dynamic": "~10.0.5",
25
- "@angular/router": "~10.0.5",
26
- "@duetds/angular": "latest",
27
- "@duetds/css": "latest",
28
- "@duetds/icons": "latest",
29
- "@duetds/tokens": "latest",
30
- "rxjs": "~6.5.5",
31
- "tslib": "2.0.0",
32
- "zone.js": "~0.10.3"
33
- },
34
- "devDependencies": {
35
- "@angular-devkit/build-angular": "~0.1000.4",
36
- "@angular/cli": "~10.0.4",
37
- "@angular/compiler-cli": "~10.0.5",
38
- "@types/node": "12.11.1",
39
- "codelyzer": "6.0.0",
40
- "crypto-js": "4.0.0",
41
- "ncp": "2.0.0",
42
- "npm-run-all": "4.1.5",
43
- "replace-in-file": "5.0.2",
44
- "ts-node": "~8.3.0",
45
- "tslint": "~6.1.0",
46
- "typescript": "~3.9.5",
47
- "yargs": "15.1.0"
48
- }
49
- }
@@ -1,17 +0,0 @@
1
- import { NgModule } from "@angular/core"
2
- import { Routes, RouterModule } from "@angular/router"
3
- import { IndexPageComponent } from "./index-page/index-page.component"
4
- import { InsurancePageComponent } from "./insurance-page/insurance-page.component"
5
- import { InjuriesPageComponent } from "./injuries-page/injuries-page.component"
6
-
7
- const routes: Routes = [
8
- { path: "", component: IndexPageComponent },
9
- { path: "vahinkoasiat", component: InjuriesPageComponent },
10
- { path: "vakuutukset", component: InsurancePageComponent },
11
- ]
12
-
13
- @NgModule({
14
- imports: [RouterModule.forRoot(routes, { scrollPositionRestoration: "enabled", useHash: true })],
15
- exports: [RouterModule],
16
- })
17
- export class AppRoutingModule {}
@@ -1,15 +0,0 @@
1
- <duet-footer
2
- logo-href="/"
3
- language="fi"
4
- [items]="[
5
- { label: 'Hae korvausta', href: '#', icon: 'navigation-make-claim' },
6
- { label: 'Osta vakuutus', href: '#', icon: 'action-buy-insurance' },
7
- { label: 'Yhteystiedot', href: '#', icon: 'form-tel' }
8
- ]"
9
- [menu]="[
10
- { label: 'Turvallisuus ja käyttöehdot', href: '#' },
11
- { label: 'Evästeet', href: '#' },
12
- { label: 'Henkilötietojen käsittely', href: '#' }
13
- ]"
14
- >
15
- </duet-footer>
@@ -1,22 +0,0 @@
1
- <duet-header
2
- language="fi"
3
- skip-to-id="#content"
4
- contact="Ota yhteyttä"
5
- logo-href="/"
6
- [currentHref]="currentUrl"
7
- [items]="items"
8
- [languageItems]="[
9
- { label: 'Suomeksi', country: 'fi', href: '#' },
10
- { label: 'På Svenska', country: 'sv', href: '#' },
11
- { label: 'In English', country: 'en', href: '#' }
12
- ]"
13
- [contactItems]="[
14
- { label: 'Lähetä viesti', href: '#' },
15
- { label: 'Avaa chat', href: '#' },
16
- { label: 'Yhteystiedot', href: '#' }
17
- ]"
18
- [session]="{ label: 'Kirjaudu ulos', href: '#', type: 'logout' }"
19
- [user]="{ label: 'Laura', href: '#' }"
20
- (duetChange)="handleHeaderChange($event)"
21
- >
22
- </duet-header>
@@ -1,3 +0,0 @@
1
- :host {
2
- display: contents;
3
- }
@@ -1,54 +0,0 @@
1
- import { Component } from "@angular/core"
2
- import { Router } from "@angular/router"
3
- import { LocationStrategy } from "@angular/common"
4
- import { DuetHeaderItem } from "@duetds/components/lib/types/components/duet-header/duet-header"
5
-
6
- @Component({
7
- selector: "app-header",
8
- templateUrl: "./header.component.html",
9
- styleUrls: ["./header.component.scss"],
10
- })
11
- export class HeaderComponent {
12
- private links: DuetHeaderItem[] = [
13
- { label: "Etusivu", href: "/" },
14
- { label: "Vakuutukset", href: "/vakuutukset" },
15
- { label: "Vahinkoasiat", href: "/vahinkoasiat" },
16
- ]
17
-
18
- constructor(private router: Router, private location: LocationStrategy) {}
19
-
20
- public get currentUrl() {
21
- return this.location.prepareExternalUrl(this.router.url)
22
- }
23
-
24
- public get items() {
25
- return this.links.map(link => ({
26
- ...link,
27
- href: this.location.prepareExternalUrl(link.href),
28
- }))
29
- }
30
-
31
- handleHeaderChange(event: CustomEvent) {
32
- if (event.detail.originalEvent.metaKey) {
33
- return
34
- }
35
-
36
- event.detail.originalEvent.preventDefault()
37
- const data = event.detail.data
38
-
39
- if (data.type || data.country) {
40
- return
41
- }
42
-
43
- if (data.label === "logo") {
44
- this.navigateToItem(data)
45
- } else {
46
- const item = this.links.find(item => item.label === data.label)
47
- this.navigateToItem(item)
48
- }
49
- }
50
-
51
- private navigateToItem(data: DuetHeaderItem) {
52
- this.router.navigateByUrl(data.href)
53
- }
54
- }
@@ -1,53 +0,0 @@
1
- <duet-hero
2
- heading="Etusivu"
3
- image="https://cdn.duetds.com/api/assets/illustrations/placeholder-light.svg"
4
- button-label="Toimintopainike"
5
- [buttonUrl]="heroButtonUrl"
6
- id="content"
7
- description="Tämä teksti on luotu Hero-komponentin description-asetuksella. Voit lisätä tähän esimerkiksi ingressin."
8
- (duetClick)="handleHeroClick($event)"
9
- >
10
- </duet-hero>
11
- <duet-layout sticky>
12
- <div slot="main">
13
- <duet-card padding="large">
14
- <duet-heading level="h2">Pääpalsta</duet-heading>
15
- <duet-paragraph>
16
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
17
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation
18
- <duet-link url="#">ullamco laboris nisi ut aliquip</duet-link> ex ea commodo consequat. Duis aute irure dolor in
19
- reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat
20
- non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
21
- </duet-paragraph>
22
- <duet-paragraph>
23
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
24
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
25
- consequat.
26
- </duet-paragraph>
27
- <duet-heading level="h3">Otsikko 3</duet-heading>
28
- <duet-paragraph>
29
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
30
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation.
31
- </duet-paragraph>
32
- <duet-heading level="h4">Otsikko 4</duet-heading>
33
- <duet-paragraph>
34
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
35
- magna aliqua.
36
- </duet-paragraph>
37
- <duet-heading level="h5">Otsikko 5</duet-heading>
38
- <duet-paragraph>
39
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
40
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
41
- consequat.
42
- </duet-paragraph>
43
- <duet-heading level="h6">Otsikko 6</duet-heading>
44
- <duet-paragraph> Lorem ipsum dolor sit amet, consectetur adipiscing elit. </duet-paragraph>
45
- </duet-card>
46
- </div>
47
- <div slot="sidebar">
48
- <duet-card padding="large" heading="Sivupalsta">
49
- Sivupalstaa voidaan käyttää pääsisältöön liittyvän tiedon näyttämiseen tai vaihtoehtoisesti nostamaan esiin
50
- aiheeseen liittyvää muuta sisältöä.
51
- </duet-card>
52
- </div>
53
- </duet-layout>
@@ -1,30 +0,0 @@
1
- import { Component } from "@angular/core"
2
- import { Router } from "@angular/router"
3
- import { Title } from "@angular/platform-browser"
4
- import { LocationStrategy } from "@angular/common"
5
-
6
- @Component({
7
- selector: "app-index-page",
8
- templateUrl: "./index-page.component.html",
9
- styleUrls: ["./index-page.component.scss"],
10
- })
11
- export class IndexPageComponent {
12
- private heroUrl = "/vakuutukset"
13
-
14
- constructor(private router: Router, private location: LocationStrategy, private title: Title) {
15
- this.title.setTitle("LähiTapiola")
16
- }
17
-
18
- handleHeroClick(event: CustomEvent) {
19
- if (event.detail.originalEvent.metaKey) {
20
- return
21
- }
22
-
23
- event.detail.originalEvent.preventDefault()
24
- this.router.navigateByUrl(this.heroUrl)
25
- }
26
-
27
- get heroButtonUrl() {
28
- return this.location.prepareExternalUrl(this.heroUrl)
29
- }
30
- }
@@ -1,37 +0,0 @@
1
- <duet-layout center>
2
- <div slot="main">
3
- <duet-card padding="large">
4
- <duet-heading level="h1" visual-level="h2">Vahinkoasiat</duet-heading>
5
- <duet-paragraph>
6
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
7
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation
8
- <duet-link url="#">ullamco laboris nisi ut aliquip</duet-link> ex ea commodo consequat. Duis aute irure dolor in
9
- reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat
10
- non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
11
- </duet-paragraph>
12
- <duet-paragraph>
13
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
14
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
15
- consequat.
16
- </duet-paragraph>
17
- <duet-heading level="h3">Otsikko 3</duet-heading>
18
- <duet-paragraph>
19
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
20
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation.
21
- </duet-paragraph>
22
- <duet-heading level="h4">Otsikko 4</duet-heading>
23
- <duet-paragraph>
24
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
25
- magna aliqua.
26
- </duet-paragraph>
27
- <duet-heading level="h5">Otsikko 5</duet-heading>
28
- <duet-paragraph>
29
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
30
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
31
- consequat.
32
- </duet-paragraph>
33
- <duet-heading level="h6">Otsikko 6</duet-heading>
34
- <duet-paragraph>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</duet-paragraph>
35
- </duet-card>
36
- </div>
37
- </duet-layout>
@@ -1,18 +0,0 @@
1
- import { Component, Renderer2, OnDestroy } from "@angular/core"
2
- import { Title } from "@angular/platform-browser"
3
-
4
- @Component({
5
- selector: "app-injuries-page",
6
- templateUrl: "./injuries-page.component.html",
7
- styleUrls: ["./injuries-page.component.scss"],
8
- })
9
- export class InjuriesPageComponent implements OnDestroy {
10
- constructor(private title: Title, private renderer: Renderer2) {
11
- this.title.setTitle("Vahinkoasiat")
12
- this.renderer.addClass(document.documentElement, "duet-bg-gradient")
13
- }
14
-
15
- ngOnDestroy() {
16
- this.renderer.removeClass(document.documentElement, "duet-bg-gradient")
17
- }
18
- }
@@ -1,43 +0,0 @@
1
- <duet-layout sticky sticky-distance="with-links" id="content">
2
- <div slot="main">
3
- <duet-card padding="large">
4
- <duet-heading level="h1" visual-level="h2">Vakuutukset</duet-heading>
5
- <duet-paragraph>
6
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
7
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation
8
- <duet-link url="#">ullamco laboris nisi ut aliquip</duet-link> ex ea commodo consequat. Duis aute irure dolor in
9
- reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat
10
- non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
11
- </duet-paragraph>
12
- <duet-paragraph>
13
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
14
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
15
- consequat.
16
- </duet-paragraph>
17
- <duet-heading level="h3">Otsikko 3</duet-heading>
18
- <duet-paragraph>
19
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
20
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation.
21
- </duet-paragraph>
22
- <duet-heading level="h4">Otsikko 4</duet-heading>
23
- <duet-paragraph>
24
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
25
- magna aliqua.
26
- </duet-paragraph>
27
- <duet-heading level="h5">Otsikko 5</duet-heading>
28
- <duet-paragraph>
29
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore
30
- magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
31
- consequat.
32
- </duet-paragraph>
33
- <duet-heading level="h6">Otsikko 6</duet-heading>
34
- <duet-paragraph>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</duet-paragraph>
35
- </duet-card>
36
- </div>
37
- <div slot="sidebar">
38
- <duet-card padding="large" heading="Sivupalsta">
39
- Sivupalstaa voidaan käyttää pääsisältöön liittyvän tiedon näyttämiseen tai vaihtoehtoisesti nostamaan esiin
40
- aiheeseen liittyvää muuta sisältöä.
41
- </duet-card>
42
- </div>
43
- </duet-layout>
@@ -1,18 +0,0 @@
1
- import { Component, Renderer2, OnDestroy } from "@angular/core"
2
- import { Title } from "@angular/platform-browser"
3
-
4
- @Component({
5
- selector: "app-insurance-page",
6
- templateUrl: "./insurance-page.component.html",
7
- styleUrls: ["./insurance-page.component.scss"],
8
- })
9
- export class InsurancePageComponent implements OnDestroy {
10
- constructor(private title: Title, private renderer: Renderer2) {
11
- this.title.setTitle("Vakuutukset")
12
- this.renderer.addClass(document.documentElement, "duet-bg-gradient")
13
- }
14
-
15
- ngOnDestroy() {
16
- this.renderer.removeClass(document.documentElement, "duet-bg-gradient")
17
- }
18
- }
@@ -1,14 +0,0 @@
1
- /*
2
- This is a "Solution Style" tsconfig.json file, and is used by editors and TypeScript’s language server to improve development experience.
3
- It is not intended to be used to perform a compilation.
4
-
5
- To learn more about this file see: https://angular.io/config/solution-tsconfig.
6
- */
7
- {
8
- "files": [],
9
- "references": [
10
- {
11
- "path": "./tsconfig.app.json"
12
- }
13
- ]
14
- }
@@ -1,48 +0,0 @@
1
- {
2
- "name": "duet-react-template",
3
- "version": "0.1.1",
4
- "private": true,
5
- "scripts": {
6
- "start": "react-scripts start",
7
- "build": "react-scripts build",
8
- "eject": "react-scripts eject",
9
- "build:prototype": "npm-run-all --sequential build:clean build:prepare build:login build:template build:encrypt",
10
- "build:clean": "rm -rf ./dist",
11
- "build:prepare": "mkdir -p ./dist && touch dist/.nojekyll",
12
- "build:login": "ncp ./.github/workflows/login.template ./dist/index.html",
13
- "build:template": "PUBLIC_URL=/$DUET_PROJECT_NAME/$DUET_TOKEN react-scripts build && mv build/ dist/$DUET_TOKEN",
14
- "build:encrypt": "node ./.github/workflows/encrypt.js $DUET_TOKEN passphrase"
15
- },
16
- "browserslist": {
17
- "production": [
18
- ">0.2%",
19
- "not dead",
20
- "not op_mini all"
21
- ],
22
- "development": [
23
- "last 1 chrome version",
24
- "last 1 firefox version",
25
- "last 1 safari version"
26
- ]
27
- },
28
- "eslintConfig": {
29
- "extends": "react-app"
30
- },
31
- "dependencies": {
32
- "@duetds/css": "latest",
33
- "@duetds/icons": "latest",
34
- "@duetds/react": "latest",
35
- "@duetds/tokens": "latest",
36
- "react": "16.13.1",
37
- "react-dom": "16.13.1",
38
- "react-scripts": "3.4.3",
39
- "sass": "1.29.0"
40
- },
41
- "devDependencies": {
42
- "crypto-js": "4.0.0",
43
- "ncp": "2.0.0",
44
- "npm-run-all": "4.1.5",
45
- "replace-in-file": "5.0.2",
46
- "yargs": "15.1.0"
47
- }
48
- }