@roomle/web-sdk 2.43.0 → 2.44.0-alpha.2

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 (316) hide show
  1. package/.releaserc.json +55 -58
  2. package/README.md +3 -0
  3. package/lib/banana-for-scale-58aa07e7.nomodule.js +2 -0
  4. package/lib/{banana-for-scale-d4c457d4.nomodule.js.map → banana-for-scale-58aa07e7.nomodule.js.map} +1 -1
  5. package/lib/banana-for-scale-b0cad920.js +2 -0
  6. package/lib/{banana-for-scale-29fe9ece.js.map → banana-for-scale-b0cad920.js.map} +1 -1
  7. package/lib/budgeteer-measure-23a42ba1.js +2 -0
  8. package/lib/budgeteer-measure-23a42ba1.js.map +1 -0
  9. package/lib/budgeteer-measure.nomodule.js +1 -1
  10. package/lib/budgeteer-measure.nomodule.js.map +1 -1
  11. package/lib/component-dimensioning-3e2b21b8.nomodule.js +2 -0
  12. package/lib/component-dimensioning-3e2b21b8.nomodule.js.map +1 -0
  13. package/lib/{component-dimensioning-7b9b757c.nomodule.js → component-dimensioning-c2294a31.js} +2 -2
  14. package/lib/component-dimensioning-c2294a31.js.map +1 -0
  15. package/lib/{component-raycast-helper-e2883ebb.nomodule.js → component-raycast-helper-0b429141.nomodule.js} +2 -2
  16. package/lib/component-raycast-helper-0b429141.nomodule.js.map +1 -0
  17. package/lib/{component-raycast-helper-1eac1f65.js → component-raycast-helper-96be30dc.js} +2 -2
  18. package/lib/component-raycast-helper-96be30dc.js.map +1 -0
  19. package/lib/{configurator-df61a67c.js → configurator-1a9502eb.js} +2 -2
  20. package/lib/configurator-1a9502eb.js.map +1 -0
  21. package/lib/{configurator-9b988733.nomodule.js → configurator-ad930002.nomodule.js} +2 -2
  22. package/lib/configurator-ad930002.nomodule.js.map +1 -0
  23. package/lib/configurator-dummy-app.js.map +1 -1
  24. package/lib/configurator-dummy.html +167 -79
  25. package/lib/configurator-main-d4d311c0.js +2 -0
  26. package/lib/configurator-main-d4d311c0.js.map +1 -0
  27. package/lib/configurator-main.nomodule.js +1 -1
  28. package/lib/{default-light-setting-004b9cd2.js → default-light-setting-17aeb133.js} +2 -2
  29. package/lib/default-light-setting-17aeb133.js.map +1 -0
  30. package/lib/{default-light-setting-c6c8e1ad.nomodule.js → default-light-setting-917cc079.nomodule.js} +2 -2
  31. package/lib/default-light-setting-917cc079.nomodule.js.map +1 -0
  32. package/lib/definitions/acceptance-tests/src/utils/async-acceptance-test.d.ts +1 -1
  33. package/lib/definitions/common-core/mock/three-mock.d.ts +1 -1
  34. package/lib/definitions/common-core/src/error-handler.d.ts +1 -1
  35. package/lib/definitions/common-core/src/kernel-io.d.ts +1 -1
  36. package/lib/definitions/common-core/src/lightsetting/dynamic-light-setting-loader.d.ts +1 -1
  37. package/lib/definitions/common-core/src/rapi-access.d.ts +3 -3
  38. package/lib/definitions/common-core/src/script-loader.d.ts +1 -1
  39. package/lib/definitions/common-core/src/utils/common-utils.d.ts +1 -1
  40. package/lib/definitions/common-core/src/view-model/configurator-view-model.d.ts +1 -0
  41. package/lib/definitions/common-core/src/webgl/image-renderer.d.ts +1 -1
  42. package/lib/definitions/configurator-core/src/roomle-configurator.d.ts +58 -58
  43. package/lib/definitions/configurator-core/src/services/configurator-ui-callback.d.ts +2 -2
  44. package/lib/definitions/configurator-core/src/utils/event-dispatcher.d.ts +1 -1
  45. package/lib/definitions/configurator-core/src/utils/indexeddb-adapter.d.ts +2 -2
  46. package/lib/definitions/configurator-core/src/utils/test-helpers/interaction-helper.d.ts +2 -2
  47. package/lib/definitions/configurator-core/src/utils/test-helpers/ui-mock.d.ts +3 -3
  48. package/lib/definitions/configurator-core/src/utils/ui-intersection-helper.d.ts +2 -2
  49. package/lib/definitions/planner-core/mock/planner-kernel-access-mock.d.ts +1 -1
  50. package/lib/definitions/planner-core/src/roomle-planner-ui-callback.d.ts +1 -0
  51. package/lib/definitions/tools-core/src/roomle-tools-core.d.ts +1 -1
  52. package/lib/definitions/typings/global-definitions.d.ts +1 -1
  53. package/lib/definitions/typings/helper.d.ts +1 -1
  54. package/lib/definitions/typings/kernel.d.ts +1 -1
  55. package/lib/definitions/typings/rapi-types.d.ts +9 -9
  56. package/lib/definitions/workers/src/budgeteer.sw.d.ts +1 -1
  57. package/lib/dimensioning-helper-0995e4b8.nomodule.js +2 -0
  58. package/lib/dimensioning-helper-0995e4b8.nomodule.js.map +1 -0
  59. package/lib/dimensioning-helper-b166264a.js +2 -0
  60. package/lib/{dimensioning-helper-707197b7.js.map → dimensioning-helper-b166264a.js.map} +1 -1
  61. package/lib/embedding-dummy.html +122 -94
  62. package/lib/glb-viewer-45e04caa.js +2 -0
  63. package/lib/{glb-viewer-a3b1ff73.js.map → glb-viewer-45e04caa.js.map} +1 -1
  64. package/lib/glb-viewer-dummy-app.js.map +1 -1
  65. package/lib/glb-viewer-dummy.html +44 -30
  66. package/lib/glb-viewer-f5f9a050.nomodule.js +2 -0
  67. package/lib/{glb-viewer-23b774e0.nomodule.js.map → glb-viewer-f5f9a050.nomodule.js.map} +1 -1
  68. package/lib/glb-viewer-main-be603c6d.js +2 -0
  69. package/lib/glb-viewer-main-be603c6d.js.map +1 -0
  70. package/lib/glb-viewer-main.nomodule.js +1 -1
  71. package/lib/legacy/banana-for-scale-2021b8ce.legacy.js +2 -0
  72. package/lib/legacy/{banana-for-scale-f8ab137f.legacy.js.map → banana-for-scale-2021b8ce.legacy.js.map} +1 -1
  73. package/lib/legacy/budgeteer-measure.legacy.js +1 -1
  74. package/lib/legacy/budgeteer-measure.legacy.js.map +1 -1
  75. package/lib/legacy/component-dimensioning-f4289533.legacy.js +2 -0
  76. package/lib/legacy/component-dimensioning-f4289533.legacy.js.map +1 -0
  77. package/lib/legacy/{component-raycast-helper-59acc8b8.legacy.js → component-raycast-helper-afb624ed.legacy.js} +2 -2
  78. package/lib/legacy/component-raycast-helper-afb624ed.legacy.js.map +1 -0
  79. package/lib/legacy/{configurator-678bed92.legacy.js → configurator-431855b5.legacy.js} +2 -2
  80. package/lib/legacy/configurator-431855b5.legacy.js.map +1 -0
  81. package/lib/legacy/configurator-main.legacy.js +1 -1
  82. package/lib/legacy/{default-light-setting-0eae7ddf.legacy.js → default-light-setting-29282b63.legacy.js} +2 -2
  83. package/lib/legacy/default-light-setting-29282b63.legacy.js.map +1 -0
  84. package/lib/legacy/dimensioning-helper-b5001288.legacy.js +2 -0
  85. package/lib/legacy/dimensioning-helper-b5001288.legacy.js.map +1 -0
  86. package/lib/legacy/glb-viewer-0020898e.legacy.js +2 -0
  87. package/lib/legacy/{glb-viewer-ddc7a29d.legacy.js.map → glb-viewer-0020898e.legacy.js.map} +1 -1
  88. package/lib/legacy/glb-viewer-main.legacy.js +1 -1
  89. package/lib/legacy/main-thread-to-worker-cc24f989.legacy.js +2 -0
  90. package/lib/legacy/main-thread-to-worker-cc24f989.legacy.js.map +1 -0
  91. package/lib/legacy/material-viewer-51065b97.legacy.js +2 -0
  92. package/lib/legacy/material-viewer-51065b97.legacy.js.map +1 -0
  93. package/lib/legacy/material-viewer-main.legacy.js +1 -1
  94. package/lib/legacy/pixotron-e0f1cf47.legacy.js +2 -0
  95. package/lib/legacy/{pixotron-80fe5913.legacy.js.map → pixotron-e0f1cf47.legacy.js.map} +1 -1
  96. package/lib/legacy/planner-1af4bef2.legacy.js +2 -0
  97. package/lib/legacy/{planner-e41a2569.legacy.js.map → planner-1af4bef2.legacy.js.map} +1 -1
  98. package/lib/legacy/planner-main.legacy.js +1 -1
  99. package/lib/legacy/roomle-configurator-40f860e2.legacy.js +2 -0
  100. package/lib/legacy/{roomle-configurator-6602a267.legacy.js.map → roomle-configurator-40f860e2.legacy.js.map} +1 -1
  101. package/lib/legacy/roomle-dependency-injection-c465c69e.legacy.js +16 -0
  102. package/lib/legacy/{roomle-dependency-injection-e294616d.legacy.js.map → roomle-dependency-injection-c465c69e.legacy.js.map} +1 -1
  103. package/lib/legacy/roomle-sdk.legacy.js +1 -1
  104. package/lib/legacy/{script-loader-9dc48cfd.legacy.js → script-loader-f53b8215.legacy.js} +2 -2
  105. package/lib/legacy/script-loader-f53b8215.legacy.js.map +1 -0
  106. package/lib/legacy/static/{ConfiguratorKernel-e9065c8be4011f61.js → ConfiguratorKernel-0f003a2d53bdb498.js} +74 -73
  107. package/lib/legacy/static/ConfiguratorKernel-fee68dd17368f9c8.wasm +0 -0
  108. package/lib/legacy/static/ConfiguratorKernelJs-397177488117675e.js +146 -0
  109. package/lib/legacy/static/ConfiguratorKernelJs-6735c733ccd66361.mem +0 -0
  110. package/lib/legacy/static/DepthShadowGenerator-a3a9d85ff2c3d24c.js +266 -0
  111. package/lib/legacy/static/RoomleCore-4eb435620392fcc4.js +130 -0
  112. package/lib/legacy/static/RoomleCore-83f9a9bf9e4d7f73.wasm +0 -0
  113. package/lib/legacy/static/RoomleCoreJs-46a5e90adbb12d0c.js +154 -0
  114. package/lib/legacy/static/RoomleCoreJs-8bc350683d3c35ae.mem +0 -0
  115. package/lib/legacy/static/{RoomleToolsCore-eb38af3a8c882dff.js → RoomleToolsCore-2ec3c50f245db642.js} +70 -70
  116. package/lib/legacy/static/RoomleToolsCore-e949cc1f9026c61f.wasm +0 -0
  117. package/lib/legacy/static/Tween-5ebfb82307807fdc.js +767 -0
  118. package/lib/legacy/static/{asset-loader.worker-796c70f59b977071.js → asset-loader.worker-caa87aba0f76ce49.js} +1 -1
  119. package/lib/legacy/static/{budgeteer.sw-e7566da86237bca8.js → budgeteer.sw-0a8d4e36e18346a5.js} +1 -1
  120. package/lib/legacy/static/camera-05824b47cdb951e4.json +39 -0
  121. package/lib/legacy/static/dat.gui.min-24a0d861d5534d62.js +2447 -0
  122. package/lib/legacy/static/rubik_regular-bc008a7de2daee79.json +3535 -0
  123. package/lib/legacy/static/rubik_regular_sub-2dd2d5cca49018c5.json +168 -0
  124. package/lib/legacy/static/shaders-88030e4fbae39928.json +1 -0
  125. package/lib/legacy/stats-helper-951a6039.legacy.js +2 -0
  126. package/lib/legacy/{stats-helper-b0633f63.legacy.js.map → stats-helper-951a6039.legacy.js.map} +1 -1
  127. package/lib/legacy/{tools-core-0b66a05d.legacy.js → tools-core-8e9fd5dd.legacy.js} +2 -2
  128. package/lib/legacy/tools-core-8e9fd5dd.legacy.js.map +1 -0
  129. package/lib/main-thread-to-worker-6a4eb1ee.nomodule.js +2 -0
  130. package/lib/main-thread-to-worker-6a4eb1ee.nomodule.js.map +1 -0
  131. package/lib/main-thread-to-worker-88f74244.js +2 -0
  132. package/lib/main-thread-to-worker-88f74244.js.map +1 -0
  133. package/lib/material-viewer-2df0572f.nomodule.js +2 -0
  134. package/lib/material-viewer-2df0572f.nomodule.js.map +1 -0
  135. package/lib/material-viewer-ca21925a.js +2 -0
  136. package/lib/material-viewer-ca21925a.js.map +1 -0
  137. package/lib/material-viewer-dummy-app.js.map +1 -1
  138. package/lib/material-viewer-dummy.html +39 -22
  139. package/lib/material-viewer-main-5b2d8fb1.js +2 -0
  140. package/lib/material-viewer-main-5b2d8fb1.js.map +1 -0
  141. package/lib/material-viewer-main.nomodule.js +1 -1
  142. package/lib/measure.html +27 -34
  143. package/lib/pixotron-32c4e05d.js +2 -0
  144. package/lib/{pixotron-4eb69a29.js.map → pixotron-32c4e05d.js.map} +1 -1
  145. package/lib/pixotron-3be821e5.nomodule.js +2 -0
  146. package/lib/{pixotron-b8a4128f.nomodule.js.map → pixotron-3be821e5.nomodule.js.map} +1 -1
  147. package/lib/planner-07dfff6d.js +2 -0
  148. package/lib/{planner-05629dc5.js.map → planner-07dfff6d.js.map} +1 -1
  149. package/lib/planner-21a6fccd.nomodule.js +2 -0
  150. package/lib/{planner-0c378c93.nomodule.js.map → planner-21a6fccd.nomodule.js.map} +1 -1
  151. package/lib/planner-dummy-app.js.map +1 -1
  152. package/lib/planner-dummy.html +64 -43
  153. package/lib/planner-main-8a56d68d.js +2 -0
  154. package/lib/planner-main-8a56d68d.js.map +1 -0
  155. package/lib/planner-main.nomodule.js +1 -1
  156. package/lib/roomle-configurator-072f6af1.nomodule.js +2 -0
  157. package/lib/{roomle-configurator-ca8a3f05.nomodule.js.map → roomle-configurator-072f6af1.nomodule.js.map} +1 -1
  158. package/lib/roomle-configurator-21e1c87c.js +2 -0
  159. package/lib/{roomle-configurator-a2354193.js.map → roomle-configurator-21e1c87c.js.map} +1 -1
  160. package/lib/roomle-dependency-injection-8d66ecac.js +16 -0
  161. package/lib/{roomle-dependency-injection-dade8841.js.map → roomle-dependency-injection-8d66ecac.js.map} +1 -1
  162. package/lib/roomle-dependency-injection-f0b933f6.nomodule.js +16 -0
  163. package/lib/{roomle-dependency-injection-4d02aeed.nomodule.js.map → roomle-dependency-injection-f0b933f6.nomodule.js.map} +1 -1
  164. package/lib/{roomle-sdk-acba0c06.js → roomle-sdk-038a1704.js} +2 -2
  165. package/lib/roomle-sdk-038a1704.js.map +1 -0
  166. package/lib/roomle-sdk.nomodule.js +1 -1
  167. package/lib/{script-loader-122c197b.js → script-loader-a1d7afdd.js} +2 -2
  168. package/lib/script-loader-a1d7afdd.js.map +1 -0
  169. package/lib/{script-loader-425dddf6.nomodule.js → script-loader-c56ceed8.nomodule.js} +2 -2
  170. package/lib/script-loader-c56ceed8.nomodule.js.map +1 -0
  171. package/lib/static/ConfiguratorKernel-0f003a2d53bdb498.js +1 -0
  172. package/lib/static/ConfiguratorKernel-0f003a2d53bdb498.js.map +1 -0
  173. package/lib/static/ConfiguratorKernel-fee68dd17368f9c8.wasm +0 -0
  174. package/lib/static/ConfiguratorKernelJs-397177488117675e.js +146 -0
  175. package/lib/static/ConfiguratorKernelJs-6735c733ccd66361.mem +0 -0
  176. package/lib/static/{DepthShadowGenerator-4c4b06f0801c4034.js → DepthShadowGenerator-a3a9d85ff2c3d24c.js} +0 -0
  177. package/lib/static/DepthShadowGenerator-a3a9d85ff2c3d24c.js.map +1 -0
  178. package/lib/static/RoomleCore-4eb435620392fcc4.js +1 -0
  179. package/lib/static/RoomleCore-4eb435620392fcc4.js.map +1 -0
  180. package/lib/static/RoomleCore-83f9a9bf9e4d7f73.wasm +0 -0
  181. package/lib/static/RoomleCoreJs-46a5e90adbb12d0c.js +154 -0
  182. package/lib/static/RoomleCoreJs-8bc350683d3c35ae.mem +0 -0
  183. package/lib/static/RoomleToolsCore-2ec3c50f245db642.js +1 -0
  184. package/lib/static/RoomleToolsCore-2ec3c50f245db642.js.map +1 -0
  185. package/lib/static/RoomleToolsCore-e949cc1f9026c61f.wasm +0 -0
  186. package/lib/static/{Tween-d024b02fe34f25ab.js → Tween-5ebfb82307807fdc.js} +0 -0
  187. package/lib/static/Tween-5ebfb82307807fdc.js.map +1 -0
  188. package/lib/static/{asset-loader.worker-796c70f59b977071.js → asset-loader.worker-caa87aba0f76ce49.js} +1 -1
  189. package/lib/static/{asset-loader.worker-796c70f59b977071.js.map → asset-loader.worker-caa87aba0f76ce49.js.map} +0 -0
  190. package/lib/static/asset-loader.worker.js +1 -1
  191. package/lib/static/{budgeteer.sw-e7566da86237bca8.js → budgeteer.sw-0a8d4e36e18346a5.js} +1 -1
  192. package/lib/static/{budgeteer.sw-e7566da86237bca8.js.map → budgeteer.sw-0a8d4e36e18346a5.js.map} +0 -0
  193. package/lib/static/budgeteer.sw.js +1 -1
  194. package/lib/static/camera-05824b47cdb951e4.json +39 -0
  195. package/lib/static/{dat.gui.min-b5cbb61e5c62f0bf.js → dat.gui.min-24a0d861d5534d62.js} +0 -0
  196. package/lib/static/dat.gui.min-24a0d861d5534d62.js.map +1 -0
  197. package/lib/static/rubik_regular-bc008a7de2daee79.json +3535 -0
  198. package/lib/static/rubik_regular_sub-2dd2d5cca49018c5.json +168 -0
  199. package/lib/static/shaders-88030e4fbae39928.json +1 -0
  200. package/lib/static/worker-to-main-thread-3ad1cee7.js +1 -0
  201. package/lib/static/worker-to-main-thread-3ad1cee7.js.map +1 -0
  202. package/lib/static/worker-to-main-thread-73234f7a.js +1 -0
  203. package/lib/static/worker-to-main-thread-73234f7a.js.map +1 -0
  204. package/lib/stats-helper-53909b17.js +2 -0
  205. package/lib/{stats-helper-c731f63a.js.map → stats-helper-53909b17.js.map} +1 -1
  206. package/lib/{stats-helper-c731f63a.js → stats-helper-a75dc3da.nomodule.js} +2 -2
  207. package/lib/{stats-helper-37c0d77c.nomodule.js.map → stats-helper-a75dc3da.nomodule.js.map} +1 -1
  208. package/lib/{tools-core-4c13977c.js → tools-core-4e24e712.js} +2 -2
  209. package/lib/tools-core-4e24e712.js.map +1 -0
  210. package/lib/{tools-core-89d54f1f.nomodule.js → tools-core-865f89df.nomodule.js} +2 -2
  211. package/lib/tools-core-865f89df.nomodule.js.map +1 -0
  212. package/package.json +2 -2
  213. package/scripts/copy-assets-sdk.js +68 -56
  214. package/lib/banana-for-scale-29fe9ece.js +0 -2
  215. package/lib/banana-for-scale-d4c457d4.nomodule.js +0 -2
  216. package/lib/budgeteer-measure-1377faa9.js +0 -2
  217. package/lib/budgeteer-measure-1377faa9.js.map +0 -1
  218. package/lib/component-dimensioning-7b9b757c.nomodule.js.map +0 -1
  219. package/lib/component-dimensioning-d77dc5fd.js +0 -2
  220. package/lib/component-dimensioning-d77dc5fd.js.map +0 -1
  221. package/lib/component-raycast-helper-1eac1f65.js.map +0 -1
  222. package/lib/component-raycast-helper-e2883ebb.nomodule.js.map +0 -1
  223. package/lib/configurator-9b988733.nomodule.js.map +0 -1
  224. package/lib/configurator-df61a67c.js.map +0 -1
  225. package/lib/configurator-main-c2a9b119.js +0 -2
  226. package/lib/configurator-main-c2a9b119.js.map +0 -1
  227. package/lib/default-light-setting-004b9cd2.js.map +0 -1
  228. package/lib/default-light-setting-c6c8e1ad.nomodule.js.map +0 -1
  229. package/lib/dimensioning-helper-62227f7c.nomodule.js +0 -2
  230. package/lib/dimensioning-helper-62227f7c.nomodule.js.map +0 -1
  231. package/lib/dimensioning-helper-707197b7.js +0 -2
  232. package/lib/glb-viewer-23b774e0.nomodule.js +0 -2
  233. package/lib/glb-viewer-a3b1ff73.js +0 -2
  234. package/lib/glb-viewer-main-b413d64a.js +0 -2
  235. package/lib/glb-viewer-main-b413d64a.js.map +0 -1
  236. package/lib/legacy/banana-for-scale-f8ab137f.legacy.js +0 -2
  237. package/lib/legacy/component-dimensioning-06a6f9ee.legacy.js +0 -2
  238. package/lib/legacy/component-dimensioning-06a6f9ee.legacy.js.map +0 -1
  239. package/lib/legacy/component-raycast-helper-59acc8b8.legacy.js.map +0 -1
  240. package/lib/legacy/configurator-678bed92.legacy.js.map +0 -1
  241. package/lib/legacy/default-light-setting-0eae7ddf.legacy.js.map +0 -1
  242. package/lib/legacy/dimensioning-helper-97e8b9c5.legacy.js +0 -2
  243. package/lib/legacy/dimensioning-helper-97e8b9c5.legacy.js.map +0 -1
  244. package/lib/legacy/glb-viewer-ddc7a29d.legacy.js +0 -2
  245. package/lib/legacy/main-thread-to-worker-e2f2b9cb.legacy.js +0 -2
  246. package/lib/legacy/main-thread-to-worker-e2f2b9cb.legacy.js.map +0 -1
  247. package/lib/legacy/material-viewer-a01fd304.legacy.js +0 -2
  248. package/lib/legacy/material-viewer-a01fd304.legacy.js.map +0 -1
  249. package/lib/legacy/pixotron-80fe5913.legacy.js +0 -2
  250. package/lib/legacy/planner-e41a2569.legacy.js +0 -2
  251. package/lib/legacy/roomle-configurator-6602a267.legacy.js +0 -2
  252. package/lib/legacy/roomle-dependency-injection-e294616d.legacy.js +0 -16
  253. package/lib/legacy/script-loader-9dc48cfd.legacy.js.map +0 -1
  254. package/lib/legacy/static/ConfiguratorKernel-2e859fe27a3c86ed.wasm +0 -0
  255. package/lib/legacy/static/ConfiguratorKernelJs-23e7a53b8a38380c.mem +0 -0
  256. package/lib/legacy/static/ConfiguratorKernelJs-b43dc826821e864e.js +0 -146
  257. package/lib/legacy/static/DepthShadowGenerator-4c4b06f0801c4034.js +0 -262
  258. package/lib/legacy/static/RoomleCore-07c1ebfd847560ef.wasm +0 -0
  259. package/lib/legacy/static/RoomleCore-b08e77d418a3f4a0.js +0 -130
  260. package/lib/legacy/static/RoomleCoreJs-b207f4e5106d5bf5.js +0 -154
  261. package/lib/legacy/static/RoomleCoreJs-f9d0ac5ec78a81f3.mem +0 -0
  262. package/lib/legacy/static/RoomleToolsCore-c33ca3a9cb8ba880.wasm +0 -0
  263. package/lib/legacy/static/Tween-d024b02fe34f25ab.js +0 -913
  264. package/lib/legacy/static/camera-f4cef679615485dc.json +0 -39
  265. package/lib/legacy/static/dat.gui.min-b5cbb61e5c62f0bf.js +0 -13
  266. package/lib/legacy/static/rubik_regular-75bd7bb699e9e39d.json +0 -1
  267. package/lib/legacy/static/rubik_regular_sub-eb3f3b61078695cc.json +0 -1
  268. package/lib/legacy/static/shaders-7bdb2939b2a0d677.json +0 -1
  269. package/lib/legacy/stats-helper-b0633f63.legacy.js +0 -2
  270. package/lib/legacy/tools-core-0b66a05d.legacy.js.map +0 -1
  271. package/lib/main-thread-to-worker-681bab1a.js +0 -2
  272. package/lib/main-thread-to-worker-681bab1a.js.map +0 -1
  273. package/lib/main-thread-to-worker-7283a354.nomodule.js +0 -2
  274. package/lib/main-thread-to-worker-7283a354.nomodule.js.map +0 -1
  275. package/lib/material-viewer-2ca0de10.js +0 -2
  276. package/lib/material-viewer-2ca0de10.js.map +0 -1
  277. package/lib/material-viewer-ba8646c8.nomodule.js +0 -2
  278. package/lib/material-viewer-ba8646c8.nomodule.js.map +0 -1
  279. package/lib/material-viewer-main-dd95bf93.js +0 -2
  280. package/lib/material-viewer-main-dd95bf93.js.map +0 -1
  281. package/lib/pixotron-4eb69a29.js +0 -2
  282. package/lib/pixotron-b8a4128f.nomodule.js +0 -2
  283. package/lib/planner-05629dc5.js +0 -2
  284. package/lib/planner-0c378c93.nomodule.js +0 -2
  285. package/lib/planner-main-117f91e4.js +0 -2
  286. package/lib/planner-main-117f91e4.js.map +0 -1
  287. package/lib/roomle-configurator-a2354193.js +0 -2
  288. package/lib/roomle-configurator-ca8a3f05.nomodule.js +0 -2
  289. package/lib/roomle-dependency-injection-4d02aeed.nomodule.js +0 -16
  290. package/lib/roomle-dependency-injection-dade8841.js +0 -16
  291. package/lib/roomle-sdk-acba0c06.js.map +0 -1
  292. package/lib/script-loader-122c197b.js.map +0 -1
  293. package/lib/script-loader-425dddf6.nomodule.js.map +0 -1
  294. package/lib/static/ConfiguratorKernel-2e859fe27a3c86ed.wasm +0 -0
  295. package/lib/static/ConfiguratorKernel-e9065c8be4011f61.js +0 -1
  296. package/lib/static/ConfiguratorKernel-e9065c8be4011f61.js.map +0 -1
  297. package/lib/static/ConfiguratorKernelJs-23e7a53b8a38380c.mem +0 -0
  298. package/lib/static/ConfiguratorKernelJs-b43dc826821e864e.js +0 -146
  299. package/lib/static/DepthShadowGenerator-4c4b06f0801c4034.js.map +0 -1
  300. package/lib/static/RoomleCore-07c1ebfd847560ef.wasm +0 -0
  301. package/lib/static/RoomleCore-b08e77d418a3f4a0.js +0 -1
  302. package/lib/static/RoomleCore-b08e77d418a3f4a0.js.map +0 -1
  303. package/lib/static/RoomleCoreJs-b207f4e5106d5bf5.js +0 -154
  304. package/lib/static/RoomleCoreJs-f9d0ac5ec78a81f3.mem +0 -0
  305. package/lib/static/RoomleToolsCore-c33ca3a9cb8ba880.wasm +0 -0
  306. package/lib/static/RoomleToolsCore-eb38af3a8c882dff.js +0 -1
  307. package/lib/static/RoomleToolsCore-eb38af3a8c882dff.js.map +0 -1
  308. package/lib/static/Tween-d024b02fe34f25ab.js.map +0 -1
  309. package/lib/static/camera-f4cef679615485dc.json +0 -39
  310. package/lib/static/dat.gui.min-b5cbb61e5c62f0bf.js.map +0 -1
  311. package/lib/static/rubik_regular-75bd7bb699e9e39d.json +0 -1
  312. package/lib/static/rubik_regular_sub-eb3f3b61078695cc.json +0 -1
  313. package/lib/static/shaders-7bdb2939b2a0d677.json +0 -1
  314. package/lib/stats-helper-37c0d77c.nomodule.js +0 -2
  315. package/lib/tools-core-4c13977c.js.map +0 -1
  316. package/lib/tools-core-89d54f1f.nomodule.js.map +0 -1
@@ -0,0 +1,2447 @@
1
+ /**
2
+ * dat-gui JavaScript Controller Library
3
+ * http://code.google.com/p/dat-gui
4
+ *
5
+ * Copyright 2011 Data Arts Team, Google Creative Lab
6
+ *
7
+ * Licensed under the Apache License, Version 2.0 (the "License");
8
+ * you may not use this file except in compliance with the License.
9
+ * You may obtain a copy of the License at
10
+ *
11
+ * http://www.apache.org/licenses/LICENSE-2.0
12
+ */
13
+ !(function (e, t) {
14
+ 'object' == typeof exports && 'undefined' != typeof module
15
+ ? t(exports)
16
+ : 'function' == typeof define && define.amd
17
+ ? define(['exports'], t)
18
+ : t((e.dat = {}));
19
+ })(this, function (e) {
20
+ 'use strict';
21
+ function t(e, t) {
22
+ var n = e.__state.conversionName.toString(),
23
+ o = Math.round(e.r),
24
+ i = Math.round(e.g),
25
+ r = Math.round(e.b),
26
+ s = e.a,
27
+ a = Math.round(e.h),
28
+ l = e.s.toFixed(1),
29
+ d = e.v.toFixed(1);
30
+ if (t || 'THREE_CHAR_HEX' === n || 'SIX_CHAR_HEX' === n) {
31
+ for (var c = e.hex.toString(16); c.length < 6; ) c = '0' + c;
32
+ return '#' + c;
33
+ }
34
+ return 'CSS_RGB' === n
35
+ ? 'rgb(' + o + ',' + i + ',' + r + ')'
36
+ : 'CSS_RGBA' === n
37
+ ? 'rgba(' + o + ',' + i + ',' + r + ',' + s + ')'
38
+ : 'HEX' === n
39
+ ? '0x' + e.hex.toString(16)
40
+ : 'RGB_ARRAY' === n
41
+ ? '[' + o + ',' + i + ',' + r + ']'
42
+ : 'RGBA_ARRAY' === n
43
+ ? '[' + o + ',' + i + ',' + r + ',' + s + ']'
44
+ : 'RGB_OBJ' === n
45
+ ? '{r:' + o + ',g:' + i + ',b:' + r + '}'
46
+ : 'RGBA_OBJ' === n
47
+ ? '{r:' + o + ',g:' + i + ',b:' + r + ',a:' + s + '}'
48
+ : 'HSV_OBJ' === n
49
+ ? '{h:' + a + ',s:' + l + ',v:' + d + '}'
50
+ : 'HSVA_OBJ' === n
51
+ ? '{h:' + a + ',s:' + l + ',v:' + d + ',a:' + s + '}'
52
+ : 'unknown format';
53
+ }
54
+ function n(e, t, n) {
55
+ Object.defineProperty(e, t, {
56
+ get: function () {
57
+ return 'RGB' === this.__state.space
58
+ ? this.__state[t]
59
+ : (I.recalculateRGB(this, t, n), this.__state[t]);
60
+ },
61
+ set: function (e) {
62
+ 'RGB' !== this.__state.space &&
63
+ (I.recalculateRGB(this, t, n), (this.__state.space = 'RGB')),
64
+ (this.__state[t] = e);
65
+ },
66
+ });
67
+ }
68
+ function o(e, t) {
69
+ Object.defineProperty(e, t, {
70
+ get: function () {
71
+ return 'HSV' === this.__state.space
72
+ ? this.__state[t]
73
+ : (I.recalculateHSV(this), this.__state[t]);
74
+ },
75
+ set: function (e) {
76
+ 'HSV' !== this.__state.space &&
77
+ (I.recalculateHSV(this), (this.__state.space = 'HSV')),
78
+ (this.__state[t] = e);
79
+ },
80
+ });
81
+ }
82
+ function i(e) {
83
+ if ('0' === e || S.isUndefined(e)) return 0;
84
+ var t = e.match(U);
85
+ return S.isNull(t) ? 0 : parseFloat(t[1]);
86
+ }
87
+ function r(e) {
88
+ var t = e.toString();
89
+ return t.indexOf('.') > -1 ? t.length - t.indexOf('.') - 1 : 0;
90
+ }
91
+ function s(e, t) {
92
+ var n = Math.pow(10, t);
93
+ return Math.round(e * n) / n;
94
+ }
95
+ function a(e, t, n, o, i) {
96
+ return o + ((e - t) / (n - t)) * (i - o);
97
+ }
98
+ function l(e, t, n, o) {
99
+ (e.style.background = ''),
100
+ S.each(ee, function (i) {
101
+ e.style.cssText +=
102
+ 'background: ' +
103
+ i +
104
+ 'linear-gradient(' +
105
+ t +
106
+ ', ' +
107
+ n +
108
+ ' 0%, ' +
109
+ o +
110
+ ' 100%); ';
111
+ });
112
+ }
113
+ function d(e) {
114
+ (e.style.background = ''),
115
+ (e.style.cssText +=
116
+ 'background: -moz-linear-gradient(top, #ff0000 0%, #ff00ff 17%, #0000ff 34%, #00ffff 50%, #00ff00 67%, #ffff00 84%, #ff0000 100%);'),
117
+ (e.style.cssText +=
118
+ 'background: -webkit-linear-gradient(top, #ff0000 0%,#ff00ff 17%,#0000ff 34%,#00ffff 50%,#00ff00 67%,#ffff00 84%,#ff0000 100%);'),
119
+ (e.style.cssText +=
120
+ 'background: -o-linear-gradient(top, #ff0000 0%,#ff00ff 17%,#0000ff 34%,#00ffff 50%,#00ff00 67%,#ffff00 84%,#ff0000 100%);'),
121
+ (e.style.cssText +=
122
+ 'background: -ms-linear-gradient(top, #ff0000 0%,#ff00ff 17%,#0000ff 34%,#00ffff 50%,#00ff00 67%,#ffff00 84%,#ff0000 100%);'),
123
+ (e.style.cssText +=
124
+ 'background: linear-gradient(top, #ff0000 0%,#ff00ff 17%,#0000ff 34%,#00ffff 50%,#00ff00 67%,#ffff00 84%,#ff0000 100%);');
125
+ }
126
+ function c(e, t, n) {
127
+ var o = document.createElement('li');
128
+ return (
129
+ t && o.appendChild(t),
130
+ n ? e.__ul.insertBefore(o, n) : e.__ul.appendChild(o),
131
+ e.onResize(),
132
+ o
133
+ );
134
+ }
135
+ function u(e) {
136
+ X.unbind(window, 'resize', e.__resizeHandler),
137
+ e.saveToLocalStorageIfPossible &&
138
+ X.unbind(window, 'unload', e.saveToLocalStorageIfPossible);
139
+ }
140
+ function _(e, t) {
141
+ var n = e.__preset_select[e.__preset_select.selectedIndex];
142
+ n.innerHTML = t ? n.value + '*' : n.value;
143
+ }
144
+ function h(e, t, n) {
145
+ if (
146
+ ((n.__li = t),
147
+ (n.__gui = e),
148
+ S.extend(n, {
149
+ options: function (t) {
150
+ if (arguments.length > 1) {
151
+ var o = n.__li.nextElementSibling;
152
+ return (
153
+ n.remove(),
154
+ f(e, n.object, n.property, {
155
+ before: o,
156
+ factoryArgs: [S.toArray(arguments)],
157
+ })
158
+ );
159
+ }
160
+ if (S.isArray(t) || S.isObject(t)) {
161
+ var i = n.__li.nextElementSibling;
162
+ return (
163
+ n.remove(),
164
+ f(e, n.object, n.property, { before: i, factoryArgs: [t] })
165
+ );
166
+ }
167
+ },
168
+ name: function (e) {
169
+ return (n.__li.firstElementChild.firstElementChild.innerHTML = e), n;
170
+ },
171
+ listen: function () {
172
+ return n.__gui.listen(n), n;
173
+ },
174
+ remove: function () {
175
+ return n.__gui.remove(n), n;
176
+ },
177
+ }),
178
+ n instanceof q)
179
+ ) {
180
+ var o = new Q(n.object, n.property, {
181
+ min: n.__min,
182
+ max: n.__max,
183
+ step: n.__step,
184
+ });
185
+ S.each(
186
+ ['updateDisplay', 'onChange', 'onFinishChange', 'step'],
187
+ function (e) {
188
+ var t = n[e],
189
+ i = o[e];
190
+ n[e] = o[e] = function () {
191
+ var e = Array.prototype.slice.call(arguments);
192
+ return i.apply(o, e), t.apply(n, e);
193
+ };
194
+ }
195
+ ),
196
+ X.addClass(t, 'has-slider'),
197
+ n.domElement.insertBefore(o.domElement, n.domElement.firstElementChild);
198
+ } else if (n instanceof Q) {
199
+ var i = function (t) {
200
+ if (S.isNumber(n.__min) && S.isNumber(n.__max)) {
201
+ var o = n.__li.firstElementChild.firstElementChild.innerHTML,
202
+ i = n.__gui.__listening.indexOf(n) > -1;
203
+ n.remove();
204
+ var r = f(e, n.object, n.property, {
205
+ before: n.__li.nextElementSibling,
206
+ factoryArgs: [n.__min, n.__max, n.__step],
207
+ });
208
+ return r.name(o), i && r.listen(), r;
209
+ }
210
+ return t;
211
+ };
212
+ (n.min = S.compose(i, n.min)), (n.max = S.compose(i, n.max));
213
+ } else
214
+ n instanceof K
215
+ ? (X.bind(t, 'click', function () {
216
+ X.fakeEvent(n.__checkbox, 'click');
217
+ }),
218
+ X.bind(n.__checkbox, 'click', function (e) {
219
+ e.stopPropagation();
220
+ }))
221
+ : n instanceof Z
222
+ ? (X.bind(t, 'click', function () {
223
+ X.fakeEvent(n.__button, 'click');
224
+ }),
225
+ X.bind(t, 'mouseover', function () {
226
+ X.addClass(n.__button, 'hover');
227
+ }),
228
+ X.bind(t, 'mouseout', function () {
229
+ X.removeClass(n.__button, 'hover');
230
+ }))
231
+ : n instanceof $ &&
232
+ (X.addClass(t, 'color'),
233
+ (n.updateDisplay = S.compose(function (e) {
234
+ return (t.style.borderLeftColor = n.__color.toString()), e;
235
+ }, n.updateDisplay)),
236
+ n.updateDisplay());
237
+ n.setValue = S.compose(function (t) {
238
+ return (
239
+ e.getRoot().__preset_select && n.isModified() && _(e.getRoot(), !0), t
240
+ );
241
+ }, n.setValue);
242
+ }
243
+ function p(e, t) {
244
+ var n = e.getRoot(),
245
+ o = n.__rememberedObjects.indexOf(t.object);
246
+ if (-1 !== o) {
247
+ var i = n.__rememberedObjectIndecesToControllers[o];
248
+ if (
249
+ (void 0 === i &&
250
+ ((i = {}), (n.__rememberedObjectIndecesToControllers[o] = i)),
251
+ (i[t.property] = t),
252
+ n.load && n.load.remembered)
253
+ ) {
254
+ var r = n.load.remembered,
255
+ s = void 0;
256
+ if (r[e.preset]) s = r[e.preset];
257
+ else {
258
+ if (!r[se]) return;
259
+ s = r[se];
260
+ }
261
+ if (s[o] && void 0 !== s[o][t.property]) {
262
+ var a = s[o][t.property];
263
+ (t.initialValue = a), t.setValue(a);
264
+ }
265
+ }
266
+ }
267
+ }
268
+ function f(e, t, n, o) {
269
+ if (void 0 === t[n])
270
+ throw new Error('Object "' + t + '" has no property "' + n + '"');
271
+ var i = void 0;
272
+ if (o.color) i = new $(t, n);
273
+ else {
274
+ var r = [t, n].concat(o.factoryArgs);
275
+ i = ne.apply(e, r);
276
+ }
277
+ o.before instanceof z && (o.before = o.before.__li),
278
+ p(e, i),
279
+ X.addClass(i.domElement, 'c');
280
+ var s = document.createElement('span');
281
+ X.addClass(s, 'property-name'), (s.innerHTML = i.property);
282
+ var a = document.createElement('div');
283
+ a.appendChild(s), a.appendChild(i.domElement);
284
+ var l = c(e, a, o.before);
285
+ return (
286
+ X.addClass(l, he.CLASS_CONTROLLER_ROW),
287
+ i instanceof $ ? X.addClass(l, 'color') : X.addClass(l, H(i.getValue())),
288
+ h(e, l, i),
289
+ e.__controllers.push(i),
290
+ i
291
+ );
292
+ }
293
+ function m(e, t) {
294
+ return document.location.href + '.' + t;
295
+ }
296
+ function g(e, t, n) {
297
+ var o = document.createElement('option');
298
+ (o.innerHTML = t),
299
+ (o.value = t),
300
+ e.__preset_select.appendChild(o),
301
+ n && (e.__preset_select.selectedIndex = e.__preset_select.length - 1);
302
+ }
303
+ function b(e, t) {
304
+ t.style.display = e.useLocalStorage ? 'block' : 'none';
305
+ }
306
+ function v(e) {
307
+ var t = (e.__save_row = document.createElement('li'));
308
+ X.addClass(e.domElement, 'has-save'),
309
+ e.__ul.insertBefore(t, e.__ul.firstChild),
310
+ X.addClass(t, 'save-row');
311
+ var n = document.createElement('span');
312
+ (n.innerHTML = '&nbsp;'), X.addClass(n, 'button gears');
313
+ var o = document.createElement('span');
314
+ (o.innerHTML = 'Save'), X.addClass(o, 'button'), X.addClass(o, 'save');
315
+ var i = document.createElement('span');
316
+ (i.innerHTML = 'New'), X.addClass(i, 'button'), X.addClass(i, 'save-as');
317
+ var r = document.createElement('span');
318
+ (r.innerHTML = 'Revert'), X.addClass(r, 'button'), X.addClass(r, 'revert');
319
+ var s = (e.__preset_select = document.createElement('select'));
320
+ if (
321
+ (e.load && e.load.remembered
322
+ ? S.each(e.load.remembered, function (t, n) {
323
+ g(e, n, n === e.preset);
324
+ })
325
+ : g(e, se, !1),
326
+ X.bind(s, 'change', function () {
327
+ for (var t = 0; t < e.__preset_select.length; t++)
328
+ e.__preset_select[t].innerHTML = e.__preset_select[t].value;
329
+ e.preset = this.value;
330
+ }),
331
+ t.appendChild(s),
332
+ t.appendChild(n),
333
+ t.appendChild(o),
334
+ t.appendChild(i),
335
+ t.appendChild(r),
336
+ ae)
337
+ ) {
338
+ var a = document.getElementById('dg-local-explain'),
339
+ l = document.getElementById('dg-local-storage');
340
+ (document.getElementById('dg-save-locally').style.display = 'block'),
341
+ 'true' === localStorage.getItem(m(e, 'isLocal')) &&
342
+ l.setAttribute('checked', 'checked'),
343
+ b(e, a),
344
+ X.bind(l, 'change', function () {
345
+ (e.useLocalStorage = !e.useLocalStorage), b(e, a);
346
+ });
347
+ }
348
+ var d = document.getElementById('dg-new-constructor');
349
+ X.bind(d, 'keydown', function (e) {
350
+ !e.metaKey || (67 !== e.which && 67 !== e.keyCode) || le.hide();
351
+ }),
352
+ X.bind(n, 'click', function () {
353
+ (d.innerHTML = JSON.stringify(e.getSaveObject(), void 0, 2)),
354
+ le.show(),
355
+ d.focus(),
356
+ d.select();
357
+ }),
358
+ X.bind(o, 'click', function () {
359
+ e.save();
360
+ }),
361
+ X.bind(i, 'click', function () {
362
+ var t = prompt('Enter a new preset name.');
363
+ t && e.saveAs(t);
364
+ }),
365
+ X.bind(r, 'click', function () {
366
+ e.revert();
367
+ });
368
+ }
369
+ function y(e) {
370
+ function t(t) {
371
+ return (
372
+ t.preventDefault(),
373
+ (e.width += i - t.clientX),
374
+ e.onResize(),
375
+ (i = t.clientX),
376
+ !1
377
+ );
378
+ }
379
+ function n() {
380
+ X.removeClass(e.__closeButton, he.CLASS_DRAG),
381
+ X.unbind(window, 'mousemove', t),
382
+ X.unbind(window, 'mouseup', n);
383
+ }
384
+ function o(o) {
385
+ return (
386
+ o.preventDefault(),
387
+ (i = o.clientX),
388
+ X.addClass(e.__closeButton, he.CLASS_DRAG),
389
+ X.bind(window, 'mousemove', t),
390
+ X.bind(window, 'mouseup', n),
391
+ !1
392
+ );
393
+ }
394
+ var i = void 0;
395
+ (e.__resize_handle = document.createElement('div')),
396
+ S.extend(e.__resize_handle.style, {
397
+ width: '6px',
398
+ marginLeft: '-3px',
399
+ height: '200px',
400
+ cursor: 'ew-resize',
401
+ position: 'absolute',
402
+ }),
403
+ X.bind(e.__resize_handle, 'mousedown', o),
404
+ X.bind(e.__closeButton, 'mousedown', o),
405
+ e.domElement.insertBefore(
406
+ e.__resize_handle,
407
+ e.domElement.firstElementChild
408
+ );
409
+ }
410
+ function w(e, t) {
411
+ (e.domElement.style.width = t + 'px'),
412
+ e.__save_row && e.autoPlace && (e.__save_row.style.width = t + 'px'),
413
+ e.__closeButton && (e.__closeButton.style.width = t + 'px');
414
+ }
415
+ function x(e, t) {
416
+ var n = {};
417
+ return (
418
+ S.each(e.__rememberedObjects, function (o, i) {
419
+ var r = {},
420
+ s = e.__rememberedObjectIndecesToControllers[i];
421
+ S.each(s, function (e, n) {
422
+ r[n] = t ? e.initialValue : e.getValue();
423
+ }),
424
+ (n[i] = r);
425
+ }),
426
+ n
427
+ );
428
+ }
429
+ function E(e) {
430
+ for (var t = 0; t < e.__preset_select.length; t++)
431
+ e.__preset_select[t].value === e.preset &&
432
+ (e.__preset_select.selectedIndex = t);
433
+ }
434
+ function C(e) {
435
+ 0 !== e.length &&
436
+ oe.call(window, function () {
437
+ C(e);
438
+ }),
439
+ S.each(e, function (e) {
440
+ e.updateDisplay();
441
+ });
442
+ }
443
+ var A = Array.prototype.forEach,
444
+ k = Array.prototype.slice,
445
+ S = {
446
+ BREAK: {},
447
+ extend: function (e) {
448
+ return (
449
+ this.each(
450
+ k.call(arguments, 1),
451
+ function (t) {
452
+ (this.isObject(t) ? Object.keys(t) : []).forEach(
453
+ function (n) {
454
+ this.isUndefined(t[n]) || (e[n] = t[n]);
455
+ }.bind(this)
456
+ );
457
+ },
458
+ this
459
+ ),
460
+ e
461
+ );
462
+ },
463
+ defaults: function (e) {
464
+ return (
465
+ this.each(
466
+ k.call(arguments, 1),
467
+ function (t) {
468
+ (this.isObject(t) ? Object.keys(t) : []).forEach(
469
+ function (n) {
470
+ this.isUndefined(e[n]) && (e[n] = t[n]);
471
+ }.bind(this)
472
+ );
473
+ },
474
+ this
475
+ ),
476
+ e
477
+ );
478
+ },
479
+ compose: function () {
480
+ var e = k.call(arguments);
481
+ return function () {
482
+ for (var t = k.call(arguments), n = e.length - 1; n >= 0; n--)
483
+ t = [e[n].apply(this, t)];
484
+ return t[0];
485
+ };
486
+ },
487
+ each: function (e, t, n) {
488
+ if (e)
489
+ if (A && e.forEach && e.forEach === A) e.forEach(t, n);
490
+ else if (e.length === e.length + 0) {
491
+ var o = void 0,
492
+ i = void 0;
493
+ for (o = 0, i = e.length; o < i; o++)
494
+ if (o in e && t.call(n, e[o], o) === this.BREAK) return;
495
+ } else for (var r in e) if (t.call(n, e[r], r) === this.BREAK) return;
496
+ },
497
+ defer: function (e) {
498
+ setTimeout(e, 0);
499
+ },
500
+ debounce: function (e, t, n) {
501
+ var o = void 0;
502
+ return function () {
503
+ var i = this,
504
+ r = arguments,
505
+ s = n || !o;
506
+ clearTimeout(o),
507
+ (o = setTimeout(function () {
508
+ (o = null), n || e.apply(i, r);
509
+ }, t)),
510
+ s && e.apply(i, r);
511
+ };
512
+ },
513
+ toArray: function (e) {
514
+ return e.toArray ? e.toArray() : k.call(e);
515
+ },
516
+ isUndefined: function (e) {
517
+ return void 0 === e;
518
+ },
519
+ isNull: function (e) {
520
+ return null === e;
521
+ },
522
+ isNaN: (function (e) {
523
+ function t(t) {
524
+ return e.apply(this, arguments);
525
+ }
526
+ return (
527
+ (t.toString = function () {
528
+ return e.toString();
529
+ }),
530
+ t
531
+ );
532
+ })(function (e) {
533
+ return isNaN(e);
534
+ }),
535
+ isArray:
536
+ Array.isArray ||
537
+ function (e) {
538
+ return e.constructor === Array;
539
+ },
540
+ isObject: function (e) {
541
+ return e === Object(e);
542
+ },
543
+ isNumber: function (e) {
544
+ return e === e + 0;
545
+ },
546
+ isString: function (e) {
547
+ return e === e + '';
548
+ },
549
+ isBoolean: function (e) {
550
+ return !1 === e || !0 === e;
551
+ },
552
+ isFunction: function (e) {
553
+ return '[object Function]' === Object.prototype.toString.call(e);
554
+ },
555
+ },
556
+ O = [
557
+ {
558
+ litmus: S.isString,
559
+ conversions: {
560
+ THREE_CHAR_HEX: {
561
+ read: function (e) {
562
+ var t = e.match(/^#([A-F0-9])([A-F0-9])([A-F0-9])$/i);
563
+ return (
564
+ null !== t && {
565
+ space: 'HEX',
566
+ hex: parseInt(
567
+ '0x' +
568
+ t[1].toString() +
569
+ t[1].toString() +
570
+ t[2].toString() +
571
+ t[2].toString() +
572
+ t[3].toString() +
573
+ t[3].toString(),
574
+ 0
575
+ ),
576
+ }
577
+ );
578
+ },
579
+ write: t,
580
+ },
581
+ SIX_CHAR_HEX: {
582
+ read: function (e) {
583
+ var t = e.match(/^#([A-F0-9]{6})$/i);
584
+ return (
585
+ null !== t && {
586
+ space: 'HEX',
587
+ hex: parseInt('0x' + t[1].toString(), 0),
588
+ }
589
+ );
590
+ },
591
+ write: t,
592
+ },
593
+ CSS_RGB: {
594
+ read: function (e) {
595
+ var t = e.match(/^rgb\(\s*(.+)\s*,\s*(.+)\s*,\s*(.+)\s*\)/);
596
+ return (
597
+ null !== t && {
598
+ space: 'RGB',
599
+ r: parseFloat(t[1]),
600
+ g: parseFloat(t[2]),
601
+ b: parseFloat(t[3]),
602
+ }
603
+ );
604
+ },
605
+ write: t,
606
+ },
607
+ CSS_RGBA: {
608
+ read: function (e) {
609
+ var t = e.match(
610
+ /^rgba\(\s*(.+)\s*,\s*(.+)\s*,\s*(.+)\s*,\s*(.+)\s*\)/
611
+ );
612
+ return (
613
+ null !== t && {
614
+ space: 'RGB',
615
+ r: parseFloat(t[1]),
616
+ g: parseFloat(t[2]),
617
+ b: parseFloat(t[3]),
618
+ a: parseFloat(t[4]),
619
+ }
620
+ );
621
+ },
622
+ write: t,
623
+ },
624
+ },
625
+ },
626
+ {
627
+ litmus: S.isNumber,
628
+ conversions: {
629
+ HEX: {
630
+ read: function (e) {
631
+ return { space: 'HEX', hex: e, conversionName: 'HEX' };
632
+ },
633
+ write: function (e) {
634
+ return e.hex;
635
+ },
636
+ },
637
+ },
638
+ },
639
+ {
640
+ litmus: S.isArray,
641
+ conversions: {
642
+ RGB_ARRAY: {
643
+ read: function (e) {
644
+ return (
645
+ 3 === e.length && { space: 'RGB', r: e[0], g: e[1], b: e[2] }
646
+ );
647
+ },
648
+ write: function (e) {
649
+ return [e.r, e.g, e.b];
650
+ },
651
+ },
652
+ RGBA_ARRAY: {
653
+ read: function (e) {
654
+ return (
655
+ 4 === e.length && {
656
+ space: 'RGB',
657
+ r: e[0],
658
+ g: e[1],
659
+ b: e[2],
660
+ a: e[3],
661
+ }
662
+ );
663
+ },
664
+ write: function (e) {
665
+ return [e.r, e.g, e.b, e.a];
666
+ },
667
+ },
668
+ },
669
+ },
670
+ {
671
+ litmus: S.isObject,
672
+ conversions: {
673
+ RGBA_OBJ: {
674
+ read: function (e) {
675
+ return (
676
+ !!(
677
+ S.isNumber(e.r) &&
678
+ S.isNumber(e.g) &&
679
+ S.isNumber(e.b) &&
680
+ S.isNumber(e.a)
681
+ ) && {
682
+ space: 'RGB',
683
+ r: e.r,
684
+ g: e.g,
685
+ b: e.b,
686
+ a: e.a,
687
+ }
688
+ );
689
+ },
690
+ write: function (e) {
691
+ return { r: e.r, g: e.g, b: e.b, a: e.a };
692
+ },
693
+ },
694
+ RGB_OBJ: {
695
+ read: function (e) {
696
+ return (
697
+ !!(S.isNumber(e.r) && S.isNumber(e.g) && S.isNumber(e.b)) && {
698
+ space: 'RGB',
699
+ r: e.r,
700
+ g: e.g,
701
+ b: e.b,
702
+ }
703
+ );
704
+ },
705
+ write: function (e) {
706
+ return { r: e.r, g: e.g, b: e.b };
707
+ },
708
+ },
709
+ HSVA_OBJ: {
710
+ read: function (e) {
711
+ return (
712
+ !!(
713
+ S.isNumber(e.h) &&
714
+ S.isNumber(e.s) &&
715
+ S.isNumber(e.v) &&
716
+ S.isNumber(e.a)
717
+ ) && {
718
+ space: 'HSV',
719
+ h: e.h,
720
+ s: e.s,
721
+ v: e.v,
722
+ a: e.a,
723
+ }
724
+ );
725
+ },
726
+ write: function (e) {
727
+ return { h: e.h, s: e.s, v: e.v, a: e.a };
728
+ },
729
+ },
730
+ HSV_OBJ: {
731
+ read: function (e) {
732
+ return (
733
+ !!(S.isNumber(e.h) && S.isNumber(e.s) && S.isNumber(e.v)) && {
734
+ space: 'HSV',
735
+ h: e.h,
736
+ s: e.s,
737
+ v: e.v,
738
+ }
739
+ );
740
+ },
741
+ write: function (e) {
742
+ return { h: e.h, s: e.s, v: e.v };
743
+ },
744
+ },
745
+ },
746
+ },
747
+ ],
748
+ T = void 0,
749
+ R = void 0,
750
+ L = function () {
751
+ R = !1;
752
+ var e = arguments.length > 1 ? S.toArray(arguments) : arguments[0];
753
+ return (
754
+ S.each(O, function (t) {
755
+ if (t.litmus(e))
756
+ return (
757
+ S.each(t.conversions, function (t, n) {
758
+ if (((T = t.read(e)), !1 === R && !1 !== T))
759
+ return (
760
+ (R = T), (T.conversionName = n), (T.conversion = t), S.BREAK
761
+ );
762
+ }),
763
+ S.BREAK
764
+ );
765
+ }),
766
+ R
767
+ );
768
+ },
769
+ B = void 0,
770
+ N = {
771
+ hsv_to_rgb: function (e, t, n) {
772
+ var o = Math.floor(e / 60) % 6,
773
+ i = e / 60 - Math.floor(e / 60),
774
+ r = n * (1 - t),
775
+ s = n * (1 - i * t),
776
+ a = n * (1 - (1 - i) * t),
777
+ l = [
778
+ [n, a, r],
779
+ [s, n, r],
780
+ [r, n, a],
781
+ [r, s, n],
782
+ [a, r, n],
783
+ [n, r, s],
784
+ ][o];
785
+ return { r: 255 * l[0], g: 255 * l[1], b: 255 * l[2] };
786
+ },
787
+ rgb_to_hsv: function (e, t, n) {
788
+ var o = Math.min(e, t, n),
789
+ i = Math.max(e, t, n),
790
+ r = i - o,
791
+ s = void 0,
792
+ a = void 0;
793
+ return 0 === i
794
+ ? { h: NaN, s: 0, v: 0 }
795
+ : ((a = r / i),
796
+ (s =
797
+ e === i
798
+ ? (t - n) / r
799
+ : t === i
800
+ ? 2 + (n - e) / r
801
+ : 4 + (e - t) / r),
802
+ (s /= 6) < 0 && (s += 1),
803
+ { h: 360 * s, s: a, v: i / 255 });
804
+ },
805
+ rgb_to_hex: function (e, t, n) {
806
+ var o = this.hex_with_component(0, 2, e);
807
+ return (
808
+ (o = this.hex_with_component(o, 1, t)),
809
+ (o = this.hex_with_component(o, 0, n))
810
+ );
811
+ },
812
+ component_from_hex: function (e, t) {
813
+ return (e >> (8 * t)) & 255;
814
+ },
815
+ hex_with_component: function (e, t, n) {
816
+ return (n << (B = 8 * t)) | (e & ~(255 << B));
817
+ },
818
+ },
819
+ H =
820
+ 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator
821
+ ? function (e) {
822
+ return typeof e;
823
+ }
824
+ : function (e) {
825
+ return e &&
826
+ 'function' == typeof Symbol &&
827
+ e.constructor === Symbol &&
828
+ e !== Symbol.prototype
829
+ ? 'symbol'
830
+ : typeof e;
831
+ },
832
+ F = function (e, t) {
833
+ if (!(e instanceof t))
834
+ throw new TypeError('Cannot call a class as a function');
835
+ },
836
+ P = (function () {
837
+ function e(e, t) {
838
+ for (var n = 0; n < t.length; n++) {
839
+ var o = t[n];
840
+ (o.enumerable = o.enumerable || !1),
841
+ (o.configurable = !0),
842
+ 'value' in o && (o.writable = !0),
843
+ Object.defineProperty(e, o.key, o);
844
+ }
845
+ }
846
+ return function (t, n, o) {
847
+ return n && e(t.prototype, n), o && e(t, o), t;
848
+ };
849
+ })(),
850
+ j = function e(t, n, o) {
851
+ null === t && (t = Function.prototype);
852
+ var i = Object.getOwnPropertyDescriptor(t, n);
853
+ if (void 0 === i) {
854
+ var r = Object.getPrototypeOf(t);
855
+ return null === r ? void 0 : e(r, n, o);
856
+ }
857
+ if ('value' in i) return i.value;
858
+ var s = i.get;
859
+ if (void 0 !== s) return s.call(o);
860
+ },
861
+ D = function (e, t) {
862
+ if ('function' != typeof t && null !== t)
863
+ throw new TypeError(
864
+ 'Super expression must either be null or a function, not ' + typeof t
865
+ );
866
+ (e.prototype = Object.create(t && t.prototype, {
867
+ constructor: {
868
+ value: e,
869
+ enumerable: !1,
870
+ writable: !0,
871
+ configurable: !0,
872
+ },
873
+ })),
874
+ t &&
875
+ (Object.setPrototypeOf
876
+ ? Object.setPrototypeOf(e, t)
877
+ : (e.__proto__ = t));
878
+ },
879
+ V = function (e, t) {
880
+ if (!e)
881
+ throw new ReferenceError(
882
+ "this hasn't been initialised - super() hasn't been called"
883
+ );
884
+ return !t || ('object' != typeof t && 'function' != typeof t) ? e : t;
885
+ },
886
+ I = (function () {
887
+ function e() {
888
+ if (
889
+ (F(this, e),
890
+ (this.__state = L.apply(this, arguments)),
891
+ !1 === this.__state)
892
+ )
893
+ throw new Error('Failed to interpret color arguments');
894
+ this.__state.a = this.__state.a || 1;
895
+ }
896
+ return (
897
+ P(e, [
898
+ {
899
+ key: 'toString',
900
+ value: function () {
901
+ return t(this);
902
+ },
903
+ },
904
+ {
905
+ key: 'toHexString',
906
+ value: function () {
907
+ return t(this, !0);
908
+ },
909
+ },
910
+ {
911
+ key: 'toOriginal',
912
+ value: function () {
913
+ return this.__state.conversion.write(this);
914
+ },
915
+ },
916
+ ]),
917
+ e
918
+ );
919
+ })();
920
+ (I.recalculateRGB = function (e, t, n) {
921
+ if ('HEX' === e.__state.space)
922
+ e.__state[t] = N.component_from_hex(e.__state.hex, n);
923
+ else {
924
+ if ('HSV' !== e.__state.space) throw new Error('Corrupted color state');
925
+ S.extend(e.__state, N.hsv_to_rgb(e.__state.h, e.__state.s, e.__state.v));
926
+ }
927
+ }),
928
+ (I.recalculateHSV = function (e) {
929
+ var t = N.rgb_to_hsv(e.r, e.g, e.b);
930
+ S.extend(e.__state, { s: t.s, v: t.v }),
931
+ S.isNaN(t.h)
932
+ ? S.isUndefined(e.__state.h) && (e.__state.h = 0)
933
+ : (e.__state.h = t.h);
934
+ }),
935
+ (I.COMPONENTS = ['r', 'g', 'b', 'h', 's', 'v', 'hex', 'a']),
936
+ n(I.prototype, 'r', 2),
937
+ n(I.prototype, 'g', 1),
938
+ n(I.prototype, 'b', 0),
939
+ o(I.prototype, 'h'),
940
+ o(I.prototype, 's'),
941
+ o(I.prototype, 'v'),
942
+ Object.defineProperty(I.prototype, 'a', {
943
+ get: function () {
944
+ return this.__state.a;
945
+ },
946
+ set: function (e) {
947
+ this.__state.a = e;
948
+ },
949
+ }),
950
+ Object.defineProperty(I.prototype, 'hex', {
951
+ get: function () {
952
+ return (
953
+ 'HEX' !== !this.__state.space &&
954
+ (this.__state.hex = N.rgb_to_hex(this.r, this.g, this.b)),
955
+ this.__state.hex
956
+ );
957
+ },
958
+ set: function (e) {
959
+ (this.__state.space = 'HEX'), (this.__state.hex = e);
960
+ },
961
+ });
962
+ var z = (function () {
963
+ function e(t, n) {
964
+ F(this, e),
965
+ (this.initialValue = t[n]),
966
+ (this.domElement = document.createElement('div')),
967
+ (this.object = t),
968
+ (this.property = n),
969
+ (this.__onChange = void 0),
970
+ (this.__onFinishChange = void 0);
971
+ }
972
+ return (
973
+ P(e, [
974
+ {
975
+ key: 'onChange',
976
+ value: function (e) {
977
+ return (this.__onChange = e), this;
978
+ },
979
+ },
980
+ {
981
+ key: 'onFinishChange',
982
+ value: function (e) {
983
+ return (this.__onFinishChange = e), this;
984
+ },
985
+ },
986
+ {
987
+ key: 'setValue',
988
+ value: function (e) {
989
+ return (
990
+ (this.object[this.property] = e),
991
+ this.__onChange && this.__onChange.call(this, e),
992
+ this.updateDisplay(),
993
+ this
994
+ );
995
+ },
996
+ },
997
+ {
998
+ key: 'getValue',
999
+ value: function () {
1000
+ return this.object[this.property];
1001
+ },
1002
+ },
1003
+ {
1004
+ key: 'updateDisplay',
1005
+ value: function () {
1006
+ return this;
1007
+ },
1008
+ },
1009
+ {
1010
+ key: 'isModified',
1011
+ value: function () {
1012
+ return this.initialValue !== this.getValue();
1013
+ },
1014
+ },
1015
+ ]),
1016
+ e
1017
+ );
1018
+ })(),
1019
+ M = {
1020
+ HTMLEvents: ['change'],
1021
+ MouseEvents: ['click', 'mousemove', 'mousedown', 'mouseup', 'mouseover'],
1022
+ KeyboardEvents: ['keydown'],
1023
+ },
1024
+ G = {};
1025
+ S.each(M, function (e, t) {
1026
+ S.each(e, function (e) {
1027
+ G[e] = t;
1028
+ });
1029
+ });
1030
+ var U = /(\d+(\.\d+)?)px/,
1031
+ X = {
1032
+ makeSelectable: function (e, t) {
1033
+ void 0 !== e &&
1034
+ void 0 !== e.style &&
1035
+ ((e.onselectstart = t
1036
+ ? function () {
1037
+ return !1;
1038
+ }
1039
+ : function () {}),
1040
+ (e.style.MozUserSelect = t ? 'auto' : 'none'),
1041
+ (e.style.KhtmlUserSelect = t ? 'auto' : 'none'),
1042
+ (e.unselectable = t ? 'on' : 'off'));
1043
+ },
1044
+ makeFullscreen: function (e, t, n) {
1045
+ var o = n,
1046
+ i = t;
1047
+ S.isUndefined(i) && (i = !0),
1048
+ S.isUndefined(o) && (o = !0),
1049
+ (e.style.position = 'absolute'),
1050
+ i && ((e.style.left = 0), (e.style.right = 0)),
1051
+ o && ((e.style.top = 0), (e.style.bottom = 0));
1052
+ },
1053
+ fakeEvent: function (e, t, n, o) {
1054
+ var i = n || {},
1055
+ r = G[t];
1056
+ if (!r) throw new Error('Event type ' + t + ' not supported.');
1057
+ var s = document.createEvent(r);
1058
+ switch (r) {
1059
+ case 'MouseEvents':
1060
+ var a = i.x || i.clientX || 0,
1061
+ l = i.y || i.clientY || 0;
1062
+ s.initMouseEvent(
1063
+ t,
1064
+ i.bubbles || !1,
1065
+ i.cancelable || !0,
1066
+ window,
1067
+ i.clickCount || 1,
1068
+ 0,
1069
+ 0,
1070
+ a,
1071
+ l,
1072
+ !1,
1073
+ !1,
1074
+ !1,
1075
+ !1,
1076
+ 0,
1077
+ null
1078
+ );
1079
+ break;
1080
+ case 'KeyboardEvents':
1081
+ var d = s.initKeyboardEvent || s.initKeyEvent;
1082
+ S.defaults(i, {
1083
+ cancelable: !0,
1084
+ ctrlKey: !1,
1085
+ altKey: !1,
1086
+ shiftKey: !1,
1087
+ metaKey: !1,
1088
+ keyCode: void 0,
1089
+ charCode: void 0,
1090
+ }),
1091
+ d(
1092
+ t,
1093
+ i.bubbles || !1,
1094
+ i.cancelable,
1095
+ window,
1096
+ i.ctrlKey,
1097
+ i.altKey,
1098
+ i.shiftKey,
1099
+ i.metaKey,
1100
+ i.keyCode,
1101
+ i.charCode
1102
+ );
1103
+ break;
1104
+ default:
1105
+ s.initEvent(t, i.bubbles || !1, i.cancelable || !0);
1106
+ }
1107
+ S.defaults(s, o), e.dispatchEvent(s);
1108
+ },
1109
+ bind: function (e, t, n, o) {
1110
+ var i = o || !1;
1111
+ return (
1112
+ e.addEventListener
1113
+ ? e.addEventListener(t, n, i)
1114
+ : e.attachEvent && e.attachEvent('on' + t, n),
1115
+ X
1116
+ );
1117
+ },
1118
+ unbind: function (e, t, n, o) {
1119
+ var i = o || !1;
1120
+ return (
1121
+ e.removeEventListener
1122
+ ? e.removeEventListener(t, n, i)
1123
+ : e.detachEvent && e.detachEvent('on' + t, n),
1124
+ X
1125
+ );
1126
+ },
1127
+ addClass: function (e, t) {
1128
+ if (void 0 === e.className) e.className = t;
1129
+ else if (e.className !== t) {
1130
+ var n = e.className.split(/ +/);
1131
+ -1 === n.indexOf(t) &&
1132
+ (n.push(t),
1133
+ (e.className = n
1134
+ .join(' ')
1135
+ .replace(/^\s+/, '')
1136
+ .replace(/\s+$/, '')));
1137
+ }
1138
+ return X;
1139
+ },
1140
+ removeClass: function (e, t) {
1141
+ if (t)
1142
+ if (e.className === t) e.removeAttribute('class');
1143
+ else {
1144
+ var n = e.className.split(/ +/),
1145
+ o = n.indexOf(t);
1146
+ -1 !== o && (n.splice(o, 1), (e.className = n.join(' ')));
1147
+ }
1148
+ else e.className = void 0;
1149
+ return X;
1150
+ },
1151
+ hasClass: function (e, t) {
1152
+ return (
1153
+ new RegExp('(?:^|\\s+)' + t + '(?:\\s+|$)').test(e.className) || !1
1154
+ );
1155
+ },
1156
+ getWidth: function (e) {
1157
+ var t = getComputedStyle(e);
1158
+ return (
1159
+ i(t['border-left-width']) +
1160
+ i(t['border-right-width']) +
1161
+ i(t['padding-left']) +
1162
+ i(t['padding-right']) +
1163
+ i(t.width)
1164
+ );
1165
+ },
1166
+ getHeight: function (e) {
1167
+ var t = getComputedStyle(e);
1168
+ return (
1169
+ i(t['border-top-width']) +
1170
+ i(t['border-bottom-width']) +
1171
+ i(t['padding-top']) +
1172
+ i(t['padding-bottom']) +
1173
+ i(t.height)
1174
+ );
1175
+ },
1176
+ getOffset: function (e) {
1177
+ var t = e,
1178
+ n = { left: 0, top: 0 };
1179
+ if (t.offsetParent)
1180
+ do {
1181
+ (n.left += t.offsetLeft),
1182
+ (n.top += t.offsetTop),
1183
+ (t = t.offsetParent);
1184
+ } while (t);
1185
+ return n;
1186
+ },
1187
+ isActive: function (e) {
1188
+ return e === document.activeElement && (e.type || e.href);
1189
+ },
1190
+ },
1191
+ K = (function (e) {
1192
+ function t(e, n) {
1193
+ F(this, t);
1194
+ var o = V(
1195
+ this,
1196
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n)
1197
+ ),
1198
+ i = o;
1199
+ return (
1200
+ (o.__prev = o.getValue()),
1201
+ (o.__checkbox = document.createElement('input')),
1202
+ o.__checkbox.setAttribute('type', 'checkbox'),
1203
+ X.bind(
1204
+ o.__checkbox,
1205
+ 'change',
1206
+ function () {
1207
+ i.setValue(!i.__prev);
1208
+ },
1209
+ !1
1210
+ ),
1211
+ o.domElement.appendChild(o.__checkbox),
1212
+ o.updateDisplay(),
1213
+ o
1214
+ );
1215
+ }
1216
+ return (
1217
+ D(t, z),
1218
+ P(t, [
1219
+ {
1220
+ key: 'setValue',
1221
+ value: function (e) {
1222
+ var n = j(
1223
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1224
+ 'setValue',
1225
+ this
1226
+ ).call(this, e);
1227
+ return (
1228
+ this.__onFinishChange &&
1229
+ this.__onFinishChange.call(this, this.getValue()),
1230
+ (this.__prev = this.getValue()),
1231
+ n
1232
+ );
1233
+ },
1234
+ },
1235
+ {
1236
+ key: 'updateDisplay',
1237
+ value: function () {
1238
+ return (
1239
+ !0 === this.getValue()
1240
+ ? (this.__checkbox.setAttribute('checked', 'checked'),
1241
+ (this.__checkbox.checked = !0),
1242
+ (this.__prev = !0))
1243
+ : ((this.__checkbox.checked = !1), (this.__prev = !1)),
1244
+ j(
1245
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1246
+ 'updateDisplay',
1247
+ this
1248
+ ).call(this)
1249
+ );
1250
+ },
1251
+ },
1252
+ ]),
1253
+ t
1254
+ );
1255
+ })(),
1256
+ Y = (function (e) {
1257
+ function t(e, n, o) {
1258
+ F(this, t);
1259
+ var i = V(
1260
+ this,
1261
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n)
1262
+ ),
1263
+ r = o,
1264
+ s = i;
1265
+ if (((i.__select = document.createElement('select')), S.isArray(r))) {
1266
+ var a = {};
1267
+ S.each(r, function (e) {
1268
+ a[e] = e;
1269
+ }),
1270
+ (r = a);
1271
+ }
1272
+ return (
1273
+ S.each(r, function (e, t) {
1274
+ var n = document.createElement('option');
1275
+ (n.innerHTML = t),
1276
+ n.setAttribute('value', e),
1277
+ s.__select.appendChild(n);
1278
+ }),
1279
+ i.updateDisplay(),
1280
+ X.bind(i.__select, 'change', function () {
1281
+ var e = this.options[this.selectedIndex].value;
1282
+ s.setValue(e);
1283
+ }),
1284
+ i.domElement.appendChild(i.__select),
1285
+ i
1286
+ );
1287
+ }
1288
+ return (
1289
+ D(t, z),
1290
+ P(t, [
1291
+ {
1292
+ key: 'setValue',
1293
+ value: function (e) {
1294
+ var n = j(
1295
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1296
+ 'setValue',
1297
+ this
1298
+ ).call(this, e);
1299
+ return (
1300
+ this.__onFinishChange &&
1301
+ this.__onFinishChange.call(this, this.getValue()),
1302
+ n
1303
+ );
1304
+ },
1305
+ },
1306
+ {
1307
+ key: 'updateDisplay',
1308
+ value: function () {
1309
+ return X.isActive(this.__select)
1310
+ ? this
1311
+ : ((this.__select.value = this.getValue()),
1312
+ j(
1313
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1314
+ 'updateDisplay',
1315
+ this
1316
+ ).call(this));
1317
+ },
1318
+ },
1319
+ ]),
1320
+ t
1321
+ );
1322
+ })(),
1323
+ J = (function (e) {
1324
+ function t(e, n) {
1325
+ function o() {
1326
+ r.setValue(r.__input.value);
1327
+ }
1328
+ F(this, t);
1329
+ var i = V(
1330
+ this,
1331
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n)
1332
+ ),
1333
+ r = i;
1334
+ return (
1335
+ (i.__input = document.createElement('input')),
1336
+ i.__input.setAttribute('type', 'text'),
1337
+ X.bind(i.__input, 'keyup', o),
1338
+ X.bind(i.__input, 'change', o),
1339
+ X.bind(i.__input, 'blur', function () {
1340
+ r.__onFinishChange && r.__onFinishChange.call(r, r.getValue());
1341
+ }),
1342
+ X.bind(i.__input, 'keydown', function (e) {
1343
+ 13 === e.keyCode && this.blur();
1344
+ }),
1345
+ i.updateDisplay(),
1346
+ i.domElement.appendChild(i.__input),
1347
+ i
1348
+ );
1349
+ }
1350
+ return (
1351
+ D(t, z),
1352
+ P(t, [
1353
+ {
1354
+ key: 'updateDisplay',
1355
+ value: function () {
1356
+ return (
1357
+ X.isActive(this.__input) ||
1358
+ (this.__input.value = this.getValue()),
1359
+ j(
1360
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1361
+ 'updateDisplay',
1362
+ this
1363
+ ).call(this)
1364
+ );
1365
+ },
1366
+ },
1367
+ ]),
1368
+ t
1369
+ );
1370
+ })(),
1371
+ W = (function (e) {
1372
+ function t(e, n, o) {
1373
+ F(this, t);
1374
+ var i = V(
1375
+ this,
1376
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n)
1377
+ ),
1378
+ s = o || {};
1379
+ return (
1380
+ (i.__min = s.min),
1381
+ (i.__max = s.max),
1382
+ (i.__step = s.step),
1383
+ S.isUndefined(i.__step)
1384
+ ? 0 === i.initialValue
1385
+ ? (i.__impliedStep = 1)
1386
+ : (i.__impliedStep =
1387
+ Math.pow(
1388
+ 10,
1389
+ Math.floor(Math.log(Math.abs(i.initialValue)) / Math.LN10)
1390
+ ) / 10)
1391
+ : (i.__impliedStep = i.__step),
1392
+ (i.__precision = r(i.__impliedStep)),
1393
+ i
1394
+ );
1395
+ }
1396
+ return (
1397
+ D(t, z),
1398
+ P(t, [
1399
+ {
1400
+ key: 'setValue',
1401
+ value: function (e) {
1402
+ var n = e;
1403
+ return (
1404
+ void 0 !== this.__min && n < this.__min
1405
+ ? (n = this.__min)
1406
+ : void 0 !== this.__max && n > this.__max && (n = this.__max),
1407
+ void 0 !== this.__step &&
1408
+ n % this.__step != 0 &&
1409
+ (n = Math.round(n / this.__step) * this.__step),
1410
+ j(
1411
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1412
+ 'setValue',
1413
+ this
1414
+ ).call(this, n)
1415
+ );
1416
+ },
1417
+ },
1418
+ {
1419
+ key: 'min',
1420
+ value: function (e) {
1421
+ return (this.__min = e), this;
1422
+ },
1423
+ },
1424
+ {
1425
+ key: 'max',
1426
+ value: function (e) {
1427
+ return (this.__max = e), this;
1428
+ },
1429
+ },
1430
+ {
1431
+ key: 'step',
1432
+ value: function (e) {
1433
+ return (
1434
+ (this.__step = e),
1435
+ (this.__impliedStep = e),
1436
+ (this.__precision = r(e)),
1437
+ this
1438
+ );
1439
+ },
1440
+ },
1441
+ ]),
1442
+ t
1443
+ );
1444
+ })(),
1445
+ Q = (function (e) {
1446
+ function t(e, n, o) {
1447
+ function i() {
1448
+ l.__onFinishChange && l.__onFinishChange.call(l, l.getValue());
1449
+ }
1450
+ function r(e) {
1451
+ var t = d - e.clientY;
1452
+ l.setValue(l.getValue() + t * l.__impliedStep), (d = e.clientY);
1453
+ }
1454
+ function s() {
1455
+ X.unbind(window, 'mousemove', r), X.unbind(window, 'mouseup', s), i();
1456
+ }
1457
+ F(this, t);
1458
+ var a = V(
1459
+ this,
1460
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n, o)
1461
+ );
1462
+ a.__truncationSuspended = !1;
1463
+ var l = a,
1464
+ d = void 0;
1465
+ return (
1466
+ (a.__input = document.createElement('input')),
1467
+ a.__input.setAttribute('type', 'text'),
1468
+ X.bind(a.__input, 'change', function () {
1469
+ var e = parseFloat(l.__input.value);
1470
+ S.isNaN(e) || l.setValue(e);
1471
+ }),
1472
+ X.bind(a.__input, 'blur', function () {
1473
+ i();
1474
+ }),
1475
+ X.bind(a.__input, 'mousedown', function (e) {
1476
+ X.bind(window, 'mousemove', r),
1477
+ X.bind(window, 'mouseup', s),
1478
+ (d = e.clientY);
1479
+ }),
1480
+ X.bind(a.__input, 'keydown', function (e) {
1481
+ 13 === e.keyCode &&
1482
+ ((l.__truncationSuspended = !0),
1483
+ this.blur(),
1484
+ (l.__truncationSuspended = !1),
1485
+ i());
1486
+ }),
1487
+ a.updateDisplay(),
1488
+ a.domElement.appendChild(a.__input),
1489
+ a
1490
+ );
1491
+ }
1492
+ return (
1493
+ D(t, W),
1494
+ P(t, [
1495
+ {
1496
+ key: 'updateDisplay',
1497
+ value: function () {
1498
+ return (
1499
+ (this.__input.value = this.__truncationSuspended
1500
+ ? this.getValue()
1501
+ : s(this.getValue(), this.__precision)),
1502
+ j(
1503
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1504
+ 'updateDisplay',
1505
+ this
1506
+ ).call(this)
1507
+ );
1508
+ },
1509
+ },
1510
+ ]),
1511
+ t
1512
+ );
1513
+ })(),
1514
+ q = (function (e) {
1515
+ function t(e, n, o, i, r) {
1516
+ function s(e) {
1517
+ e.preventDefault();
1518
+ var t = _.__background.getBoundingClientRect();
1519
+ return (
1520
+ _.setValue(a(e.clientX, t.left, t.right, _.__min, _.__max)), !1
1521
+ );
1522
+ }
1523
+ function l() {
1524
+ X.unbind(window, 'mousemove', s),
1525
+ X.unbind(window, 'mouseup', l),
1526
+ _.__onFinishChange && _.__onFinishChange.call(_, _.getValue());
1527
+ }
1528
+ function d(e) {
1529
+ var t = e.touches[0].clientX,
1530
+ n = _.__background.getBoundingClientRect();
1531
+ _.setValue(a(t, n.left, n.right, _.__min, _.__max));
1532
+ }
1533
+ function c() {
1534
+ X.unbind(window, 'touchmove', d),
1535
+ X.unbind(window, 'touchend', c),
1536
+ _.__onFinishChange && _.__onFinishChange.call(_, _.getValue());
1537
+ }
1538
+ F(this, t);
1539
+ var u = V(
1540
+ this,
1541
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n, {
1542
+ min: o,
1543
+ max: i,
1544
+ step: r,
1545
+ })
1546
+ ),
1547
+ _ = u;
1548
+ return (
1549
+ (u.__background = document.createElement('div')),
1550
+ (u.__foreground = document.createElement('div')),
1551
+ X.bind(u.__background, 'mousedown', function (e) {
1552
+ document.activeElement.blur(),
1553
+ X.bind(window, 'mousemove', s),
1554
+ X.bind(window, 'mouseup', l),
1555
+ s(e);
1556
+ }),
1557
+ X.bind(u.__background, 'touchstart', function (e) {
1558
+ 1 === e.touches.length &&
1559
+ (X.bind(window, 'touchmove', d),
1560
+ X.bind(window, 'touchend', c),
1561
+ d(e));
1562
+ }),
1563
+ X.addClass(u.__background, 'slider'),
1564
+ X.addClass(u.__foreground, 'slider-fg'),
1565
+ u.updateDisplay(),
1566
+ u.__background.appendChild(u.__foreground),
1567
+ u.domElement.appendChild(u.__background),
1568
+ u
1569
+ );
1570
+ }
1571
+ return (
1572
+ D(t, W),
1573
+ P(t, [
1574
+ {
1575
+ key: 'updateDisplay',
1576
+ value: function () {
1577
+ var e =
1578
+ (this.getValue() - this.__min) / (this.__max - this.__min);
1579
+ return (
1580
+ (this.__foreground.style.width = 100 * e + '%'),
1581
+ j(
1582
+ t.prototype.__proto__ || Object.getPrototypeOf(t.prototype),
1583
+ 'updateDisplay',
1584
+ this
1585
+ ).call(this)
1586
+ );
1587
+ },
1588
+ },
1589
+ ]),
1590
+ t
1591
+ );
1592
+ })(),
1593
+ Z = (function (e) {
1594
+ function t(e, n, o) {
1595
+ F(this, t);
1596
+ var i = V(
1597
+ this,
1598
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n)
1599
+ ),
1600
+ r = i;
1601
+ return (
1602
+ (i.__button = document.createElement('div')),
1603
+ (i.__button.innerHTML = void 0 === o ? 'Fire' : o),
1604
+ X.bind(i.__button, 'click', function (e) {
1605
+ return e.preventDefault(), r.fire(), !1;
1606
+ }),
1607
+ X.addClass(i.__button, 'button'),
1608
+ i.domElement.appendChild(i.__button),
1609
+ i
1610
+ );
1611
+ }
1612
+ return (
1613
+ D(t, z),
1614
+ P(t, [
1615
+ {
1616
+ key: 'fire',
1617
+ value: function () {
1618
+ this.__onChange && this.__onChange.call(this),
1619
+ this.getValue().call(this.object),
1620
+ this.__onFinishChange &&
1621
+ this.__onFinishChange.call(this, this.getValue());
1622
+ },
1623
+ },
1624
+ ]),
1625
+ t
1626
+ );
1627
+ })(),
1628
+ $ = (function (e) {
1629
+ function t(e, n) {
1630
+ function o(e) {
1631
+ u(e),
1632
+ X.bind(window, 'mousemove', u),
1633
+ X.bind(window, 'touchmove', u),
1634
+ X.bind(window, 'mouseup', r),
1635
+ X.bind(window, 'touchend', r);
1636
+ }
1637
+ function i(e) {
1638
+ _(e),
1639
+ X.bind(window, 'mousemove', _),
1640
+ X.bind(window, 'touchmove', _),
1641
+ X.bind(window, 'mouseup', s),
1642
+ X.bind(window, 'touchend', s);
1643
+ }
1644
+ function r() {
1645
+ X.unbind(window, 'mousemove', u),
1646
+ X.unbind(window, 'touchmove', u),
1647
+ X.unbind(window, 'mouseup', r),
1648
+ X.unbind(window, 'touchend', r),
1649
+ c();
1650
+ }
1651
+ function s() {
1652
+ X.unbind(window, 'mousemove', _),
1653
+ X.unbind(window, 'touchmove', _),
1654
+ X.unbind(window, 'mouseup', s),
1655
+ X.unbind(window, 'touchend', s),
1656
+ c();
1657
+ }
1658
+ function a() {
1659
+ var e = L(this.value);
1660
+ !1 !== e
1661
+ ? ((p.__color.__state = e), p.setValue(p.__color.toOriginal()))
1662
+ : (this.value = p.__color.toString());
1663
+ }
1664
+ function c() {
1665
+ p.__onFinishChange &&
1666
+ p.__onFinishChange.call(p, p.__color.toOriginal());
1667
+ }
1668
+ function u(e) {
1669
+ -1 === e.type.indexOf('touch') && e.preventDefault();
1670
+ var t = p.__saturation_field.getBoundingClientRect(),
1671
+ n = (e.touches && e.touches[0]) || e,
1672
+ o = n.clientX,
1673
+ i = n.clientY,
1674
+ r = (o - t.left) / (t.right - t.left),
1675
+ s = 1 - (i - t.top) / (t.bottom - t.top);
1676
+ return (
1677
+ s > 1 ? (s = 1) : s < 0 && (s = 0),
1678
+ r > 1 ? (r = 1) : r < 0 && (r = 0),
1679
+ (p.__color.v = s),
1680
+ (p.__color.s = r),
1681
+ p.setValue(p.__color.toOriginal()),
1682
+ !1
1683
+ );
1684
+ }
1685
+ function _(e) {
1686
+ -1 === e.type.indexOf('touch') && e.preventDefault();
1687
+ var t = p.__hue_field.getBoundingClientRect(),
1688
+ n =
1689
+ 1 -
1690
+ (((e.touches && e.touches[0]) || e).clientY - t.top) /
1691
+ (t.bottom - t.top);
1692
+ return (
1693
+ n > 1 ? (n = 1) : n < 0 && (n = 0),
1694
+ (p.__color.h = 360 * n),
1695
+ p.setValue(p.__color.toOriginal()),
1696
+ !1
1697
+ );
1698
+ }
1699
+ F(this, t);
1700
+ var h = V(
1701
+ this,
1702
+ (t.__proto__ || Object.getPrototypeOf(t)).call(this, e, n)
1703
+ );
1704
+ (h.__color = new I(h.getValue())), (h.__temp = new I(0));
1705
+ var p = h;
1706
+ (h.domElement = document.createElement('div')),
1707
+ X.makeSelectable(h.domElement, !1),
1708
+ (h.__selector = document.createElement('div')),
1709
+ (h.__selector.className = 'selector'),
1710
+ (h.__saturation_field = document.createElement('div')),
1711
+ (h.__saturation_field.className = 'saturation-field'),
1712
+ (h.__field_knob = document.createElement('div')),
1713
+ (h.__field_knob.className = 'field-knob'),
1714
+ (h.__field_knob_border = '2px solid '),
1715
+ (h.__hue_knob = document.createElement('div')),
1716
+ (h.__hue_knob.className = 'hue-knob'),
1717
+ (h.__hue_field = document.createElement('div')),
1718
+ (h.__hue_field.className = 'hue-field'),
1719
+ (h.__input = document.createElement('input')),
1720
+ (h.__input.type = 'text'),
1721
+ (h.__input_textShadow = '0 1px 1px '),
1722
+ X.bind(h.__input, 'keydown', function (e) {
1723
+ 13 === e.keyCode && a.call(this);
1724
+ }),
1725
+ X.bind(h.__input, 'blur', a),
1726
+ X.bind(h.__selector, 'mousedown', function () {
1727
+ X.addClass(this, 'drag').bind(window, 'mouseup', function () {
1728
+ X.removeClass(p.__selector, 'drag');
1729
+ });
1730
+ }),
1731
+ X.bind(h.__selector, 'touchstart', function () {
1732
+ X.addClass(this, 'drag').bind(window, 'touchend', function () {
1733
+ X.removeClass(p.__selector, 'drag');
1734
+ });
1735
+ });
1736
+ var f = document.createElement('div');
1737
+ return (
1738
+ S.extend(h.__selector.style, {
1739
+ width: '122px',
1740
+ height: '102px',
1741
+ padding: '3px',
1742
+ backgroundColor: '#222',
1743
+ boxShadow: '0px 1px 3px rgba(0,0,0,0.3)',
1744
+ }),
1745
+ S.extend(h.__field_knob.style, {
1746
+ position: 'absolute',
1747
+ width: '12px',
1748
+ height: '12px',
1749
+ border:
1750
+ h.__field_knob_border + (h.__color.v < 0.5 ? '#fff' : '#000'),
1751
+ boxShadow: '0px 1px 3px rgba(0,0,0,0.5)',
1752
+ borderRadius: '12px',
1753
+ zIndex: 1,
1754
+ }),
1755
+ S.extend(h.__hue_knob.style, {
1756
+ position: 'absolute',
1757
+ width: '15px',
1758
+ height: '2px',
1759
+ borderRight: '4px solid #fff',
1760
+ zIndex: 1,
1761
+ }),
1762
+ S.extend(h.__saturation_field.style, {
1763
+ width: '100px',
1764
+ height: '100px',
1765
+ border: '1px solid #555',
1766
+ marginRight: '3px',
1767
+ display: 'inline-block',
1768
+ cursor: 'pointer',
1769
+ }),
1770
+ S.extend(f.style, {
1771
+ width: '100%',
1772
+ height: '100%',
1773
+ background: 'none',
1774
+ }),
1775
+ l(f, 'top', 'rgba(0,0,0,0)', '#000'),
1776
+ S.extend(h.__hue_field.style, {
1777
+ width: '15px',
1778
+ height: '100px',
1779
+ border: '1px solid #555',
1780
+ cursor: 'ns-resize',
1781
+ position: 'absolute',
1782
+ top: '3px',
1783
+ right: '3px',
1784
+ }),
1785
+ d(h.__hue_field),
1786
+ S.extend(h.__input.style, {
1787
+ outline: 'none',
1788
+ textAlign: 'center',
1789
+ color: '#fff',
1790
+ border: 0,
1791
+ fontWeight: 'bold',
1792
+ textShadow: h.__input_textShadow + 'rgba(0,0,0,0.7)',
1793
+ }),
1794
+ X.bind(h.__saturation_field, 'mousedown', o),
1795
+ X.bind(h.__saturation_field, 'touchstart', o),
1796
+ X.bind(h.__field_knob, 'mousedown', o),
1797
+ X.bind(h.__field_knob, 'touchstart', o),
1798
+ X.bind(h.__hue_field, 'mousedown', i),
1799
+ X.bind(h.__hue_field, 'touchstart', i),
1800
+ h.__saturation_field.appendChild(f),
1801
+ h.__selector.appendChild(h.__field_knob),
1802
+ h.__selector.appendChild(h.__saturation_field),
1803
+ h.__selector.appendChild(h.__hue_field),
1804
+ h.__hue_field.appendChild(h.__hue_knob),
1805
+ h.domElement.appendChild(h.__input),
1806
+ h.domElement.appendChild(h.__selector),
1807
+ h.updateDisplay(),
1808
+ h
1809
+ );
1810
+ }
1811
+ return (
1812
+ D(t, z),
1813
+ P(t, [
1814
+ {
1815
+ key: 'updateDisplay',
1816
+ value: function () {
1817
+ var e = L(this.getValue());
1818
+ if (!1 !== e) {
1819
+ var t = !1;
1820
+ S.each(
1821
+ I.COMPONENTS,
1822
+ function (n) {
1823
+ if (
1824
+ !S.isUndefined(e[n]) &&
1825
+ !S.isUndefined(this.__color.__state[n]) &&
1826
+ e[n] !== this.__color.__state[n]
1827
+ )
1828
+ return (t = !0), {};
1829
+ },
1830
+ this
1831
+ ),
1832
+ t && S.extend(this.__color.__state, e);
1833
+ }
1834
+ S.extend(this.__temp.__state, this.__color.__state),
1835
+ (this.__temp.a = 1);
1836
+ var n = this.__color.v < 0.5 || this.__color.s > 0.5 ? 255 : 0,
1837
+ o = 255 - n;
1838
+ S.extend(this.__field_knob.style, {
1839
+ marginLeft: 100 * this.__color.s - 7 + 'px',
1840
+ marginTop: 100 * (1 - this.__color.v) - 7 + 'px',
1841
+ backgroundColor: this.__temp.toHexString(),
1842
+ border:
1843
+ this.__field_knob_border +
1844
+ 'rgb(' +
1845
+ n +
1846
+ ',' +
1847
+ n +
1848
+ ',' +
1849
+ n +
1850
+ ')',
1851
+ }),
1852
+ (this.__hue_knob.style.marginTop =
1853
+ 100 * (1 - this.__color.h / 360) + 'px'),
1854
+ (this.__temp.s = 1),
1855
+ (this.__temp.v = 1),
1856
+ l(
1857
+ this.__saturation_field,
1858
+ 'left',
1859
+ '#fff',
1860
+ this.__temp.toHexString()
1861
+ ),
1862
+ (this.__input.value = this.__color.toString()),
1863
+ S.extend(this.__input.style, {
1864
+ backgroundColor: this.__color.toHexString(),
1865
+ color: 'rgb(' + n + ',' + n + ',' + n + ')',
1866
+ textShadow:
1867
+ this.__input_textShadow +
1868
+ 'rgba(' +
1869
+ o +
1870
+ ',' +
1871
+ o +
1872
+ ',' +
1873
+ o +
1874
+ ',.7)',
1875
+ });
1876
+ },
1877
+ },
1878
+ ]),
1879
+ t
1880
+ );
1881
+ })(),
1882
+ ee = ['-moz-', '-o-', '-webkit-', '-ms-', ''],
1883
+ te = {
1884
+ load: function (e, t) {
1885
+ var n = t || document,
1886
+ o = n.createElement('link');
1887
+ (o.type = 'text/css'),
1888
+ (o.rel = 'stylesheet'),
1889
+ (o.href = e),
1890
+ n.getElementsByTagName('head')[0].appendChild(o);
1891
+ },
1892
+ inject: function (e, t) {
1893
+ var n = t || document,
1894
+ o = document.createElement('style');
1895
+ (o.type = 'text/css'), (o.innerHTML = e);
1896
+ var i = n.getElementsByTagName('head')[0];
1897
+ try {
1898
+ i.appendChild(o);
1899
+ } catch (e) {}
1900
+ },
1901
+ },
1902
+ ne = function (e, t) {
1903
+ var n = e[t];
1904
+ return S.isArray(arguments[2]) || S.isObject(arguments[2])
1905
+ ? new Y(e, t, arguments[2])
1906
+ : S.isNumber(n)
1907
+ ? S.isNumber(arguments[2]) && S.isNumber(arguments[3])
1908
+ ? S.isNumber(arguments[4])
1909
+ ? new q(e, t, arguments[2], arguments[3], arguments[4])
1910
+ : new q(e, t, arguments[2], arguments[3])
1911
+ : S.isNumber(arguments[4])
1912
+ ? new Q(e, t, {
1913
+ min: arguments[2],
1914
+ max: arguments[3],
1915
+ step: arguments[4],
1916
+ })
1917
+ : new Q(e, t, { min: arguments[2], max: arguments[3] })
1918
+ : S.isString(n)
1919
+ ? new J(e, t)
1920
+ : S.isFunction(n)
1921
+ ? new Z(e, t, '')
1922
+ : S.isBoolean(n)
1923
+ ? new K(e, t)
1924
+ : null;
1925
+ },
1926
+ oe =
1927
+ window.requestAnimationFrame ||
1928
+ window.webkitRequestAnimationFrame ||
1929
+ window.mozRequestAnimationFrame ||
1930
+ window.oRequestAnimationFrame ||
1931
+ window.msRequestAnimationFrame ||
1932
+ function (e) {
1933
+ setTimeout(e, 1e3 / 60);
1934
+ },
1935
+ ie = (function () {
1936
+ function e() {
1937
+ F(this, e),
1938
+ (this.backgroundElement = document.createElement('div')),
1939
+ S.extend(this.backgroundElement.style, {
1940
+ backgroundColor: 'rgba(0,0,0,0.8)',
1941
+ top: 0,
1942
+ left: 0,
1943
+ display: 'none',
1944
+ zIndex: '1000',
1945
+ opacity: 0,
1946
+ WebkitTransition: 'opacity 0.2s linear',
1947
+ transition: 'opacity 0.2s linear',
1948
+ }),
1949
+ X.makeFullscreen(this.backgroundElement),
1950
+ (this.backgroundElement.style.position = 'fixed'),
1951
+ (this.domElement = document.createElement('div')),
1952
+ S.extend(this.domElement.style, {
1953
+ position: 'fixed',
1954
+ display: 'none',
1955
+ zIndex: '1001',
1956
+ opacity: 0,
1957
+ WebkitTransition:
1958
+ '-webkit-transform 0.2s ease-out, opacity 0.2s linear',
1959
+ transition: 'transform 0.2s ease-out, opacity 0.2s linear',
1960
+ }),
1961
+ document.body.appendChild(this.backgroundElement),
1962
+ document.body.appendChild(this.domElement);
1963
+ var t = this;
1964
+ X.bind(this.backgroundElement, 'click', function () {
1965
+ t.hide();
1966
+ });
1967
+ }
1968
+ return (
1969
+ P(e, [
1970
+ {
1971
+ key: 'show',
1972
+ value: function () {
1973
+ var e = this;
1974
+ (this.backgroundElement.style.display = 'block'),
1975
+ (this.domElement.style.display = 'block'),
1976
+ (this.domElement.style.opacity = 0),
1977
+ (this.domElement.style.webkitTransform = 'scale(1.1)'),
1978
+ this.layout(),
1979
+ S.defer(function () {
1980
+ (e.backgroundElement.style.opacity = 1),
1981
+ (e.domElement.style.opacity = 1),
1982
+ (e.domElement.style.webkitTransform = 'scale(1)');
1983
+ });
1984
+ },
1985
+ },
1986
+ {
1987
+ key: 'hide',
1988
+ value: function () {
1989
+ var e = this,
1990
+ t = function t() {
1991
+ (e.domElement.style.display = 'none'),
1992
+ (e.backgroundElement.style.display = 'none'),
1993
+ X.unbind(e.domElement, 'webkitTransitionEnd', t),
1994
+ X.unbind(e.domElement, 'transitionend', t),
1995
+ X.unbind(e.domElement, 'oTransitionEnd', t);
1996
+ };
1997
+ X.bind(this.domElement, 'webkitTransitionEnd', t),
1998
+ X.bind(this.domElement, 'transitionend', t),
1999
+ X.bind(this.domElement, 'oTransitionEnd', t),
2000
+ (this.backgroundElement.style.opacity = 0),
2001
+ (this.domElement.style.opacity = 0),
2002
+ (this.domElement.style.webkitTransform = 'scale(1.1)');
2003
+ },
2004
+ },
2005
+ {
2006
+ key: 'layout',
2007
+ value: function () {
2008
+ (this.domElement.style.left =
2009
+ window.innerWidth / 2 - X.getWidth(this.domElement) / 2 + 'px'),
2010
+ (this.domElement.style.top =
2011
+ window.innerHeight / 2 -
2012
+ X.getHeight(this.domElement) / 2 +
2013
+ 'px');
2014
+ },
2015
+ },
2016
+ ]),
2017
+ e
2018
+ );
2019
+ })(),
2020
+ re = (function (e) {
2021
+ if (e && 'undefined' != typeof window) {
2022
+ var t = document.createElement('style');
2023
+ return (
2024
+ t.setAttribute('type', 'text/css'),
2025
+ (t.innerHTML = e),
2026
+ document.head.appendChild(t),
2027
+ e
2028
+ );
2029
+ }
2030
+ })(
2031
+ ".dg ul{list-style:none;margin:0;padding:0;width:100%;clear:both}.dg.ac{position:fixed;top:0;left:0;right:0;height:0;z-index:0}.dg:not(.ac) .main{overflow:hidden}.dg.main{-webkit-transition:opacity .1s linear;-o-transition:opacity .1s linear;-moz-transition:opacity .1s linear;transition:opacity .1s linear}.dg.main.taller-than-window{overflow-y:auto}.dg.main.taller-than-window .close-button{opacity:1;margin-top:-1px;border-top:1px solid #2c2c2c}.dg.main ul.closed .close-button{opacity:1 !important}.dg.main:hover .close-button,.dg.main .close-button.drag{opacity:1}.dg.main .close-button{-webkit-transition:opacity .1s linear;-o-transition:opacity .1s linear;-moz-transition:opacity .1s linear;transition:opacity .1s linear;border:0;line-height:19px;height:20px;cursor:pointer;text-align:center;background-color:#000}.dg.main .close-button.close-top{position:relative}.dg.main .close-button.close-bottom{position:absolute}.dg.main .close-button:hover{background-color:#111}.dg.a{float:right;margin-right:15px;overflow-y:visible}.dg.a.has-save>ul.close-top{margin-top:0}.dg.a.has-save>ul.close-bottom{margin-top:27px}.dg.a.has-save>ul.closed{margin-top:0}.dg.a .save-row{top:0;z-index:1002}.dg.a .save-row.close-top{position:relative}.dg.a .save-row.close-bottom{position:fixed}.dg li{-webkit-transition:height .1s ease-out;-o-transition:height .1s ease-out;-moz-transition:height .1s ease-out;transition:height .1s ease-out;-webkit-transition:overflow .1s linear;-o-transition:overflow .1s linear;-moz-transition:overflow .1s linear;transition:overflow .1s linear}.dg li:not(.folder){cursor:auto;height:27px;line-height:27px;padding:0 4px 0 5px}.dg li.folder{padding:0;border-left:4px solid rgba(0,0,0,0)}.dg li.title{cursor:pointer;margin-left:-4px}.dg .closed li:not(.title),.dg .closed ul li,.dg .closed ul li>*{height:0;overflow:hidden;border:0}.dg .cr{clear:both;padding-left:3px;height:27px;overflow:hidden}.dg .property-name{cursor:default;float:left;clear:left;width:40%;overflow:hidden;text-overflow:ellipsis}.dg .c{float:left;width:60%;position:relative}.dg .c input[type=text]{border:0;margin-top:4px;padding:3px;width:100%;float:right}.dg .has-slider input[type=text]{width:30%;margin-left:0}.dg .slider{float:left;width:66%;margin-left:-5px;margin-right:0;height:19px;margin-top:4px}.dg .slider-fg{height:100%}.dg .c input[type=checkbox]{margin-top:7px}.dg .c select{margin-top:5px}.dg .cr.function,.dg .cr.function .property-name,.dg .cr.function *,.dg .cr.boolean,.dg .cr.boolean *{cursor:pointer}.dg .cr.color{overflow:visible}.dg .selector{display:none;position:absolute;margin-left:-9px;margin-top:23px;z-index:10}.dg .c:hover .selector,.dg .selector.drag{display:block}.dg li.save-row{padding:0}.dg li.save-row .button{display:inline-block;padding:0px 6px}.dg.dialogue{background-color:#222;width:460px;padding:15px;font-size:13px;line-height:15px}#dg-new-constructor{padding:10px;color:#222;font-family:Monaco, monospace;font-size:10px;border:0;resize:none;box-shadow:inset 1px 1px 1px #888;word-wrap:break-word;margin:12px 0;display:block;width:440px;overflow-y:scroll;height:100px;position:relative}#dg-local-explain{display:none;font-size:11px;line-height:17px;border-radius:3px;background-color:#333;padding:8px;margin-top:10px}#dg-local-explain code{font-size:10px}#dat-gui-save-locally{display:none}.dg{color:#eee;font:11px 'Lucida Grande', sans-serif;text-shadow:0 -1px 0 #111}.dg.main::-webkit-scrollbar{width:5px;background:#1a1a1a}.dg.main::-webkit-scrollbar-corner{height:0;display:none}.dg.main::-webkit-scrollbar-thumb{border-radius:5px;background:#676767}.dg li:not(.folder){background:#1a1a1a;border-bottom:1px solid #2c2c2c}.dg li.save-row{line-height:25px;background:#dad5cb;border:0}.dg li.save-row select{margin-left:5px;width:108px}.dg li.save-row .button{margin-left:5px;margin-top:1px;border-radius:2px;font-size:9px;line-height:7px;padding:4px 4px 5px 4px;background:#c5bdad;color:#fff;text-shadow:0 1px 0 #b0a58f;box-shadow:0 -1px 0 #b0a58f;cursor:pointer}.dg li.save-row .button.gears{background:#c5bdad url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAANCAYAAAB/9ZQ7AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAQJJREFUeNpiYKAU/P//PwGIC/ApCABiBSAW+I8AClAcgKxQ4T9hoMAEUrxx2QSGN6+egDX+/vWT4e7N82AMYoPAx/evwWoYoSYbACX2s7KxCxzcsezDh3evFoDEBYTEEqycggWAzA9AuUSQQgeYPa9fPv6/YWm/Acx5IPb7ty/fw+QZblw67vDs8R0YHyQhgObx+yAJkBqmG5dPPDh1aPOGR/eugW0G4vlIoTIfyFcA+QekhhHJhPdQxbiAIguMBTQZrPD7108M6roWYDFQiIAAv6Aow/1bFwXgis+f2LUAynwoIaNcz8XNx3Dl7MEJUDGQpx9gtQ8YCueB+D26OECAAQDadt7e46D42QAAAABJRU5ErkJggg==) 2px 1px no-repeat;height:7px;width:8px}.dg li.save-row .button:hover{background-color:#bab19e;box-shadow:0 -1px 0 #b0a58f}.dg li.folder{border-bottom:0}.dg li.title{padding-left:16px;background:#000 url(data:image/gif;base64,R0lGODlhBQAFAJEAAP////Pz8////////yH5BAEAAAIALAAAAAAFAAUAAAIIlI+hKgFxoCgAOw==) 6px 10px no-repeat;cursor:pointer;border-bottom:1px solid rgba(255,255,255,0.2)}.dg .closed li.title{background-image:url(data:image/gif;base64,R0lGODlhBQAFAJEAAP////Pz8////////yH5BAEAAAIALAAAAAAFAAUAAAIIlGIWqMCbWAEAOw==)}.dg .cr.boolean{border-left:3px solid #806787}.dg .cr.color{border-left:3px solid}.dg .cr.function{border-left:3px solid #e61d5f}.dg .cr.number{border-left:3px solid #2FA1D6}.dg .cr.number input[type=text]{color:#2FA1D6}.dg .cr.string{border-left:3px solid #1ed36f}.dg .cr.string input[type=text]{color:#1ed36f}.dg .cr.function:hover,.dg .cr.boolean:hover{background:#111}.dg .c input[type=text]{background:#303030;outline:none}.dg .c input[type=text]:hover{background:#3c3c3c}.dg .c input[type=text]:focus{background:#494949;color:#fff}.dg .c .slider{background:#303030;cursor:ew-resize}.dg .c .slider-fg{background:#2FA1D6;max-width:100%}.dg .c .slider:hover{background:#3c3c3c}.dg .c .slider:hover .slider-fg{background:#44abda}\n"
2032
+ );
2033
+ te.inject(re);
2034
+ var se = 'Default',
2035
+ ae = (function () {
2036
+ try {
2037
+ return !!window.localStorage;
2038
+ } catch (e) {
2039
+ return !1;
2040
+ }
2041
+ })(),
2042
+ le = void 0,
2043
+ de = !0,
2044
+ ce = void 0,
2045
+ ue = !1,
2046
+ _e = [],
2047
+ he = function e(t) {
2048
+ var n = this,
2049
+ o = t || {};
2050
+ (this.domElement = document.createElement('div')),
2051
+ (this.__ul = document.createElement('ul')),
2052
+ this.domElement.appendChild(this.__ul),
2053
+ X.addClass(this.domElement, 'dg'),
2054
+ (this.__folders = {}),
2055
+ (this.__controllers = []),
2056
+ (this.__rememberedObjects = []),
2057
+ (this.__rememberedObjectIndecesToControllers = []),
2058
+ (this.__listening = []),
2059
+ (o = S.defaults(o, {
2060
+ closeOnTop: !1,
2061
+ autoPlace: !0,
2062
+ width: e.DEFAULT_WIDTH,
2063
+ })),
2064
+ (o = S.defaults(o, { resizable: o.autoPlace, hideable: o.autoPlace })),
2065
+ S.isUndefined(o.load)
2066
+ ? (o.load = { preset: se })
2067
+ : o.preset && (o.load.preset = o.preset),
2068
+ S.isUndefined(o.parent) && o.hideable && _e.push(this),
2069
+ (o.resizable = S.isUndefined(o.parent) && o.resizable),
2070
+ o.autoPlace && S.isUndefined(o.scrollable) && (o.scrollable = !0);
2071
+ var i = ae && 'true' === localStorage.getItem(m(this, 'isLocal')),
2072
+ r = void 0;
2073
+ if (
2074
+ (Object.defineProperties(this, {
2075
+ parent: {
2076
+ get: function () {
2077
+ return o.parent;
2078
+ },
2079
+ },
2080
+ scrollable: {
2081
+ get: function () {
2082
+ return o.scrollable;
2083
+ },
2084
+ },
2085
+ autoPlace: {
2086
+ get: function () {
2087
+ return o.autoPlace;
2088
+ },
2089
+ },
2090
+ closeOnTop: {
2091
+ get: function () {
2092
+ return o.closeOnTop;
2093
+ },
2094
+ },
2095
+ preset: {
2096
+ get: function () {
2097
+ return n.parent ? n.getRoot().preset : o.load.preset;
2098
+ },
2099
+ set: function (e) {
2100
+ n.parent ? (n.getRoot().preset = e) : (o.load.preset = e),
2101
+ E(this),
2102
+ n.revert();
2103
+ },
2104
+ },
2105
+ width: {
2106
+ get: function () {
2107
+ return o.width;
2108
+ },
2109
+ set: function (e) {
2110
+ (o.width = e), w(n, e);
2111
+ },
2112
+ },
2113
+ name: {
2114
+ get: function () {
2115
+ return o.name;
2116
+ },
2117
+ set: function (e) {
2118
+ (o.name = e), titleRowName && (titleRowName.innerHTML = o.name);
2119
+ },
2120
+ },
2121
+ closed: {
2122
+ get: function () {
2123
+ return o.closed;
2124
+ },
2125
+ set: function (t) {
2126
+ (o.closed = t),
2127
+ o.closed
2128
+ ? X.addClass(n.__ul, e.CLASS_CLOSED)
2129
+ : X.removeClass(n.__ul, e.CLASS_CLOSED),
2130
+ this.onResize(),
2131
+ n.__closeButton &&
2132
+ (n.__closeButton.innerHTML = t ? e.TEXT_OPEN : e.TEXT_CLOSED);
2133
+ },
2134
+ },
2135
+ load: {
2136
+ get: function () {
2137
+ return o.load;
2138
+ },
2139
+ },
2140
+ useLocalStorage: {
2141
+ get: function () {
2142
+ return i;
2143
+ },
2144
+ set: function (e) {
2145
+ ae &&
2146
+ ((i = e),
2147
+ e ? X.bind(window, 'unload', r) : X.unbind(window, 'unload', r),
2148
+ localStorage.setItem(m(n, 'isLocal'), e));
2149
+ },
2150
+ },
2151
+ }),
2152
+ S.isUndefined(o.parent))
2153
+ ) {
2154
+ if (
2155
+ ((o.closed = !1),
2156
+ X.addClass(this.domElement, e.CLASS_MAIN),
2157
+ X.makeSelectable(this.domElement, !1),
2158
+ ae && i)
2159
+ ) {
2160
+ n.useLocalStorage = !0;
2161
+ var s = localStorage.getItem(m(this, 'gui'));
2162
+ s && (o.load = JSON.parse(s));
2163
+ }
2164
+ (this.__closeButton = document.createElement('div')),
2165
+ (this.__closeButton.innerHTML = e.TEXT_CLOSED),
2166
+ X.addClass(this.__closeButton, e.CLASS_CLOSE_BUTTON),
2167
+ o.closeOnTop
2168
+ ? (X.addClass(this.__closeButton, e.CLASS_CLOSE_TOP),
2169
+ this.domElement.insertBefore(
2170
+ this.__closeButton,
2171
+ this.domElement.childNodes[0]
2172
+ ))
2173
+ : (X.addClass(this.__closeButton, e.CLASS_CLOSE_BOTTOM),
2174
+ this.domElement.appendChild(this.__closeButton)),
2175
+ X.bind(this.__closeButton, 'click', function () {
2176
+ n.closed = !n.closed;
2177
+ });
2178
+ } else {
2179
+ void 0 === o.closed && (o.closed = !0);
2180
+ var a = document.createTextNode(o.name);
2181
+ X.addClass(a, 'controller-name');
2182
+ var l = c(n, a);
2183
+ X.addClass(this.__ul, e.CLASS_CLOSED),
2184
+ X.addClass(l, 'title'),
2185
+ X.bind(l, 'click', function (e) {
2186
+ return e.preventDefault(), (n.closed = !n.closed), !1;
2187
+ }),
2188
+ o.closed || (this.closed = !1);
2189
+ }
2190
+ o.autoPlace &&
2191
+ (S.isUndefined(o.parent) &&
2192
+ (de &&
2193
+ ((ce = document.createElement('div')),
2194
+ X.addClass(ce, 'dg'),
2195
+ X.addClass(ce, e.CLASS_AUTO_PLACE_CONTAINER),
2196
+ document.body.appendChild(ce),
2197
+ (de = !1)),
2198
+ ce.appendChild(this.domElement),
2199
+ X.addClass(this.domElement, e.CLASS_AUTO_PLACE)),
2200
+ this.parent || w(n, o.width)),
2201
+ (this.__resizeHandler = function () {
2202
+ n.onResizeDebounced();
2203
+ }),
2204
+ X.bind(window, 'resize', this.__resizeHandler),
2205
+ X.bind(this.__ul, 'webkitTransitionEnd', this.__resizeHandler),
2206
+ X.bind(this.__ul, 'transitionend', this.__resizeHandler),
2207
+ X.bind(this.__ul, 'oTransitionEnd', this.__resizeHandler),
2208
+ this.onResize(),
2209
+ o.resizable && y(this),
2210
+ (r = function () {
2211
+ ae &&
2212
+ 'true' === localStorage.getItem(m(n, 'isLocal')) &&
2213
+ localStorage.setItem(
2214
+ m(n, 'gui'),
2215
+ JSON.stringify(n.getSaveObject())
2216
+ );
2217
+ }),
2218
+ (this.saveToLocalStorageIfPossible = r),
2219
+ o.parent ||
2220
+ (function () {
2221
+ var e = n.getRoot();
2222
+ (e.width += 1),
2223
+ S.defer(function () {
2224
+ e.width -= 1;
2225
+ });
2226
+ })();
2227
+ };
2228
+ (he.toggleHide = function () {
2229
+ (ue = !ue),
2230
+ S.each(_e, function (e) {
2231
+ e.domElement.style.display = ue ? 'none' : '';
2232
+ });
2233
+ }),
2234
+ (he.CLASS_AUTO_PLACE = 'a'),
2235
+ (he.CLASS_AUTO_PLACE_CONTAINER = 'ac'),
2236
+ (he.CLASS_MAIN = 'main'),
2237
+ (he.CLASS_CONTROLLER_ROW = 'cr'),
2238
+ (he.CLASS_TOO_TALL = 'taller-than-window'),
2239
+ (he.CLASS_CLOSED = 'closed'),
2240
+ (he.CLASS_CLOSE_BUTTON = 'close-button'),
2241
+ (he.CLASS_CLOSE_TOP = 'close-top'),
2242
+ (he.CLASS_CLOSE_BOTTOM = 'close-bottom'),
2243
+ (he.CLASS_DRAG = 'drag'),
2244
+ (he.DEFAULT_WIDTH = 245),
2245
+ (he.TEXT_CLOSED = 'Close Controls'),
2246
+ (he.TEXT_OPEN = 'Open Controls'),
2247
+ (he._keydownHandler = function (e) {
2248
+ 'text' === document.activeElement.type ||
2249
+ (72 !== e.which && 72 !== e.keyCode) ||
2250
+ he.toggleHide();
2251
+ }),
2252
+ X.bind(window, 'keydown', he._keydownHandler, !1),
2253
+ S.extend(he.prototype, {
2254
+ add: function (e, t) {
2255
+ return f(this, e, t, {
2256
+ factoryArgs: Array.prototype.slice.call(arguments, 2),
2257
+ });
2258
+ },
2259
+ addColor: function (e, t) {
2260
+ return f(this, e, t, { color: !0 });
2261
+ },
2262
+ remove: function (e) {
2263
+ this.__ul.removeChild(e.__li),
2264
+ this.__controllers.splice(this.__controllers.indexOf(e), 1);
2265
+ var t = this;
2266
+ S.defer(function () {
2267
+ t.onResize();
2268
+ });
2269
+ },
2270
+ destroy: function () {
2271
+ if (this.parent)
2272
+ throw new Error(
2273
+ 'Only the root GUI should be removed with .destroy(). For subfolders, use gui.removeFolder(folder) instead.'
2274
+ );
2275
+ this.autoPlace && ce.removeChild(this.domElement);
2276
+ var e = this;
2277
+ S.each(this.__folders, function (t) {
2278
+ e.removeFolder(t);
2279
+ }),
2280
+ X.unbind(window, 'keydown', he._keydownHandler, !1),
2281
+ u(this);
2282
+ },
2283
+ addFolder: function (e) {
2284
+ if (void 0 !== this.__folders[e])
2285
+ throw new Error(
2286
+ 'You already have a folder in this GUI by the name "' + e + '"'
2287
+ );
2288
+ var t = { name: e, parent: this };
2289
+ (t.autoPlace = this.autoPlace),
2290
+ this.load &&
2291
+ this.load.folders &&
2292
+ this.load.folders[e] &&
2293
+ ((t.closed = this.load.folders[e].closed),
2294
+ (t.load = this.load.folders[e]));
2295
+ var n = new he(t);
2296
+ this.__folders[e] = n;
2297
+ var o = c(this, n.domElement);
2298
+ return X.addClass(o, 'folder'), n;
2299
+ },
2300
+ removeFolder: function (e) {
2301
+ this.__ul.removeChild(e.domElement.parentElement),
2302
+ delete this.__folders[e.name],
2303
+ this.load &&
2304
+ this.load.folders &&
2305
+ this.load.folders[e.name] &&
2306
+ delete this.load.folders[e.name],
2307
+ u(e);
2308
+ var t = this;
2309
+ S.each(e.__folders, function (t) {
2310
+ e.removeFolder(t);
2311
+ }),
2312
+ S.defer(function () {
2313
+ t.onResize();
2314
+ });
2315
+ },
2316
+ open: function () {
2317
+ this.closed = !1;
2318
+ },
2319
+ close: function () {
2320
+ this.closed = !0;
2321
+ },
2322
+ onResize: function () {
2323
+ var e = this.getRoot();
2324
+ if (e.scrollable) {
2325
+ var t = X.getOffset(e.__ul).top,
2326
+ n = 0;
2327
+ S.each(e.__ul.childNodes, function (t) {
2328
+ (e.autoPlace && t === e.__save_row) || (n += X.getHeight(t));
2329
+ }),
2330
+ window.innerHeight - t - 20 < n
2331
+ ? (X.addClass(e.domElement, he.CLASS_TOO_TALL),
2332
+ (e.__ul.style.height = window.innerHeight - t - 20 + 'px'))
2333
+ : (X.removeClass(e.domElement, he.CLASS_TOO_TALL),
2334
+ (e.__ul.style.height = 'auto'));
2335
+ }
2336
+ e.__resize_handle &&
2337
+ S.defer(function () {
2338
+ e.__resize_handle.style.height = e.__ul.offsetHeight + 'px';
2339
+ }),
2340
+ e.__closeButton && (e.__closeButton.style.width = e.width + 'px');
2341
+ },
2342
+ onResizeDebounced: S.debounce(function () {
2343
+ this.onResize();
2344
+ }, 50),
2345
+ remember: function () {
2346
+ if (
2347
+ (S.isUndefined(le) &&
2348
+ ((le = new ie()).domElement.innerHTML =
2349
+ '<div id="dg-save" class="dg dialogue">\n\n Here\'s the new load parameter for your <code>GUI</code>\'s constructor:\n\n <textarea id="dg-new-constructor"></textarea>\n\n <div id="dg-save-locally">\n\n <input id="dg-local-storage" type="checkbox"/> Automatically save\n values to <code>localStorage</code> on exit.\n\n <div id="dg-local-explain">The values saved to <code>localStorage</code> will\n override those passed to <code>dat.GUI</code>\'s constructor. This makes it\n easier to work incrementally, but <code>localStorage</code> is fragile,\n and your friends may not see the same values you do.\n\n </div>\n\n </div>\n\n</div>'),
2350
+ this.parent)
2351
+ )
2352
+ throw new Error('You can only call remember on a top level GUI.');
2353
+ var e = this;
2354
+ S.each(Array.prototype.slice.call(arguments), function (t) {
2355
+ 0 === e.__rememberedObjects.length && v(e),
2356
+ -1 === e.__rememberedObjects.indexOf(t) &&
2357
+ e.__rememberedObjects.push(t);
2358
+ }),
2359
+ this.autoPlace && w(this, this.width);
2360
+ },
2361
+ getRoot: function () {
2362
+ for (var e = this; e.parent; ) e = e.parent;
2363
+ return e;
2364
+ },
2365
+ getSaveObject: function () {
2366
+ var e = this.load;
2367
+ return (
2368
+ (e.closed = this.closed),
2369
+ this.__rememberedObjects.length > 0 &&
2370
+ ((e.preset = this.preset),
2371
+ e.remembered || (e.remembered = {}),
2372
+ (e.remembered[this.preset] = x(this))),
2373
+ (e.folders = {}),
2374
+ S.each(this.__folders, function (t, n) {
2375
+ e.folders[n] = t.getSaveObject();
2376
+ }),
2377
+ e
2378
+ );
2379
+ },
2380
+ save: function () {
2381
+ this.load.remembered || (this.load.remembered = {}),
2382
+ (this.load.remembered[this.preset] = x(this)),
2383
+ _(this, !1),
2384
+ this.saveToLocalStorageIfPossible();
2385
+ },
2386
+ saveAs: function (e) {
2387
+ this.load.remembered ||
2388
+ ((this.load.remembered = {}),
2389
+ (this.load.remembered[se] = x(this, !0))),
2390
+ (this.load.remembered[e] = x(this)),
2391
+ (this.preset = e),
2392
+ g(this, e, !0),
2393
+ this.saveToLocalStorageIfPossible();
2394
+ },
2395
+ revert: function (e) {
2396
+ S.each(
2397
+ this.__controllers,
2398
+ function (t) {
2399
+ this.getRoot().load.remembered
2400
+ ? p(e || this.getRoot(), t)
2401
+ : t.setValue(t.initialValue),
2402
+ t.__onFinishChange && t.__onFinishChange.call(t, t.getValue());
2403
+ },
2404
+ this
2405
+ ),
2406
+ S.each(this.__folders, function (e) {
2407
+ e.revert(e);
2408
+ }),
2409
+ e || _(this.getRoot(), !1);
2410
+ },
2411
+ listen: function (e) {
2412
+ var t = 0 === this.__listening.length;
2413
+ this.__listening.push(e), t && C(this.__listening);
2414
+ },
2415
+ updateDisplay: function () {
2416
+ S.each(this.__controllers, function (e) {
2417
+ e.updateDisplay();
2418
+ }),
2419
+ S.each(this.__folders, function (e) {
2420
+ e.updateDisplay();
2421
+ });
2422
+ },
2423
+ });
2424
+ var pe = { Color: I, math: N, interpret: L },
2425
+ fe = {
2426
+ Controller: z,
2427
+ BooleanController: K,
2428
+ OptionController: Y,
2429
+ StringController: J,
2430
+ NumberController: W,
2431
+ NumberControllerBox: Q,
2432
+ NumberControllerSlider: q,
2433
+ FunctionController: Z,
2434
+ ColorController: $,
2435
+ },
2436
+ me = { dom: X },
2437
+ ge = { GUI: he },
2438
+ be = he,
2439
+ ve = { color: pe, controllers: fe, dom: me, gui: ge, GUI: be };
2440
+ (e.color = pe),
2441
+ (e.controllers = fe),
2442
+ (e.dom = me),
2443
+ (e.gui = ge),
2444
+ (e.GUI = be),
2445
+ (e.default = ve),
2446
+ Object.defineProperty(e, '__esModule', { value: !0 });
2447
+ });