@lovrabet/rabetbase-cli 2.1.14-beta.1 → 2.1.14-beta.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 (203) hide show
  1. package/README.md +18 -0
  2. package/lib/api/api-doc.js +1 -1
  3. package/lib/api/fetch-model-list.js +1 -1
  4. package/lib/api/generate-api-file.js +1 -1
  5. package/lib/auth/auth-server-ui.js +1 -1
  6. package/lib/auth/auth-server.js +1 -1
  7. package/lib/auth/constant.js +1 -1
  8. package/lib/auth/get-cookie.js +1 -1
  9. package/lib/auth/get-session-user.js +1 -1
  10. package/lib/auth/is-session-valid.js +1 -1
  11. package/lib/auth/login-success-html.js +1 -1
  12. package/lib/auth/logout.js +1 -1
  13. package/lib/cli-flags.js +1 -1
  14. package/lib/cli.js +1 -1
  15. package/lib/commands/api/generate.js +1 -1
  16. package/lib/commands/api/index.js +1 -1
  17. package/lib/commands/api/list.js +1 -1
  18. package/lib/commands/api/pull.js +1 -1
  19. package/lib/commands/api/shared.js +1 -1
  20. package/lib/commands/app/add.js +1 -1
  21. package/lib/commands/app/discover.js +1 -1
  22. package/lib/commands/app/index.js +1 -1
  23. package/lib/commands/app/list.js +1 -1
  24. package/lib/commands/app/remove.js +1 -1
  25. package/lib/commands/app/shared.js +1 -1
  26. package/lib/commands/app/use.js +1 -1
  27. package/lib/commands/auth/index.js +1 -1
  28. package/lib/commands/bff/create.js +1 -1
  29. package/lib/commands/bff/delete.js +1 -1
  30. package/lib/commands/bff/detail.js +1 -1
  31. package/lib/commands/bff/index.js +1 -1
  32. package/lib/commands/bff/list.js +1 -1
  33. package/lib/commands/bff/pull.js +1 -1
  34. package/lib/commands/bff/push.js +1 -1
  35. package/lib/commands/bff/status.js +1 -1
  36. package/lib/commands/cli-update.js +1 -1
  37. package/lib/commands/codegen/index.js +1 -1
  38. package/lib/commands/codegen/sdk.js +1 -1
  39. package/lib/commands/codegen/sql.js +1 -1
  40. package/lib/commands/common/app-selector.js +1 -1
  41. package/lib/commands/common/flags.js +1 -1
  42. package/lib/commands/common/validate.js +1 -1
  43. package/lib/commands/config/get.js +1 -1
  44. package/lib/commands/config/index.js +1 -1
  45. package/lib/commands/config/list.js +1 -1
  46. package/lib/commands/config/set.js +1 -1
  47. package/lib/commands/config/shared.js +1 -1
  48. package/lib/commands/data/filter.js +1 -1
  49. package/lib/commands/data/getOne.js +1 -1
  50. package/lib/commands/data/index.js +1 -1
  51. package/lib/commands/data/shared.js +1 -1
  52. package/lib/commands/dataset/capability.js +1 -1
  53. package/lib/commands/dataset/delete.js +1 -1
  54. package/lib/commands/dataset/detail.js +1 -1
  55. package/lib/commands/dataset/extend-update.js +1 -1
  56. package/lib/commands/dataset/field-update.js +1 -1
  57. package/lib/commands/dataset/index.js +1 -1
  58. package/lib/commands/dataset/link-create.js +1 -1
  59. package/lib/commands/dataset/link-delete.js +1 -1
  60. package/lib/commands/dataset/link-shared.js +1 -1
  61. package/lib/commands/dataset/link-update.js +1 -1
  62. package/lib/commands/dataset/links.js +1 -1
  63. package/lib/commands/dataset/list.js +1 -1
  64. package/lib/commands/dataset/operations.js +1 -1
  65. package/lib/commands/dataset/rename.js +1 -1
  66. package/lib/commands/db/analyze-cancel.js +1 -1
  67. package/lib/commands/db/analyze-start.js +1 -1
  68. package/lib/commands/db/analyze-status.js +1 -1
  69. package/lib/commands/db/create.js +1 -1
  70. package/lib/commands/db/delete.js +1 -1
  71. package/lib/commands/db/detail.js +1 -1
  72. package/lib/commands/db/diff.js +1 -1
  73. package/lib/commands/db/index.js +1 -1
  74. package/lib/commands/db/list.js +1 -1
  75. package/lib/commands/db/shared.js +1 -1
  76. package/lib/commands/db/tables.js +1 -1
  77. package/lib/commands/db/test.js +1 -1
  78. package/lib/commands/db/update.js +1 -1
  79. package/lib/commands/doctor.js +1 -1
  80. package/lib/commands/init/index.js +1 -1
  81. package/lib/commands/issue/index.js +1 -1
  82. package/lib/commands/issue/nudge.js +1 -1
  83. package/lib/commands/issue/report.js +1 -1
  84. package/lib/commands/issue/shared.js +1 -1
  85. package/lib/commands/logs/index.js +1 -1
  86. package/lib/commands/menu/index.js +1 -1
  87. package/lib/commands/menu/shared/compare-table.js +1 -1
  88. package/lib/commands/menu/shared/index.js +1 -1
  89. package/lib/commands/menu/shared/inquirer.js +1 -1
  90. package/lib/commands/menu/shared/local-pages.js +1 -1
  91. package/lib/commands/menu/shared/logic.js +1 -1
  92. package/lib/commands/menu/shared/service.js +1 -1
  93. package/lib/commands/menu/shared/sync-core.js +1 -1
  94. package/lib/commands/menu/shared/update-core.js +1 -1
  95. package/lib/commands/menu/shared/valid-url.js +1 -1
  96. package/lib/commands/menu/sync.js +1 -1
  97. package/lib/commands/menu/update.js +1 -1
  98. package/lib/commands/page/generate-start.js +1 -1
  99. package/lib/commands/page/generate-status.js +1 -1
  100. package/lib/commands/page/index.js +1 -1
  101. package/lib/commands/page/pull.js +1 -1
  102. package/lib/commands/page/push.js +1 -1
  103. package/lib/commands/page/shared.js +1 -1
  104. package/lib/commands/page/standard-page-status.js +1 -1
  105. package/lib/commands/page/sync.js +1 -1
  106. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  107. package/lib/commands/project/create/format-elapsed.js +1 -1
  108. package/lib/commands/project/create/main.js +1 -1
  109. package/lib/commands/project/create/non-interactive.js +1 -1
  110. package/lib/commands/project/create/project-template-path.js +1 -1
  111. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  112. package/lib/commands/project/create/use-format-code.js +1 -1
  113. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  114. package/lib/commands/project/index.js +1 -1
  115. package/lib/commands/project/init.js +1 -1
  116. package/lib/commands/project/upgrade.js +1 -1
  117. package/lib/commands/registry.js +1 -1
  118. package/lib/commands/run/index.js +1 -1
  119. package/lib/commands/schema.js +1 -1
  120. package/lib/commands/skill/index.js +1 -1
  121. package/lib/commands/sql/create.js +1 -1
  122. package/lib/commands/sql/delete.js +1 -1
  123. package/lib/commands/sql/detail.js +1 -1
  124. package/lib/commands/sql/exec.js +1 -1
  125. package/lib/commands/sql/index.js +1 -1
  126. package/lib/commands/sql/list.js +1 -1
  127. package/lib/commands/sql/pull.js +1 -1
  128. package/lib/commands/sql/push.js +1 -1
  129. package/lib/commands/sql/save.js +1 -1
  130. package/lib/commands/sql/shared.js +1 -1
  131. package/lib/commands/sql/status.js +1 -1
  132. package/lib/commands/sql/validate.js +1 -1
  133. package/lib/config/schema.js +1 -1
  134. package/lib/constant/cdn.js +1 -1
  135. package/lib/constant/cli.js +1 -1
  136. package/lib/constant/defaults.js +1 -1
  137. package/lib/constant/domain.js +1 -1
  138. package/lib/constant/env.js +1 -1
  139. package/lib/constant/output.js +1 -1
  140. package/lib/constant/paths.js +1 -1
  141. package/lib/constant/risk.js +1 -1
  142. package/lib/context.js +1 -1
  143. package/lib/core/alias-resolver.js +1 -1
  144. package/lib/core/api-client.js +1 -1
  145. package/lib/core/bff/config.js +1 -1
  146. package/lib/core/bff/file-system.js +1 -1
  147. package/lib/core/bff/hash.js +1 -1
  148. package/lib/core/bff/lock.js +1 -1
  149. package/lib/core/bff/utils.js +1 -1
  150. package/lib/core/db-resolver.js +1 -1
  151. package/lib/core/page/file-system.js +1 -1
  152. package/lib/core/page/hash.js +1 -1
  153. package/lib/core/page/lock.js +1 -1
  154. package/lib/core/sql-sync/config.js +1 -1
  155. package/lib/core/sql-sync/file-system.js +1 -1
  156. package/lib/core/sql-sync/hash.js +1 -1
  157. package/lib/core/sql-sync/lock.js +1 -1
  158. package/lib/core/sql-sync/utils.js +1 -1
  159. package/lib/core/sql-validator.js +1 -1
  160. package/lib/errors.js +1 -1
  161. package/lib/framework/build-all-flags.js +1 -1
  162. package/lib/framework/flags.js +1 -1
  163. package/lib/framework/help.js +1 -1
  164. package/lib/framework/index.js +1 -1
  165. package/lib/framework/output.js +1 -1
  166. package/lib/framework/response.js +1 -1
  167. package/lib/framework/runner-alias.js +1 -1
  168. package/lib/framework/runner.js +1 -1
  169. package/lib/framework/schema-export.js +1 -1
  170. package/lib/framework/types.js +1 -1
  171. package/lib/generated/build-info.js +1 -1
  172. package/lib/help.js +1 -1
  173. package/lib/skills/main.js +1 -1
  174. package/lib/skills/npx-skills-add.js +1 -1
  175. package/lib/telemetry/cli-command-trace.js +1 -1
  176. package/lib/telemetry/cli-help-trace.js +1 -1
  177. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  178. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  179. package/lib/telemetry/send-cli-trace-log.js +1 -1
  180. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  181. package/lib/utils/ai_config.js +1 -1
  182. package/lib/utils/apply-jq-filter.js +1 -1
  183. package/lib/utils/cdn-config.js +1 -1
  184. package/lib/utils/check-sdk-version.js +1 -1
  185. package/lib/utils/cli-version-check.js +1 -1
  186. package/lib/utils/cli-version-policy.js +1 -1
  187. package/lib/utils/config.js +1 -1
  188. package/lib/utils/copy-directory.js +1 -1
  189. package/lib/utils/entity-with-id.js +1 -1
  190. package/lib/utils/file-utils.js +1 -1
  191. package/lib/utils/guides-cdn.js +1 -1
  192. package/lib/utils/http-client.js +1 -1
  193. package/lib/utils/is-non-interactive.js +1 -1
  194. package/lib/utils/logger.js +1 -1
  195. package/lib/utils/params.js +1 -1
  196. package/lib/utils/platform.js +1 -1
  197. package/lib/utils/rules-cdn.js +1 -1
  198. package/lib/utils/sleep.js +1 -1
  199. package/lib/utils/template-replacer.js +1 -1
  200. package/lib/utils/version.js +1 -1
  201. package/lib/utils/with-active-cookie.js +1 -1
  202. package/lib/utils/write-cli-side-channel.js +1 -1
  203. package/package.json +3 -3
@@ -1 +1 @@
1
- function a81_0x288f(_0x159adf,_0x650ff8){_0x159adf=_0x159adf-0xc5;const _0x51a397=a81_0x51a3();let _0x288f00=_0x51a397[_0x159adf];return _0x288f00;}const a81_0x4989ee=a81_0x288f;(function(_0x26a797,_0x4560f8){const _0x36aabd=a81_0x288f,_0xbc0104=_0x26a797();while(!![]){try{const _0x301276=parseInt(_0x36aabd(0xd8))/0x1*(parseInt(_0x36aabd(0xc9))/0x2)+parseInt(_0x36aabd(0xd9))/0x3+parseInt(_0x36aabd(0xe1))/0x4+parseInt(_0x36aabd(0xcb))/0x5+-parseInt(_0x36aabd(0xf2))/0x6+-parseInt(_0x36aabd(0xd7))/0x7*(-parseInt(_0x36aabd(0xc5))/0x8)+-parseInt(_0x36aabd(0xdf))/0x9;if(_0x301276===_0x4560f8)break;else _0xbc0104['push'](_0xbc0104['shift']());}catch(_0x4243df){_0xbc0104['push'](_0xbc0104['shift']());}}}(a81_0x51a3,0xb4b18));import{existsSync}from'node:fs';import{readFile}from'node:fs/promises';import{resolve}from'node:path';import{CliErrors}from'../../errors.js';import{sanitizeIssueDescription}from'../../commands/issue/shared.js';import{PLATFORM_ISSUE_SPAN_NAME,PLATFORM_ISSUE_TRACE_NAME,sendPlatformIssueCollectLog}from'../../telemetry/send-platform-issue-collect-log.js';const DESCRIPTION_FILE_FLAG=a81_0x4989ee(0xdd);export const issueReport={'service':a81_0x4989ee(0xcd),'command':a81_0x4989ee(0x102),'description':a81_0x4989ee(0xd4),'risk':a81_0x4989ee(0xfd),'requiresAuth':![],'requiresAppCode':![],'defaultOutputFormat':a81_0x4989ee(0xc8),'flags':[{'name':a81_0x4989ee(0xd3),'type':a81_0x4989ee(0x100),'required':!![],'description':a81_0x4989ee(0xda)},{'name':a81_0x4989ee(0xc6),'type':a81_0x4989ee(0x100),'description':'Inline\x20markdown\x20issue\x20description\x20(alternative\x20to\x20--description-file)'},{'name':DESCRIPTION_FILE_FLAG,'type':a81_0x4989ee(0x100),'description':a81_0x4989ee(0xef)}],async 'validate'(_0x30ae26){const _0x5702b4=a81_0x4989ee,_0x547445=_0x30ae26['str'](_0x5702b4(0xd3))['trim'](),_0x4b6608=_0x30ae26[_0x5702b4(0xff)]('description')[_0x5702b4(0xe6)](),_0x44683f=_0x30ae26[_0x5702b4(0xff)](DESCRIPTION_FILE_FLAG)[_0x5702b4(0xe6)]();if(!_0x547445)throw CliErrors[_0x5702b4(0xee)](_0x5702b4(0xd3),_0x5702b4(0xd0));const _0x2861c6=_0x4b6608['length']>0x0,_0x57841d=_0x44683f[_0x5702b4(0xf3)]>0x0;if(_0x2861c6===_0x57841d)throw CliErrors['validation'](_0x5702b4(0xc7),_0x5702b4(0xde));if(_0x57841d){const _0x59b4cd=resolve(process[_0x5702b4(0xed)](),_0x44683f);if(!existsSync(_0x59b4cd))throw CliErrors[_0x5702b4(0xce)](_0x5702b4(0xec)+_0x59b4cd);}},async 'dryRun'(_0x50e8f1){const _0x3d0a24=a81_0x4989ee,_0x4a0cd0=await prepareIssueReport(_0x50e8f1);return{'method':_0x3d0a24(0xfa),'url':'otel://'+PLATFORM_ISSUE_TRACE_NAME+'/'+PLATFORM_ISSUE_SPAN_NAME,'body':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logData':{'issue.title':_0x4a0cd0[_0x3d0a24(0xd3)],'issue.description':_0x4a0cd0[_0x3d0a24(0xc6)],'issue.description_original_bytes':_0x4a0cd0['sanitize'][_0x3d0a24(0xdc)],'issue.description_truncated':_0x4a0cd0[_0x3d0a24(0xe7)][_0x3d0a24(0xfe)],'issue.description_redactions':_0x4a0cd0[_0x3d0a24(0xe7)][_0x3d0a24(0xe5)],'issue.description_redaction_kinds':_0x4a0cd0['sanitize'][_0x3d0a24(0xea)][_0x3d0a24(0xe4)](',')}},'description':[_0x3d0a24(0xf1),_0x3d0a24(0xf5)+_0x4a0cd0[_0x3d0a24(0xdb)],_0x4a0cd0['descriptionFilePath']?_0x3d0a24(0xeb)+_0x4a0cd0[_0x3d0a24(0x101)]:null,_0x4a0cd0[_0x3d0a24(0xe7)][_0x3d0a24(0xfe)]?_0x3d0a24(0xf4)+_0x4a0cd0[_0x3d0a24(0xe7)][_0x3d0a24(0xdc)]+'\x20bytes':null,_0x4a0cd0['sanitize'][_0x3d0a24(0xe5)]>0x0?_0x3d0a24(0xd2)+_0x4a0cd0['sanitize'][_0x3d0a24(0xe5)]+'\x20('+_0x4a0cd0[_0x3d0a24(0xe7)][_0x3d0a24(0xea)][_0x3d0a24(0xe4)](',\x20')+')':null]['filter'](Boolean)[_0x3d0a24(0xe4)]('\x0a')};},async 'execute'(_0x477da4){const _0x3f5ab8=a81_0x4989ee,_0x29b4cb=await prepareIssueReport(_0x477da4);try{await sendPlatformIssueCollectLog({'title':_0x29b4cb[_0x3f5ab8(0xd3)],'description':_0x29b4cb[_0x3f5ab8(0xc6)],'sanitize':{'originalBytes':_0x29b4cb[_0x3f5ab8(0xe7)]['originalBytes'],'truncated':_0x29b4cb[_0x3f5ab8(0xe7)][_0x3f5ab8(0xfe)],'redactionCount':_0x29b4cb[_0x3f5ab8(0xe7)][_0x3f5ab8(0xe5)],'redactionKinds':_0x29b4cb[_0x3f5ab8(0xe7)]['redactionKinds']}});}catch(_0x3bc670){throw CliErrors[_0x3f5ab8(0xcc)](_0x3f5ab8(0xe0)+(_0x3bc670 instanceof Error?_0x3bc670[_0x3f5ab8(0xd1)]:String(_0x3bc670)),_0x3f5ab8(0xf9));}return{'ok':!![],'message':buildResultMessage(_0x29b4cb['sanitize']),'data':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logDataKeys':[_0x3f5ab8(0xd6),_0x3f5ab8(0xf8),'issue.description_original_bytes',_0x3f5ab8(0xfc),_0x3f5ab8(0xd5),_0x3f5ab8(0xf7)],'issue':{'title':_0x29b4cb[_0x3f5ab8(0xd3)],'descriptionLength':_0x29b4cb['description'][_0x3f5ab8(0xf3)],'descriptionSource':_0x29b4cb[_0x3f5ab8(0xdb)],..._0x29b4cb[_0x3f5ab8(0x101)]?{'descriptionFile':_0x29b4cb[_0x3f5ab8(0x101)]}:{},'sanitize':{'originalBytes':_0x29b4cb[_0x3f5ab8(0xe7)][_0x3f5ab8(0xdc)],'truncated':_0x29b4cb[_0x3f5ab8(0xe7)][_0x3f5ab8(0xfe)],'redactions':_0x29b4cb[_0x3f5ab8(0xe7)][_0x3f5ab8(0xe5)],'redactionKinds':_0x29b4cb[_0x3f5ab8(0xe7)]['redactionKinds']}}}};}};function a81_0x51a3(){const _0x2711d4=['string','descriptionFilePath','report','8tDoKZU','description','Provide\x20exactly\x20one\x20of\x20--description\x20or\x20--description-file.','compress','2UcWboF','Write\x20markdown\x20context\x20into\x20the\x20file\x20before\x20retrying.','1058385SDfwmS','apiError','issue','validation','Platform\x20issue\x20reported\x20(','Provide\x20--title\x20with\x20a\x20one-line\x20issue\x20summary.','message','redactions:\x20','title','Report\x20a\x20platform\x20issue\x20with\x20title\x20and\x20markdown\x20context','issue.description_redactions','issue.title','3717287jNCBgr','768319UGwywu','1894464dvyEGl','One-line\x20issue\x20summary','descriptionSource','originalBytes','description-file','Use\x20--description\x20for\x20short\x20markdown\x20text,\x20or\x20--description-file\x20for\x20full\x20issue\x20context.','10398465imejkl','Failed\x20to\x20report\x20platform\x20issue:\x20','2469496hUuGdr','\x20secret(s):\x20','Issue\x20description\x20file\x20is\x20empty:\x20','join','redactionCount','trim','sanitize','redacted\x20','Provide\x20non-empty\x20markdown\x20content\x20via\x20--description\x20or\x20--description-file.','redactionKinds','descriptionFile:\x20','File\x20not\x20found:\x20','cwd','flagMissing','Path\x20to\x20a\x20markdown\x20file\x20whose\x20contents\x20become\x20issue.description','file','Send\x20platform\x20issue\x20collect\x20log\x20via\x20the\x20CLI\x20telemetry\x20adapter','5186364yXnnCQ','length','truncated:\x20original\x20','descriptionSource:\x20','Issue\x20description\x20cannot\x20be\x20empty.','issue.description_redaction_kinds','issue.description','Check\x20telemetry\x20configuration\x20and\x20network\x20reachability,\x20then\x20retry.','POST','push','issue.description_truncated','write','truncated','str'];a81_0x51a3=function(){return _0x2711d4;};return a81_0x51a3();}function buildResultMessage(_0xddb81c){const _0x1c0250=a81_0x4989ee,_0x1039a7=[];return _0xddb81c[_0x1c0250(0xfe)]&&_0x1039a7['push']('truncated\x20from\x20'+_0xddb81c[_0x1c0250(0xdc)]+'\x20bytes'),_0xddb81c[_0x1c0250(0xe5)]>0x0&&_0x1039a7[_0x1c0250(0xfb)](_0x1c0250(0xe8)+_0xddb81c[_0x1c0250(0xe5)]+_0x1c0250(0xe2)+_0xddb81c[_0x1c0250(0xea)][_0x1c0250(0xe4)](',\x20')),_0x1039a7['length']===0x0?'Platform\x20issue\x20reported':_0x1c0250(0xcf)+_0x1039a7['join'](';\x20')+')';}async function prepareIssueReport(_0x599fda){const _0x558748=a81_0x4989ee,_0x2f768c=_0x599fda['str']('title')[_0x558748(0xe6)](),_0xeaf0fd=_0x599fda[_0x558748(0xff)](_0x558748(0xc6)),_0xac4ec2=_0x599fda[_0x558748(0xff)](DESCRIPTION_FILE_FLAG)['trim']();if(!_0xac4ec2){const _0x4aed6b=_0xeaf0fd;if(!_0x4aed6b[_0x558748(0xe6)]())throw CliErrors[_0x558748(0xce)](_0x558748(0xf6),_0x558748(0xe9));const _0x4fefe3=sanitizeIssueDescription(_0x4aed6b);return{'title':_0x2f768c,'description':_0x4fefe3[_0x558748(0xc6)],'descriptionSource':'inline','sanitize':_0x4fefe3};}const _0x149f0c=resolve(process[_0x558748(0xed)](),_0xac4ec2),_0x21b1eb=await readFile(_0x149f0c,'utf8');if(!_0x21b1eb['trim']())throw CliErrors['validation'](_0x558748(0xe3)+_0x149f0c,_0x558748(0xca));const _0x46baab=sanitizeIssueDescription(_0x21b1eb);return{'title':_0x2f768c,'description':_0x46baab[_0x558748(0xc6)],'descriptionSource':_0x558748(0xf0),'descriptionFilePath':_0x149f0c,'sanitize':_0x46baab};}
1
+ function a81_0x2b35(_0xdb92f6,_0x22a406){_0xdb92f6=_0xdb92f6-0x112;const _0x2771a8=a81_0x2771();let _0x2b3517=_0x2771a8[_0xdb92f6];return _0x2b3517;}const a81_0x409bb8=a81_0x2b35;(function(_0x2dc2f1,_0x32f2df){const _0x34dfb0=a81_0x2b35,_0x1508c4=_0x2dc2f1();while(!![]){try{const _0x502fb1=-parseInt(_0x34dfb0(0x114))/0x1+parseInt(_0x34dfb0(0x13b))/0x2*(-parseInt(_0x34dfb0(0x12a))/0x3)+parseInt(_0x34dfb0(0x121))/0x4+parseInt(_0x34dfb0(0x11d))/0x5+-parseInt(_0x34dfb0(0x12f))/0x6*(parseInt(_0x34dfb0(0x131))/0x7)+-parseInt(_0x34dfb0(0x132))/0x8*(-parseInt(_0x34dfb0(0x112))/0x9)+parseInt(_0x34dfb0(0x13a))/0xa*(parseInt(_0x34dfb0(0x14d))/0xb);if(_0x502fb1===_0x32f2df)break;else _0x1508c4['push'](_0x1508c4['shift']());}catch(_0x4ec417){_0x1508c4['push'](_0x1508c4['shift']());}}}(a81_0x2771,0x25c7f));import{existsSync}from'node:fs';import{readFile}from'node:fs/promises';function a81_0x2771(){const _0x48f5dc=['truncated:\x20original\x20','issue.description_redaction_kinds','1508810tfLfSx','4iqarDQ','\x20bytes','sanitize','flagMissing','title','descriptionSource','string','POST','descriptionFile:\x20','descriptionFilePath','Failed\x20to\x20report\x20platform\x20issue:\x20','compress','cwd','Provide\x20--title\x20with\x20a\x20one-line\x20issue\x20summary.','redactions:\x20','Write\x20markdown\x20context\x20into\x20the\x20file\x20before\x20retrying.','file','issue.description_redactions','11SchUbb','inline','truncated\x20from\x20','18yVXkCg','redactionCount','112221WPCwzm','message','filter','Provide\x20non-empty\x20markdown\x20content\x20via\x20--description\x20or\x20--description-file.','trim','description-file','One-line\x20issue\x20summary','join','description','709215QMtQYI','Issue\x20description\x20cannot\x20be\x20empty.','issue.description_original_bytes','File\x20not\x20found:\x20','643208KJajny','otel://','str','Platform\x20issue\x20reported','apiError','Report\x20a\x20platform\x20issue\x20with\x20title\x20and\x20markdown\x20context','length','issue.title','truncated','150903cAywMN','redactionKinds','Path\x20to\x20a\x20markdown\x20file\x20whose\x20contents\x20become\x20issue.description','write','Issue\x20description\x20file\x20is\x20empty:\x20','5574YzQMZe','originalBytes','840FDGCmo','102112nQkmTB','validation','Use\x20--description\x20for\x20short\x20markdown\x20text,\x20or\x20--description-file\x20for\x20full\x20issue\x20context.','issue.description','issue','Check\x20telemetry\x20configuration\x20and\x20network\x20reachability,\x20then\x20retry.'];a81_0x2771=function(){return _0x48f5dc;};return a81_0x2771();}import{resolve}from'node:path';import{CliErrors}from'../../errors.js';import{sanitizeIssueDescription}from'../../commands/issue/shared.js';import{PLATFORM_ISSUE_SPAN_NAME,PLATFORM_ISSUE_TRACE_NAME,sendPlatformIssueCollectLog}from'../../telemetry/send-platform-issue-collect-log.js';const DESCRIPTION_FILE_FLAG=a81_0x409bb8(0x119);export const issueReport={'service':a81_0x409bb8(0x136),'command':'report','description':a81_0x409bb8(0x126),'risk':a81_0x409bb8(0x12d),'requiresAuth':![],'requiresAppCode':![],'defaultOutputFormat':a81_0x409bb8(0x146),'flags':[{'name':a81_0x409bb8(0x13f),'type':a81_0x409bb8(0x141),'required':!![],'description':a81_0x409bb8(0x11a)},{'name':a81_0x409bb8(0x11c),'type':a81_0x409bb8(0x141),'description':'Inline\x20markdown\x20issue\x20description\x20(alternative\x20to\x20--description-file)'},{'name':DESCRIPTION_FILE_FLAG,'type':a81_0x409bb8(0x141),'description':a81_0x409bb8(0x12c)}],async 'validate'(_0x1c8561){const _0xe101d5=a81_0x409bb8,_0x2be4a8=_0x1c8561[_0xe101d5(0x123)](_0xe101d5(0x13f))[_0xe101d5(0x118)](),_0x1f8e9a=_0x1c8561[_0xe101d5(0x123)]('description')[_0xe101d5(0x118)](),_0xf44c89=_0x1c8561[_0xe101d5(0x123)](DESCRIPTION_FILE_FLAG)[_0xe101d5(0x118)]();if(!_0x2be4a8)throw CliErrors[_0xe101d5(0x13e)]('title',_0xe101d5(0x148));const _0x447895=_0x1f8e9a[_0xe101d5(0x127)]>0x0,_0x1647c8=_0xf44c89[_0xe101d5(0x127)]>0x0;if(_0x447895===_0x1647c8)throw CliErrors[_0xe101d5(0x133)]('Provide\x20exactly\x20one\x20of\x20--description\x20or\x20--description-file.',_0xe101d5(0x134));if(_0x1647c8){const _0x1aea9e=resolve(process[_0xe101d5(0x147)](),_0xf44c89);if(!existsSync(_0x1aea9e))throw CliErrors['validation'](_0xe101d5(0x120)+_0x1aea9e);}},async 'dryRun'(_0x37e35c){const _0x30a2a9=a81_0x409bb8,_0x29c6e=await prepareIssueReport(_0x37e35c);return{'method':_0x30a2a9(0x142),'url':_0x30a2a9(0x122)+PLATFORM_ISSUE_TRACE_NAME+'/'+PLATFORM_ISSUE_SPAN_NAME,'body':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logData':{'issue.title':_0x29c6e[_0x30a2a9(0x13f)],'issue.description':_0x29c6e[_0x30a2a9(0x11c)],'issue.description_original_bytes':_0x29c6e[_0x30a2a9(0x13d)][_0x30a2a9(0x130)],'issue.description_truncated':_0x29c6e[_0x30a2a9(0x13d)][_0x30a2a9(0x129)],'issue.description_redactions':_0x29c6e[_0x30a2a9(0x13d)]['redactionCount'],'issue.description_redaction_kinds':_0x29c6e['sanitize']['redactionKinds'][_0x30a2a9(0x11b)](',')}},'description':['Send\x20platform\x20issue\x20collect\x20log\x20via\x20the\x20CLI\x20telemetry\x20adapter','descriptionSource:\x20'+_0x29c6e[_0x30a2a9(0x140)],_0x29c6e[_0x30a2a9(0x144)]?_0x30a2a9(0x143)+_0x29c6e[_0x30a2a9(0x144)]:null,_0x29c6e['sanitize'][_0x30a2a9(0x129)]?_0x30a2a9(0x138)+_0x29c6e[_0x30a2a9(0x13d)][_0x30a2a9(0x130)]+_0x30a2a9(0x13c):null,_0x29c6e[_0x30a2a9(0x13d)]['redactionCount']>0x0?_0x30a2a9(0x149)+_0x29c6e['sanitize'][_0x30a2a9(0x113)]+'\x20('+_0x29c6e[_0x30a2a9(0x13d)]['redactionKinds'][_0x30a2a9(0x11b)](',\x20')+')':null][_0x30a2a9(0x116)](Boolean)['join']('\x0a')};},async 'execute'(_0x3c9743){const _0x541973=a81_0x409bb8,_0x750782=await prepareIssueReport(_0x3c9743);try{await sendPlatformIssueCollectLog({'title':_0x750782[_0x541973(0x13f)],'description':_0x750782[_0x541973(0x11c)],'sanitize':{'originalBytes':_0x750782[_0x541973(0x13d)][_0x541973(0x130)],'truncated':_0x750782[_0x541973(0x13d)]['truncated'],'redactionCount':_0x750782[_0x541973(0x13d)][_0x541973(0x113)],'redactionKinds':_0x750782[_0x541973(0x13d)]['redactionKinds']}});}catch(_0x1f2728){throw CliErrors[_0x541973(0x125)](_0x541973(0x145)+(_0x1f2728 instanceof Error?_0x1f2728[_0x541973(0x115)]:String(_0x1f2728)),_0x541973(0x137));}return{'ok':!![],'message':buildResultMessage(_0x750782[_0x541973(0x13d)]),'data':{'traceName':PLATFORM_ISSUE_TRACE_NAME,'spanName':PLATFORM_ISSUE_SPAN_NAME,'logDataKeys':[_0x541973(0x128),_0x541973(0x135),_0x541973(0x11f),'issue.description_truncated',_0x541973(0x14c),_0x541973(0x139)],'issue':{'title':_0x750782[_0x541973(0x13f)],'descriptionLength':_0x750782[_0x541973(0x11c)][_0x541973(0x127)],'descriptionSource':_0x750782['descriptionSource'],..._0x750782[_0x541973(0x144)]?{'descriptionFile':_0x750782[_0x541973(0x144)]}:{},'sanitize':{'originalBytes':_0x750782['sanitize'][_0x541973(0x130)],'truncated':_0x750782['sanitize']['truncated'],'redactions':_0x750782[_0x541973(0x13d)][_0x541973(0x113)],'redactionKinds':_0x750782[_0x541973(0x13d)][_0x541973(0x12b)]}}}};}};function buildResultMessage(_0x105f5e){const _0x1cac53=a81_0x409bb8,_0x2e271a=[];return _0x105f5e['truncated']&&_0x2e271a['push'](_0x1cac53(0x14f)+_0x105f5e['originalBytes']+_0x1cac53(0x13c)),_0x105f5e['redactionCount']>0x0&&_0x2e271a['push']('redacted\x20'+_0x105f5e['redactionCount']+'\x20secret(s):\x20'+_0x105f5e['redactionKinds'][_0x1cac53(0x11b)](',\x20')),_0x2e271a[_0x1cac53(0x127)]===0x0?_0x1cac53(0x124):'Platform\x20issue\x20reported\x20('+_0x2e271a[_0x1cac53(0x11b)](';\x20')+')';}async function prepareIssueReport(_0x3d9fd2){const _0xa75145=a81_0x409bb8,_0xae05f0=_0x3d9fd2[_0xa75145(0x123)](_0xa75145(0x13f))[_0xa75145(0x118)](),_0x2651b3=_0x3d9fd2[_0xa75145(0x123)](_0xa75145(0x11c)),_0x23e77e=_0x3d9fd2[_0xa75145(0x123)](DESCRIPTION_FILE_FLAG)['trim']();if(!_0x23e77e){const _0x137448=_0x2651b3;if(!_0x137448[_0xa75145(0x118)]())throw CliErrors[_0xa75145(0x133)](_0xa75145(0x11e),_0xa75145(0x117));const _0x31d713=sanitizeIssueDescription(_0x137448);return{'title':_0xae05f0,'description':_0x31d713['description'],'descriptionSource':_0xa75145(0x14e),'sanitize':_0x31d713};}const _0x31a38d=resolve(process[_0xa75145(0x147)](),_0x23e77e),_0x4e7ddc=await readFile(_0x31a38d,'utf8');if(!_0x4e7ddc['trim']())throw CliErrors['validation'](_0xa75145(0x12e)+_0x31a38d,_0xa75145(0x14a));const _0x5e1363=sanitizeIssueDescription(_0x4e7ddc);return{'title':_0xae05f0,'description':_0x5e1363['description'],'descriptionSource':_0xa75145(0x14b),'descriptionFilePath':_0x31a38d,'sanitize':_0x5e1363};}
@@ -1 +1 @@
1
- function a82_0x14d2(){const _0x47bb88=['771701LYeXLB','4OSdAaZ','string','private-key','11387500aRbCDj','utf8','REDACTED:authorization','includes','244765CjZjDf','2106seMFDi','authorization','password','max','subarray','REDACTED:access-key','78qrBIRY','4EJmMxI','replace','18671356BCoPMv','1964949PcttAq','bearer-jwt','push','cookie','473335pfcRto','byteLength','kind','toString','pattern','55632kXXahu'];a82_0x14d2=function(){return _0x47bb88;};return a82_0x14d2();}function a82_0x1451(_0x981d51,_0x39412c){_0x981d51=_0x981d51-0xa5;const _0x14d281=a82_0x14d2();let _0x1451de=_0x14d281[_0x981d51];return _0x1451de;}const a82_0x50ead6=a82_0x1451;(function(_0xde1f2b,_0x2de7eb){const _0x29db5f=a82_0x1451,_0x2c6853=_0xde1f2b();while(!![]){try{const _0x2d0cfe=-parseInt(_0x29db5f(0xbc))/0x1*(-parseInt(_0x29db5f(0xa7))/0x2)+parseInt(_0x29db5f(0xaa))/0x3+parseInt(_0x29db5f(0xb5))/0x4*(-parseInt(_0x29db5f(0xae))/0x5)+-parseInt(_0x29db5f(0xa6))/0x6*(parseInt(_0x29db5f(0xb4))/0x7)+-parseInt(_0x29db5f(0xb3))/0x8*(parseInt(_0x29db5f(0xbd))/0x9)+parseInt(_0x29db5f(0xb8))/0xa+parseInt(_0x29db5f(0xa9))/0xb;if(_0x2d0cfe===_0x2de7eb)break;else _0x2c6853['push'](_0x2c6853['shift']());}catch(_0x84fb07){_0x2c6853['push'](_0x2c6853['shift']());}}}(a82_0x14d2,0xc98fd));export const ISSUE_DESCRIPTION_MAX_BYTES=0x100*0x400;const TRUNCATION_NOTICE='\x0a\x0a[...TRUNCATED\x20by\x20rabetbase-cli...]',REDACTION_RULES=[{'kind':a82_0x50ead6(0xad),'pattern':/(cookie\s*[:=]\s*)[^\s;,'"`]+/gi,'label':'REDACTED:cookie'},{'kind':a82_0x50ead6(0xbe),'pattern':/(authorization\s*:\s*)(bearer|basic|token)\s+[^\s'"`]+/gi,'label':a82_0x50ead6(0xba)},{'kind':a82_0x50ead6(0xb7),'pattern':/-----BEGIN [A-Z0-9 ]*PRIVATE KEY-----[\s\S]*?-----END [A-Z0-9 ]*PRIVATE KEY-----/g,'label':'REDACTED:private-key'},{'kind':'access-key','pattern':/((?:aliyun_)?(?:access|secret)[_-]?key(?:[_-]?id)?\s*[:=]\s*)['"]?[A-Za-z0-9/+_\-]{8,}['"]?/gi,'label':a82_0x50ead6(0xa5)},{'kind':a82_0x50ead6(0xbf),'pattern':/(pass(?:word|wd)\s*[:=]\s*)['"]?[^\s'"`]+['"]?/gi,'label':'REDACTED:password'},{'kind':a82_0x50ead6(0xab),'pattern':/\beyJ[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\b/g,'label':'REDACTED:bearer-jwt'}];export function sanitizeIssueDescription(_0x32828a){const _0x2b3ec0=a82_0x50ead6,_0x3e8763=Buffer[_0x2b3ec0(0xaf)](_0x32828a,'utf8'),_0x57154a=process.env.RABETBASE_ISSUE_RAW_DESCRIPTION==='1';let _0x28d6d4=_0x32828a,_0x2965a2=0x0;const _0x1101e0=[];if(!_0x57154a)for(const _0x3cc42c of REDACTION_RULES){let _0x295082=0x0;_0x28d6d4=_0x28d6d4[_0x2b3ec0(0xa8)](_0x3cc42c[_0x2b3ec0(0xb2)],(_0x1b3e85,_0x518f45)=>{const _0x3defc4=_0x2b3ec0;_0x295082+=0x1;const _0x14da5e=typeof _0x518f45===_0x3defc4(0xb6)?_0x518f45:'';return _0x14da5e+'['+_0x3cc42c['label']+']';}),_0x295082>0x0&&(_0x2965a2+=_0x295082,!_0x1101e0[_0x2b3ec0(0xbb)](_0x3cc42c[_0x2b3ec0(0xb0)])&&_0x1101e0[_0x2b3ec0(0xac)](_0x3cc42c[_0x2b3ec0(0xb0)]));}let _0x30aba3=![];if(Buffer[_0x2b3ec0(0xaf)](_0x28d6d4,_0x2b3ec0(0xb9))>ISSUE_DESCRIPTION_MAX_BYTES){_0x30aba3=!![];const _0x4a321a=Buffer['byteLength'](TRUNCATION_NOTICE,_0x2b3ec0(0xb9)),_0x5b4e42=Math[_0x2b3ec0(0xc0)](0x0,ISSUE_DESCRIPTION_MAX_BYTES-_0x4a321a);_0x28d6d4=sliceUtf8Bytes(_0x28d6d4,_0x5b4e42)+TRUNCATION_NOTICE;}return{'description':_0x28d6d4,'originalBytes':_0x3e8763,'truncated':_0x30aba3,'redactionCount':_0x2965a2,'redactionKinds':_0x1101e0};}function sliceUtf8Bytes(_0x1977f3,_0x49f1f9){const _0x43105c=a82_0x50ead6;if(_0x49f1f9<=0x0)return'';const _0x4c7dd1=Buffer['from'](_0x1977f3,_0x43105c(0xb9));if(_0x4c7dd1[_0x43105c(0xaf)]<=_0x49f1f9)return _0x1977f3;let _0x2c0eb6=_0x49f1f9;while(_0x2c0eb6>0x0){const _0x57385c=_0x4c7dd1[_0x2c0eb6];if(_0x57385c===undefined||(_0x57385c&0xc0)!==0x80)break;_0x2c0eb6-=0x1;}return _0x4c7dd1[_0x43105c(0xc1)](0x0,_0x2c0eb6)[_0x43105c(0xb1)](_0x43105c(0xb9));}
1
+ const a82_0x622d08=a82_0x51fe;(function(_0x22f33d,_0x5fb186){const _0x416bce=a82_0x51fe,_0x555c2f=_0x22f33d();while(!![]){try{const _0x198f94=-parseInt(_0x416bce(0xba))/0x1*(-parseInt(_0x416bce(0xc5))/0x2)+-parseInt(_0x416bce(0xc2))/0x3*(-parseInt(_0x416bce(0xb7))/0x4)+parseInt(_0x416bce(0xa7))/0x5+parseInt(_0x416bce(0xa8))/0x6*(-parseInt(_0x416bce(0xb1))/0x7)+parseInt(_0x416bce(0xb4))/0x8+-parseInt(_0x416bce(0xc1))/0x9*(parseInt(_0x416bce(0xab))/0xa)+parseInt(_0x416bce(0xac))/0xb*(parseInt(_0x416bce(0xbc))/0xc);if(_0x198f94===_0x5fb186)break;else _0x555c2f['push'](_0x555c2f['shift']());}catch(_0x550aa3){_0x555c2f['push'](_0x555c2f['shift']());}}}(a82_0x51dd,0x79363));export const ISSUE_DESCRIPTION_MAX_BYTES=0x100*0x400;function a82_0x51dd(){const _0x722794=['417719wsJGiy','private-key','95448DHROvy','string','replace','subarray','bearer-jwt','4600116KwdCrL','2403VCTOee','utf8','cookie','4eCzhNO','976005ppivKs','77160emYdQT','kind','from','10CrKCTC','209SiCswU','pattern','REDACTED:password','REDACTED:bearer-jwt','access-key','518LZLSrE','byteLength','REDACTED:access-key','1048600oQflTM','max','includes','3228jQfyJy','label','REDACTED:private-key'];a82_0x51dd=function(){return _0x722794;};return a82_0x51dd();}function a82_0x51fe(_0x4bb31e,_0x316ae7){_0x4bb31e=_0x4bb31e-0xa7;const _0x51dd42=a82_0x51dd();let _0x51fee6=_0x51dd42[_0x4bb31e];return _0x51fee6;}const TRUNCATION_NOTICE='\x0a\x0a[...TRUNCATED\x20by\x20rabetbase-cli...]',REDACTION_RULES=[{'kind':a82_0x622d08(0xc4),'pattern':/(cookie\s*[:=]\s*)[^\s;,'"`]+/gi,'label':'REDACTED:cookie'},{'kind':'authorization','pattern':/(authorization\s*:\s*)(bearer|basic|token)\s+[^\s'"`]+/gi,'label':'REDACTED:authorization'},{'kind':a82_0x622d08(0xbb),'pattern':/-----BEGIN [A-Z0-9 ]*PRIVATE KEY-----[\s\S]*?-----END [A-Z0-9 ]*PRIVATE KEY-----/g,'label':a82_0x622d08(0xb9)},{'kind':a82_0x622d08(0xb0),'pattern':/((?:aliyun_)?(?:access|secret)[_-]?key(?:[_-]?id)?\s*[:=]\s*)['"]?[A-Za-z0-9/+_\-]{8,}['"]?/gi,'label':a82_0x622d08(0xb3)},{'kind':'password','pattern':/(pass(?:word|wd)\s*[:=]\s*)['"]?[^\s'"`]+['"]?/gi,'label':a82_0x622d08(0xae)},{'kind':a82_0x622d08(0xc0),'pattern':/\beyJ[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\.[A-Za-z0-9_-]{10,}\b/g,'label':a82_0x622d08(0xaf)}];export function sanitizeIssueDescription(_0x2746bd){const _0x2f1604=a82_0x622d08,_0x3fd128=Buffer['byteLength'](_0x2746bd,'utf8'),_0x2269c3=process.env.RABETBASE_ISSUE_RAW_DESCRIPTION==='1';let _0x3d48b4=_0x2746bd,_0x28e431=0x0;const _0x4fdcd8=[];if(!_0x2269c3)for(const _0xdcc17 of REDACTION_RULES){let _0x498813=0x0;_0x3d48b4=_0x3d48b4[_0x2f1604(0xbe)](_0xdcc17[_0x2f1604(0xad)],(_0x5623e9,_0x27d365)=>{const _0x38b905=_0x2f1604;_0x498813+=0x1;const _0x576d7d=typeof _0x27d365===_0x38b905(0xbd)?_0x27d365:'';return _0x576d7d+'['+_0xdcc17[_0x38b905(0xb8)]+']';}),_0x498813>0x0&&(_0x28e431+=_0x498813,!_0x4fdcd8[_0x2f1604(0xb6)](_0xdcc17['kind'])&&_0x4fdcd8['push'](_0xdcc17[_0x2f1604(0xa9)]));}let _0x4344cc=![];if(Buffer[_0x2f1604(0xb2)](_0x3d48b4,'utf8')>ISSUE_DESCRIPTION_MAX_BYTES){_0x4344cc=!![];const _0x273749=Buffer[_0x2f1604(0xb2)](TRUNCATION_NOTICE,'utf8'),_0x4dbdfa=Math[_0x2f1604(0xb5)](0x0,ISSUE_DESCRIPTION_MAX_BYTES-_0x273749);_0x3d48b4=sliceUtf8Bytes(_0x3d48b4,_0x4dbdfa)+TRUNCATION_NOTICE;}return{'description':_0x3d48b4,'originalBytes':_0x3fd128,'truncated':_0x4344cc,'redactionCount':_0x28e431,'redactionKinds':_0x4fdcd8};}function sliceUtf8Bytes(_0x54fadb,_0x504a45){const _0x2a9982=a82_0x622d08;if(_0x504a45<=0x0)return'';const _0x58fbcb=Buffer[_0x2a9982(0xaa)](_0x54fadb,'utf8');if(_0x58fbcb[_0x2a9982(0xb2)]<=_0x504a45)return _0x54fadb;let _0x4d55f8=_0x504a45;while(_0x4d55f8>0x0){const _0x484a14=_0x58fbcb[_0x4d55f8];if(_0x484a14===undefined||(_0x484a14&0xc0)!==0x80)break;_0x4d55f8-=0x1;}return _0x58fbcb[_0x2a9982(0xbf)](0x0,_0x4d55f8)['toString'](_0x2a9982(0xc3));}
@@ -1 +1 @@
1
- const a83_0x2ebc7e=a83_0x2a35;(function(_0x486126,_0xdfacdb){const _0x23aead=a83_0x2a35,_0x5468ba=_0x486126();while(!![]){try{const _0x4cfd4a=-parseInt(_0x23aead(0x116))/0x1*(-parseInt(_0x23aead(0x109))/0x2)+-parseInt(_0x23aead(0x100))/0x3*(-parseInt(_0x23aead(0x102))/0x4)+parseInt(_0x23aead(0x112))/0x5*(parseInt(_0x23aead(0x105))/0x6)+-parseInt(_0x23aead(0xf5))/0x7*(-parseInt(_0x23aead(0x114))/0x8)+parseInt(_0x23aead(0x101))/0x9*(parseInt(_0x23aead(0x113))/0xa)+parseInt(_0x23aead(0x110))/0xb+-parseInt(_0x23aead(0xff))/0xc;if(_0x4cfd4a===_0xdfacdb)break;else _0x5468ba['push'](_0x5468ba['shift']());}catch(_0x36595a){_0x5468ba['push'](_0x5468ba['shift']());}}}(a83_0x5875,0xdf7cd));function a83_0x2a35(_0xfaefbe,_0x364c2c){_0xfaefbe=_0xfaefbe-0xf0;const _0x587557=a83_0x5875();let _0x2a35be=_0x587557[_0xfaefbe];return _0x2a35be;}import{logger}from'../../utils/logger.js';function printLogs(_0x471ef5){const _0x291db4=a83_0x2a35;if(_0x471ef5[_0x291db4(0xfd)]===0x0){console[_0x291db4(0xfb)](_0x291db4(0x10b));return;}console[_0x291db4(0xfb)](_0x291db4(0xf0)),_0x471ef5[_0x291db4(0xf9)]((_0x1456d7,_0x1f4ef2)=>{const _0x4d81bc=_0x291db4,_0x314953=new Date(_0x1456d7[_0x4d81bc(0xfa)])[_0x4d81bc(0x10c)](_0x4d81bc(0x111)),_0x1df3a7=_0x1456d7[_0x4d81bc(0xf1)]==='success'?'√':_0x1456d7['level']==='error'?'×':_0x1456d7[_0x4d81bc(0xf1)]===_0x4d81bc(0xf2)?'!':'i';console[_0x4d81bc(0xfb)](_0x1f4ef2+0x1+'.\x20'+_0x1df3a7+'\x20['+_0x1456d7['command']+']\x20'+_0x1456d7[_0x4d81bc(0x10f)]),console[_0x4d81bc(0xfb)](_0x4d81bc(0x108)+_0x314953),_0x1456d7[_0x4d81bc(0xf8)]&&console['log'](_0x4d81bc(0x115)+_0x1456d7['duration']+'ms'),_0x1456d7[_0x4d81bc(0x103)]&&Object[_0x4d81bc(0xf7)](_0x1456d7['details'])[_0x4d81bc(0xfd)]>0x0&&console[_0x4d81bc(0xfb)](_0x4d81bc(0x106)+JSON[_0x4d81bc(0xf4)](_0x1456d7[_0x4d81bc(0x103)],null,0x2)),console['log']('');});}function a83_0x5875(){const _0x2aa23d=['6055148cRdkdU','en-US','3370DaOnxA','1870hbwODA','393616scCYAq','\x20\x20\x20Duration:\x20','635sNXCdQ','*\x20Lovrabet\x20CLI\x20logs:\x0a','level','warn','View\x20command\x20history\x20logs','stringify','245RvkZKk','logs','keys','duration','forEach','timestamp','log','Clear\x20command\x20history\x20logs','length','read','68435424YcJvYr','33EqXbFl','41031jvMyKR','651876XoWuNd','details','*\x20Logs\x20cleared','1578EJJwPK','\x20\x20\x20Details:\x20','readLogs','\x20\x20\x20Time:\x20','4798lGWJvj','clearLogs','*\x20No\x20logs\x20found','toLocaleString','clear','write','message'];a83_0x5875=function(){return _0x2aa23d;};return a83_0x5875();}export const logsDefinitions=[{'service':a83_0x2ebc7e(0xf6),'command':'show','description':a83_0x2ebc7e(0xf3),'risk':a83_0x2ebc7e(0xfe),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x5b5933){const _0x51bd6c=a83_0x2ebc7e;return printLogs(logger[_0x51bd6c(0x107)]()),{'ok':!![]};}},{'service':a83_0x2ebc7e(0xf6),'command':a83_0x2ebc7e(0x10d),'description':a83_0x2ebc7e(0xfc),'risk':a83_0x2ebc7e(0x10e),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x458ea7){const _0x5028f9=a83_0x2ebc7e;return logger[_0x5028f9(0x10a)](),console['log'](_0x5028f9(0x104)),{'ok':!![]};}}];
1
+ const a83_0x39d162=a83_0x4eba;function a83_0x4eba(_0x5c2030,_0x205ef1){_0x5c2030=_0x5c2030-0xa2;const _0x2ad34d=a83_0x2ad3();let _0x4ebafe=_0x2ad34d[_0x5c2030];return _0x4ebafe;}(function(_0x204ae3,_0x452964){const _0x1f78c8=a83_0x4eba,_0x4ccc00=_0x204ae3();while(!![]){try{const _0x274b15=parseInt(_0x1f78c8(0xb2))/0x1*(parseInt(_0x1f78c8(0xb7))/0x2)+-parseInt(_0x1f78c8(0xa9))/0x3*(-parseInt(_0x1f78c8(0xa3))/0x4)+parseInt(_0x1f78c8(0xac))/0x5*(-parseInt(_0x1f78c8(0xb8))/0x6)+parseInt(_0x1f78c8(0xb9))/0x7*(parseInt(_0x1f78c8(0xab))/0x8)+parseInt(_0x1f78c8(0xaa))/0x9*(parseInt(_0x1f78c8(0xc3))/0xa)+parseInt(_0x1f78c8(0xb3))/0xb*(parseInt(_0x1f78c8(0xa6))/0xc)+-parseInt(_0x1f78c8(0xc2))/0xd;if(_0x274b15===_0x452964)break;else _0x4ccc00['push'](_0x4ccc00['shift']());}catch(_0x2059e9){_0x4ccc00['push'](_0x4ccc00['shift']());}}}(a83_0x2ad3,0xeba71));function a83_0x2ad3(){const _0x5bda0c=['command','error','stringify','details','20601230eaeHoU','40ZmSena','log','logs','470804ADLfwv','read','\x20\x20\x20Time:\x20','36KrsRXY','timestamp','toLocaleString','33SVjiyw','18405NEDlYq','3800576eGwcZz','5JvheSf','message','readLogs','\x20\x20\x20Duration:\x20','success','duration','1dFxKoS','2876632VTXjTE','length','warn','en-US','739430YnNgUi','10844922RpqyrX','28JCAfiG','level','keys','write','*\x20No\x20logs\x20found'];a83_0x2ad3=function(){return _0x5bda0c;};return a83_0x2ad3();}import{logger}from'../../utils/logger.js';function printLogs(_0x76b4b9){const _0x4da5f7=a83_0x4eba;if(_0x76b4b9[_0x4da5f7(0xb4)]===0x0){console[_0x4da5f7(0xc4)](_0x4da5f7(0xbd));return;}console[_0x4da5f7(0xc4)]('*\x20Lovrabet\x20CLI\x20logs:\x0a'),_0x76b4b9['forEach']((_0x5277c1,_0x368b0d)=>{const _0x307e87=_0x4da5f7,_0x41b41e=new Date(_0x5277c1[_0x307e87(0xa7)])[_0x307e87(0xa8)](_0x307e87(0xb6)),_0x10acc2=_0x5277c1[_0x307e87(0xba)]===_0x307e87(0xb0)?'√':_0x5277c1[_0x307e87(0xba)]===_0x307e87(0xbf)?'×':_0x5277c1[_0x307e87(0xba)]===_0x307e87(0xb5)?'!':'i';console[_0x307e87(0xc4)](_0x368b0d+0x1+'.\x20'+_0x10acc2+'\x20['+_0x5277c1[_0x307e87(0xbe)]+']\x20'+_0x5277c1[_0x307e87(0xad)]),console[_0x307e87(0xc4)](_0x307e87(0xa5)+_0x41b41e),_0x5277c1['duration']&&console['log'](_0x307e87(0xaf)+_0x5277c1[_0x307e87(0xb1)]+'ms'),_0x5277c1[_0x307e87(0xc1)]&&Object[_0x307e87(0xbb)](_0x5277c1[_0x307e87(0xc1)])['length']>0x0&&console[_0x307e87(0xc4)]('\x20\x20\x20Details:\x20'+JSON[_0x307e87(0xc0)](_0x5277c1[_0x307e87(0xc1)],null,0x2)),console[_0x307e87(0xc4)]('');});}export const logsDefinitions=[{'service':a83_0x39d162(0xa2),'command':'show','description':'View\x20command\x20history\x20logs','risk':a83_0x39d162(0xa4),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x2b19f3){const _0xfff3ec=a83_0x39d162;return printLogs(logger[_0xfff3ec(0xae)]()),{'ok':!![]};}},{'service':'logs','command':'clear','description':'Clear\x20command\x20history\x20logs','risk':a83_0x39d162(0xbc),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x114efe){const _0x1e10b4=a83_0x39d162;return logger['clearLogs'](),console[_0x1e10b4(0xc4)]('*\x20Logs\x20cleared'),{'ok':!![]};}}];
@@ -1 +1 @@
1
- (function(_0x2102eb,_0x2135a1){const _0x4ed0ee=a84_0x2dfa,_0x4c1257=_0x2102eb();while(!![]){try{const _0x2f5415=parseInt(_0x4ed0ee(0x1d9))/0x1*(-parseInt(_0x4ed0ee(0x1d8))/0x2)+-parseInt(_0x4ed0ee(0x1db))/0x3*(parseInt(_0x4ed0ee(0x1d5))/0x4)+-parseInt(_0x4ed0ee(0x1d4))/0x5*(-parseInt(_0x4ed0ee(0x1d2))/0x6)+-parseInt(_0x4ed0ee(0x1dc))/0x7+parseInt(_0x4ed0ee(0x1d3))/0x8*(parseInt(_0x4ed0ee(0x1d7))/0x9)+-parseInt(_0x4ed0ee(0x1da))/0xa*(-parseInt(_0x4ed0ee(0x1d6))/0xb)+parseInt(_0x4ed0ee(0x1dd))/0xc;if(_0x2f5415===_0x2135a1)break;else _0x4c1257['push'](_0x4c1257['shift']());}catch(_0x59f526){_0x4c1257['push'](_0x4c1257['shift']());}}}(a84_0x369f,0x8f82b));import{menuSync}from'../../commands/menu/sync.js';function a84_0x369f(){const _0x59e6b6=['9115764jzuAzm','6iqkvGl','11928ISPrYb','3194305TdfdYd','901336qdtydU','748YwpfxP','1323BuoNvr','66446IDBWWG','4QSRXru','52860udLfOh','6wPqBic','5640278fQBhYM'];a84_0x369f=function(){return _0x59e6b6;};return a84_0x369f();}function a84_0x2dfa(_0x2daf01,_0x205eea){_0x2daf01=_0x2daf01-0x1d2;const _0x369fdc=a84_0x369f();let _0x2dfa03=_0x369fdc[_0x2daf01];return _0x2dfa03;}import{menuUpdate}from'../../commands/menu/update.js';export const menuDefinitions=[menuSync,menuUpdate];
1
+ (function(_0x4fbd9f,_0x3df1ae){const _0x599ce1=a84_0x4571,_0x5168e2=_0x4fbd9f();while(!![]){try{const _0x1a92db=-parseInt(_0x599ce1(0x122))/0x1+parseInt(_0x599ce1(0x121))/0x2*(-parseInt(_0x599ce1(0x11d))/0x3)+-parseInt(_0x599ce1(0x11a))/0x4+parseInt(_0x599ce1(0x11c))/0x5*(parseInt(_0x599ce1(0x120))/0x6)+parseInt(_0x599ce1(0x119))/0x7+parseInt(_0x599ce1(0x11f))/0x8*(parseInt(_0x599ce1(0x11e))/0x9)+parseInt(_0x599ce1(0x11b))/0xa*(parseInt(_0x599ce1(0x123))/0xb);if(_0x1a92db===_0x3df1ae)break;else _0x5168e2['push'](_0x5168e2['shift']());}catch(_0x1c9927){_0x5168e2['push'](_0x5168e2['shift']());}}}(a84_0x19c6,0x251ef));import{menuSync}from'../../commands/menu/sync.js';import{menuUpdate}from'../../commands/menu/update.js';function a84_0x4571(_0x920552,_0x4468c7){_0x920552=_0x920552-0x119;const _0x19c69b=a84_0x19c6();let _0x45718e=_0x19c69b[_0x920552];return _0x45718e;}function a84_0x19c6(){const _0xac373=['36311jqseTh','879221ARmLoj','615456zBtiUe','530dLfBUx','10CYdSNJ','37029OfYFWP','343755ZfmHPQ','16cjFSnN','542838TJwGHC','2VGsMaE','239638ReoIvV'];a84_0x19c6=function(){return _0xac373;};return a84_0x19c6();}export const menuDefinitions=[menuSync,menuUpdate];
@@ -1 +1 @@
1
- function a85_0xa104(){const _0x47ddfc=['length','4305951dbIkdY','4396655aZduUu','9858982xgVSjs','map','\x20\x20No\x20pages\x20to\x20sync.','path','join','29607350zcuKqn','Platform','label','Local','local','\x20\x20\x20\x20•\x20','6vkCmSP','8cCqcli','(unchanged)','9743391udKJpx','11fazVZN','repeat','\x20page(s)\x20will\x20be\x20created\x20on\x20platform:','push','\x20menu(s)\x20will\x20be\x20updated\x20with\x20new\x20assets:','online','4956624NdZQSK','2XLHunV','Menu\x20Name','max','\x20\x20All\x20local\x20pages\x20are\x20already\x20on\x20platform.','1450681eWTRfx'];a85_0xa104=function(){return _0x47ddfc;};return a85_0xa104();}(function(_0x2a4104,_0x40d1ec){const _0x399042=a85_0x1080,_0x45cf7e=_0x2a4104();while(!![]){try{const _0x17bfc6=-parseInt(_0x399042(0x154))/0x1+-parseInt(_0x399042(0x150))/0x2*(-parseInt(_0x399042(0x156))/0x3)+parseInt(_0x399042(0x14f))/0x4+-parseInt(_0x399042(0x157))/0x5*(parseInt(_0x399042(0x163))/0x6)+-parseInt(_0x399042(0x158))/0x7+parseInt(_0x399042(0x164))/0x8*(-parseInt(_0x399042(0x166))/0x9)+parseInt(_0x399042(0x15d))/0xa*(parseInt(_0x399042(0x167))/0xb);if(_0x17bfc6===_0x40d1ec)break;else _0x45cf7e['push'](_0x45cf7e['shift']());}catch(_0x4053f0){_0x45cf7e['push'](_0x45cf7e['shift']());}}}(a85_0xa104,0xc6c5b));function strWidth(_0x1d2785){let _0x5a6123=0x0;for(const _0x150945 of _0x1d2785){_0x5a6123+=/[\u4e00-\u9fa5]/['test'](_0x150945)?0x2:0x1;}return _0x5a6123;}function padRight(_0xeb72a1,_0x5f08bc){const _0x273f26=a85_0x1080,_0x479330=strWidth(_0xeb72a1);return _0xeb72a1+'\x20'[_0x273f26(0x168)](Math[_0x273f26(0x152)](0x0,_0x5f08bc-_0x479330));}export function renderCompareTable(_0x191263,_0x4ab1ca={}){const _0x202224=a85_0x1080;if(_0x191263['length']===0x0)return'';const _0x129ba3=_0x4ab1ca['showOnline']??!![],_0x46c50d=Math['max'](0x1e,..._0x191263[_0x202224(0x159)](_0x4c5af6=>strWidth(_0x4c5af6[_0x202224(0x15f)]))),_0x345fd2=0x4,_0x5788cd=[],_0x219f77='\x20\x20'+padRight(_0x202224(0x151),_0x46c50d),_0x2a0605=padRight(_0x202224(0x160),_0x345fd2),_0xa83157=_0x129ba3?'\x20\x20'+padRight(_0x202224(0x15e),_0x345fd2):'';_0x5788cd['push'](_0x219f77+'\x20\x20'+_0x2a0605+(_0x129ba3?_0xa83157:'')),_0x5788cd['push']('\x20\x20'+'─'['repeat'](_0x46c50d)+'\x20\x20'+'─'[_0x202224(0x168)](_0x345fd2)+(_0x129ba3?'\x20\x20'+'─'[_0x202224(0x168)](_0x345fd2):''));for(const _0xc0e653 of _0x191263){const _0x339ae4=padRight(_0xc0e653[_0x202224(0x15f)],_0x46c50d),_0x3f7529=_0xc0e653[_0x202224(0x161)]?'✓':'✗',_0x59d3d4=padRight(_0x3f7529,_0x345fd2);let _0x271fe7='\x20\x20'+_0x339ae4+'\x20\x20'+_0x59d3d4;if(_0x129ba3){const _0xa5558a=_0xc0e653[_0x202224(0x16c)]?'✓':'✗';_0x271fe7+='\x20\x20'+padRight(_0xa5558a,_0x345fd2);}_0x5788cd[_0x202224(0x16a)](_0x271fe7);}return _0x5788cd[_0x202224(0x15c)]('\x0a');}export function renderSyncSummary(_0x462bd9,_0x2b769a){const _0x38471d=a85_0x1080;if(_0x462bd9[_0x38471d(0x155)]===0x0)return _0x2b769a?_0x38471d(0x153):_0x38471d(0x15a);const _0x9ec985=['\x20\x20'+_0x462bd9[_0x38471d(0x155)]+_0x38471d(0x169)];for(const _0x2502aa of _0x462bd9){_0x9ec985['push'](_0x38471d(0x162)+_0x2502aa[_0x38471d(0x15f)]+'\x20('+_0x2502aa[_0x38471d(0x15b)]+')');}return _0x9ec985[_0x38471d(0x15c)]('\x0a');}function a85_0x1080(_0x470e2e,_0x56ff8b){_0x470e2e=_0x470e2e-0x14f;const _0xa1042f=a85_0xa104();let _0x108032=_0xa1042f[_0x470e2e];return _0x108032;}export function renderUpdateSummary(_0x18aaf2,_0x1ac937){const _0x4b8d64=a85_0x1080;if(_0x18aaf2['length']===0x0)return'\x20\x20No\x20menus\x20with\x20existing\x20resources\x20found.';const _0x1c735b=['\x20\x20'+_0x18aaf2[_0x4b8d64(0x155)]+_0x4b8d64(0x16b),'\x20\x20\x20\x20JS:\x20\x20'+(_0x1ac937[0x0]??_0x4b8d64(0x165)),'\x20\x20\x20\x20CSS:\x20'+(_0x1ac937[0x1]??_0x4b8d64(0x165)),'','\x20\x20Affected\x20menus:\x20'+_0x18aaf2['join'](',\x20')];return _0x1c735b[_0x4b8d64(0x15c)]('\x0a');}
1
+ (function(_0x4b9466,_0x50ce83){const _0x2d871f=a85_0x4880,_0x1c1d00=_0x4b9466();while(!![]){try{const _0xe2ed7=-parseInt(_0x2d871f(0x19f))/0x1*(-parseInt(_0x2d871f(0x1a7))/0x2)+parseInt(_0x2d871f(0x1b1))/0x3*(-parseInt(_0x2d871f(0x1b2))/0x4)+-parseInt(_0x2d871f(0x1ac))/0x5*(parseInt(_0x2d871f(0x19c))/0x6)+parseInt(_0x2d871f(0x1b0))/0x7*(parseInt(_0x2d871f(0x1a5))/0x8)+-parseInt(_0x2d871f(0x1a9))/0x9+parseInt(_0x2d871f(0x197))/0xa*(parseInt(_0x2d871f(0x1a3))/0xb)+parseInt(_0x2d871f(0x194))/0xc;if(_0xe2ed7===_0x50ce83)break;else _0x1c1d00['push'](_0x1c1d00['shift']());}catch(_0x1c0f06){_0x1c1d00['push'](_0x1c1d00['shift']());}}}(a85_0x303a,0x45676));function strWidth(_0x388446){const _0x557068=a85_0x4880;let _0x2b5212=0x0;for(const _0xfd130b of _0x388446){_0x2b5212+=/[\u4e00-\u9fa5]/[_0x557068(0x1aa)](_0xfd130b)?0x2:0x1;}return _0x2b5212;}function padRight(_0x475204,_0x29804d){const _0x3c5c21=a85_0x4880,_0x313e44=strWidth(_0x475204);return _0x475204+'\x20'[_0x3c5c21(0x195)](Math[_0x3c5c21(0x1a4)](0x0,_0x29804d-_0x313e44));}function a85_0x4880(_0x147984,_0x5b0f49){_0x147984=_0x147984-0x191;const _0x303a30=a85_0x303a();let _0x4880a0=_0x303a30[_0x147984];return _0x4880a0;}export function renderCompareTable(_0x7c56c6,_0x300c12={}){const _0x3c2b22=a85_0x4880;if(_0x7c56c6['length']===0x0)return'';const _0x227749=_0x300c12[_0x3c2b22(0x1a1)]??!![],_0x421439=Math[_0x3c2b22(0x1a4)](0x1e,..._0x7c56c6[_0x3c2b22(0x19e)](_0x5c03dd=>strWidth(_0x5c03dd[_0x3c2b22(0x191)]))),_0x5b6dd6=0x4,_0x1482a6=[],_0x2a10ea='\x20\x20'+padRight(_0x3c2b22(0x19b),_0x421439),_0x46d6c2=padRight(_0x3c2b22(0x1a2),_0x5b6dd6),_0x21bc02=_0x227749?'\x20\x20'+padRight(_0x3c2b22(0x196),_0x5b6dd6):'';_0x1482a6[_0x3c2b22(0x193)](_0x2a10ea+'\x20\x20'+_0x46d6c2+(_0x227749?_0x21bc02:'')),_0x1482a6[_0x3c2b22(0x193)]('\x20\x20'+'─'[_0x3c2b22(0x195)](_0x421439)+'\x20\x20'+'─'[_0x3c2b22(0x195)](_0x5b6dd6)+(_0x227749?'\x20\x20'+'─'[_0x3c2b22(0x195)](_0x5b6dd6):''));for(const _0x3413b5 of _0x7c56c6){const _0x346300=padRight(_0x3413b5[_0x3c2b22(0x191)],_0x421439),_0x33ae4c=_0x3413b5[_0x3c2b22(0x198)]?'✓':'✗',_0x16cfb5=padRight(_0x33ae4c,_0x5b6dd6);let _0x49cbad='\x20\x20'+_0x346300+'\x20\x20'+_0x16cfb5;if(_0x227749){const _0x4079da=_0x3413b5['online']?'✓':'✗';_0x49cbad+='\x20\x20'+padRight(_0x4079da,_0x5b6dd6);}_0x1482a6[_0x3c2b22(0x193)](_0x49cbad);}return _0x1482a6['join']('\x0a');}export function renderSyncSummary(_0x4a1fd4,_0x3bd96e){const _0x2addbd=a85_0x4880;if(_0x4a1fd4['length']===0x0)return _0x3bd96e?_0x2addbd(0x1ab):_0x2addbd(0x19d);const _0x1d04b6=['\x20\x20'+_0x4a1fd4[_0x2addbd(0x1a0)]+_0x2addbd(0x1ae)];for(const _0x55818d of _0x4a1fd4){_0x1d04b6[_0x2addbd(0x193)](_0x2addbd(0x1af)+_0x55818d[_0x2addbd(0x191)]+'\x20('+_0x55818d[_0x2addbd(0x1ad)]+')');}return _0x1d04b6[_0x2addbd(0x19a)]('\x0a');}export function renderUpdateSummary(_0x4fab56,_0x482dfb){const _0x7fb861=a85_0x4880;if(_0x4fab56[_0x7fb861(0x1a0)]===0x0)return _0x7fb861(0x192);const _0x4f41f5=['\x20\x20'+_0x4fab56['length']+'\x20menu(s)\x20will\x20be\x20updated\x20with\x20new\x20assets:',_0x7fb861(0x199)+(_0x482dfb[0x0]??_0x7fb861(0x1a8)),'\x20\x20\x20\x20CSS:\x20'+(_0x482dfb[0x1]??_0x7fb861(0x1a8)),'',_0x7fb861(0x1a6)+_0x4fab56[_0x7fb861(0x19a)](',\x20')];return _0x4f41f5['join']('\x0a');}function a85_0x303a(){const _0x258539=['1969lYWZfd','max','4068384uWlwoE','\x20\x20Affected\x20menus:\x20','103196HgBfsU','(unchanged)','3081834GUgpxn','test','\x20\x20All\x20local\x20pages\x20are\x20already\x20on\x20platform.','236285kpFsaC','path','\x20page(s)\x20will\x20be\x20created\x20on\x20platform:','\x20\x20\x20\x20•\x20','7AGIXuT','486885sqxnCx','12fRjPFM','label','\x20\x20No\x20menus\x20with\x20existing\x20resources\x20found.','push','7226148NQxvcH','repeat','Platform','7110UCkGLu','local','\x20\x20\x20\x20JS:\x20\x20','join','Menu\x20Name','42NDztoN','\x20\x20No\x20pages\x20to\x20sync.','map','4CvRpxs','length','showOnline','Local'];a85_0x303a=function(){return _0x258539;};return a85_0x303a();}
@@ -1 +1 @@
1
- (function(_0x5ab9e9,_0xf01c88){var _0x5e2077=a86_0x2839,_0xae5179=_0x5ab9e9();while(!![]){try{var _0x582ac3=parseInt(_0x5e2077(0x1e5))/0x1+-parseInt(_0x5e2077(0x1eb))/0x2*(parseInt(_0x5e2077(0x1e3))/0x3)+parseInt(_0x5e2077(0x1e2))/0x4*(-parseInt(_0x5e2077(0x1e7))/0x5)+parseInt(_0x5e2077(0x1e9))/0x6*(-parseInt(_0x5e2077(0x1e6))/0x7)+parseInt(_0x5e2077(0x1e1))/0x8*(parseInt(_0x5e2077(0x1e4))/0x9)+-parseInt(_0x5e2077(0x1e8))/0xa+parseInt(_0x5e2077(0x1ea))/0xb;if(_0x582ac3===_0xf01c88)break;else _0xae5179['push'](_0xae5179['shift']());}catch(_0x5ea5e5){_0xae5179['push'](_0xae5179['shift']());}}}(a86_0x44aa,0xda2e9));export*from'../../../commands/menu/shared/types.js';export*from'../../../commands/menu/shared/logic.js';export*from'../../../commands/menu/shared/compare-table.js';export*from'../../../commands/menu/shared/inquirer.js';function a86_0x2839(_0x3d8223,_0x5abca6){_0x3d8223=_0x3d8223-0x1e1;var _0x44aaa0=a86_0x44aa();var _0x28396a=_0x44aaa0[_0x3d8223];return _0x28396a;}export*from'../../../commands/menu/shared/valid-url.js';export*from'../../../commands/menu/shared/local-pages.js';function a86_0x44aa(){var _0x45465f=['237280LSgASP','3662320VRAisB','104silglK','15kKdIWu','9BNenUc','629117xlRVmt','126UpshdD','258565rFzYAl','8801940NFFjlW','247788MDbeQi','37048682GNXdkt'];a86_0x44aa=function(){return _0x45465f;};return a86_0x44aa();}export*from'../../../commands/menu/shared/service.js';export*from'../../../commands/menu/shared/sync-core.js';export*from'../../../commands/menu/shared/update-core.js';
1
+ (function(_0x4e99d0,_0x869533){var _0x1664c7=a86_0x3aee,_0x2a79f3=_0x4e99d0();while(!![]){try{var _0x497875=parseInt(_0x1664c7(0x128))/0x1*(-parseInt(_0x1664c7(0x126))/0x2)+-parseInt(_0x1664c7(0x123))/0x3*(parseInt(_0x1664c7(0x121))/0x4)+-parseInt(_0x1664c7(0x127))/0x5+parseInt(_0x1664c7(0x129))/0x6*(parseInt(_0x1664c7(0x120))/0x7)+parseInt(_0x1664c7(0x124))/0x8+-parseInt(_0x1664c7(0x11f))/0x9+parseInt(_0x1664c7(0x125))/0xa*(parseInt(_0x1664c7(0x122))/0xb);if(_0x497875===_0x869533)break;else _0x2a79f3['push'](_0x2a79f3['shift']());}catch(_0x50bfb7){_0x2a79f3['push'](_0x2a79f3['shift']());}}}(a86_0x3f1b,0xbef09));function a86_0x3aee(_0x243f5f,_0x3be0c0){_0x243f5f=_0x243f5f-0x11f;var _0x3f1b03=a86_0x3f1b();var _0x3aeef4=_0x3f1b03[_0x243f5f];return _0x3aeef4;}export*from'../../../commands/menu/shared/types.js';export*from'../../../commands/menu/shared/logic.js';export*from'../../../commands/menu/shared/compare-table.js';export*from'../../../commands/menu/shared/inquirer.js';function a86_0x3f1b(){var _0x34b83b=['2956482JxFvUl','777keICJN','3291724LIFpOL','8257051GjwqhV','3ssjZwe','8249144lXGFoF','20QrwCns','2zBXeSL','1070090HzRCdV','1482346DSFFQM','59322mZdqkM'];a86_0x3f1b=function(){return _0x34b83b;};return a86_0x3f1b();}export*from'../../../commands/menu/shared/valid-url.js';export*from'../../../commands/menu/shared/local-pages.js';export*from'../../../commands/menu/shared/service.js';export*from'../../../commands/menu/shared/sync-core.js';export*from'../../../commands/menu/shared/update-core.js';
@@ -1 +1 @@
1
- (function(_0x279558,_0x10c74c){const _0x533a41=a87_0x1200,_0x21dfcd=_0x279558();while(!![]){try{const _0x55f9d0=parseInt(_0x533a41(0xdc))/0x1*(-parseInt(_0x533a41(0xbe))/0x2)+parseInt(_0x533a41(0xc3))/0x3*(-parseInt(_0x533a41(0xb8))/0x4)+parseInt(_0x533a41(0xde))/0x5*(parseInt(_0x533a41(0xd2))/0x6)+parseInt(_0x533a41(0xdb))/0x7+-parseInt(_0x533a41(0xd9))/0x8+parseInt(_0x533a41(0xb6))/0x9*(-parseInt(_0x533a41(0xd0))/0xa)+parseInt(_0x533a41(0xe0))/0xb;if(_0x55f9d0===_0x10c74c)break;else _0x21dfcd['push'](_0x21dfcd['shift']());}catch(_0x195a6a){_0x21dfcd['push'](_0x21dfcd['shift']());}}}(a87_0x1e96,0xe819f));import a87_0x27904c from'chalk';import{checkbox,input,confirm}from'@inquirer/prompts';import a87_0xfa552d from'ora';import{isUrlReachable}from'../../../commands/menu/shared/valid-url.js';import{CliErrors}from'../../../errors.js';function a87_0x1e96(){const _0x3b37fe=['No\x20menus\x20selected.','\x20\x20JS\x20URL:','cyan','[already\x20on\x20platform]','3238dCAlzw','This\x20command\x20requires\x20an\x20interactive\x20terminal.\x20','CSS\x20URL\x20check\x20failed','Cancelled.','name','141jpbgpD','length','\x20\x20✗\x20JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL','\x20\x20Select\x20menus\x20to\x20sync\x20(space\x20to\x20toggle,\x20a=all,\x20i=invert):','start','JS\x20URL\x20checked','\x20\x20✗\x20CSS\x20URL\x20is\x20unreachable','fail','\x20\x20Checking\x20JS\x20URL\x20reachability...','cancelled','[new]','\x20\x20✗\x20JS\x20URL\x20is\x20unreachable','CSS\x20URL\x20checked','5612770qmZYtS','error','3138GVmmHY','green','stdin','label','succeed','test','gray','608368rYBFWJ','path','12933256TZkqBX','895zeKVad','No\x20local\x20pages\x20found.','1010hLJrlj','filter','37665419Xhfcug','Use\x20--yes\x20to\x20run\x20in\x20non-interactive\x20mode,\x20or\x20pipe\x20data\x20via\x20--params.','includes','JS\x20URL\x20check\x20failed','red','18UHnSTn','trim','151412ohxFIe','\x20\x20Checking\x20CSS\x20URL\x20reachability...'];a87_0x1e96=function(){return _0x3b37fe;};return a87_0x1e96();}function onCancel(_0x5dab52){return _0x5dab52['catch'](_0x561fc2=>{const _0x380b01=a87_0x1200;if(_0x561fc2?.[_0x380b01(0xc2)]==='ExitPromptError')throw CliErrors['cancelled'](_0x380b01(0xc1));throw _0x561fc2;});}export function startSpinner(_0x45cb1c){const _0x2b19c9=a87_0x1200;return a87_0xfa552d({'text':_0x45cb1c,'color':_0x2b19c9(0xbc)})[_0x2b19c9(0xc7)]();}function a87_0x1200(_0x1c2704,_0x269441){_0x1c2704=_0x1c2704-0xb4;const _0x1e968c=a87_0x1e96();let _0x120030=_0x1e968c[_0x1c2704];return _0x120030;}export function stopSpinner(_0x162085,_0x14d22f,_0x35274b){const _0x42154c=a87_0x1200;_0x35274b?_0x162085[_0x42154c(0xd6)](_0x14d22f):_0x162085[_0x42154c(0xca)](_0x14d22f);}export async function askConfirm(_0x2010da){return onCancel(confirm({'message':_0x2010da,'theme':{'prefix':''}}));}export async function askJsUrl(_0x1032f3){const _0xae0e62=a87_0x1200;while(!![]){const _0x190e9b=await onCancel(input({'message':_0xae0e62(0xbb),'default':_0x1032f3,'theme':{'prefix':''}}));if(_0x190e9b[_0xae0e62(0xb7)]()==='')throw CliErrors[_0xae0e62(0xcc)](_0xae0e62(0xc1));if(!/^https:\/\/.+\.js(\?.*)?$/[_0xae0e62(0xd7)](_0x190e9b['trim']())){console[_0xae0e62(0xd1)](a87_0x27904c['red'](_0xae0e62(0xc5)));continue;}const _0x18e810=startSpinner(_0xae0e62(0xcb));try{const _0x348359=await isUrlReachable(_0x190e9b[_0xae0e62(0xb7)]());stopSpinner(_0x18e810,_0xae0e62(0xc8),_0x348359);if(!_0x348359){console['error'](a87_0x27904c[_0xae0e62(0xb5)](_0xae0e62(0xce)));continue;}return _0x190e9b[_0xae0e62(0xb7)]();}catch(_0x112e0c){stopSpinner(_0x18e810,_0xae0e62(0xb4),![]);throw _0x112e0c;}}}export async function askCssUrl(_0x39e766){const _0x2aedad=a87_0x1200;while(!![]){const _0x44ca52=await onCancel(input({'message':'\x20\x20CSS\x20URL:','default':_0x39e766,'theme':{'prefix':''}}));if(_0x44ca52[_0x2aedad(0xb7)]()==='')throw CliErrors[_0x2aedad(0xcc)](_0x2aedad(0xc1));if(!/^https:\/\/.+\.css(\?.*)?$/[_0x2aedad(0xd7)](_0x44ca52[_0x2aedad(0xb7)]())){console[_0x2aedad(0xd1)](a87_0x27904c[_0x2aedad(0xb5)]('\x20\x20✗\x20CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL'));continue;}const _0x478cb4=startSpinner(_0x2aedad(0xb9));try{const _0x330d51=await isUrlReachable(_0x44ca52[_0x2aedad(0xb7)]());stopSpinner(_0x478cb4,_0x2aedad(0xcf),_0x330d51);if(!_0x330d51){console[_0x2aedad(0xd1)](a87_0x27904c[_0x2aedad(0xb5)](_0x2aedad(0xc9)));continue;}return _0x44ca52['trim']();}catch(_0x2aef60){stopSpinner(_0x478cb4,_0x2aedad(0xc0),![]);throw _0x2aef60;}}}export async function selectPages(_0x24b3f0,_0x33ed2d,_0x3d4a75){const _0x55af9f=a87_0x1200,_0x10ab47=_0x24b3f0['map'](_0x1ac03c=>({'name':_0x1ac03c[_0x55af9f(0xd5)]+'\x20\x20'+(_0x33ed2d['has'](_0x1ac03c[_0x55af9f(0xda)])?a87_0x27904c[_0x55af9f(0xd8)](_0x55af9f(0xbd)):a87_0x27904c[_0x55af9f(0xd3)](_0x55af9f(0xcd))),'value':_0x1ac03c['label'],'checked':_0x3d4a75?_0x3d4a75['includes'](_0x1ac03c[_0x55af9f(0xd5)]):!_0x33ed2d['has'](_0x1ac03c['path'])}));if(_0x10ab47['length']===0x0)throw new Error(_0x55af9f(0xdd));const _0x2d60dd=await onCancel(checkbox({'message':_0x55af9f(0xc6),'choices':_0x10ab47,'loop':![],'theme':{'prefix':''}}));if(_0x2d60dd[_0x55af9f(0xc4)]===0x0)throw new Error(_0x55af9f(0xba));return _0x24b3f0[_0x55af9f(0xdf)](_0x48043e=>_0x2d60dd[_0x55af9f(0xe2)](_0x48043e[_0x55af9f(0xd5)]));}export function isInteractive(){const _0x4ae36a=a87_0x1200;return process[_0x4ae36a(0xd4)]['isTTY']===!![];}export function requireInteractive(){const _0x47f797=a87_0x1200;if(!isInteractive())throw new Error(_0x47f797(0xbf)+_0x47f797(0xe1));}
1
+ (function(_0x362164,_0x50c627){const _0x5bdef7=a87_0xfd37,_0x49ae70=_0x362164();while(!![]){try{const _0xbd8c76=-parseInt(_0x5bdef7(0xe1))/0x1+parseInt(_0x5bdef7(0xe7))/0x2+parseInt(_0x5bdef7(0xdd))/0x3+parseInt(_0x5bdef7(0xe2))/0x4*(parseInt(_0x5bdef7(0xbc))/0x5)+parseInt(_0x5bdef7(0xe4))/0x6*(-parseInt(_0x5bdef7(0xd6))/0x7)+parseInt(_0x5bdef7(0xd1))/0x8+-parseInt(_0x5bdef7(0xbd))/0x9*(parseInt(_0x5bdef7(0xd4))/0xa);if(_0xbd8c76===_0x50c627)break;else _0x49ae70['push'](_0x49ae70['shift']());}catch(_0x104c0e){_0x49ae70['push'](_0x49ae70['shift']());}}}(a87_0x48e1,0x34d23));import a87_0x3e28e4 from'chalk';import{checkbox,input,confirm}from'@inquirer/prompts';import a87_0x5d2ed3 from'ora';import{isUrlReachable}from'../../../commands/menu/shared/valid-url.js';import{CliErrors}from'../../../errors.js';function onCancel(_0x987741){return _0x987741['catch'](_0x164bd2=>{const _0x333ac9=a87_0xfd37;if(_0x164bd2?.[_0x333ac9(0xd7)]===_0x333ac9(0xcb))throw CliErrors['cancelled']('Cancelled.');throw _0x164bd2;});}function a87_0xfd37(_0x4ee41c,_0xd6096b){_0x4ee41c=_0x4ee41c-0xb8;const _0x48e1e3=a87_0x48e1();let _0xfd37fa=_0x48e1e3[_0x4ee41c];return _0xfd37fa;}function a87_0x48e1(){const _0x215aab=['filter','Cancelled.','948985MEuqAo','564831ZXWVET','CSS\x20URL\x20check\x20failed','cancelled','green','\x20\x20✗\x20JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL','\x20\x20Select\x20menus\x20to\x20sync\x20(space\x20to\x20toggle,\x20a=all,\x20i=invert):','path','\x20\x20✗\x20CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL','[already\x20on\x20platform]','fail','\x20\x20✗\x20JS\x20URL\x20is\x20unreachable','\x20\x20Checking\x20CSS\x20URL\x20reachability...','map','start','ExitPromptError','JS\x20URL\x20checked','length','includes','stdin','gray','3318544kbSSVk','\x20\x20JS\x20URL:','Use\x20--yes\x20to\x20run\x20in\x20non-interactive\x20mode,\x20or\x20pipe\x20data\x20via\x20--params.','100ROKsFk','cyan','241605wNXlnB','name','succeed','label','red','trim','No\x20menus\x20selected.','541596FHqyTZ','\x20\x20✗\x20CSS\x20URL\x20is\x20unreachable','has','This\x20command\x20requires\x20an\x20interactive\x20terminal.\x20','267007jntNBZ','4nfYssG','CSS\x20URL\x20checked','18cxaCJS','[new]','error','858700ZhacWy','\x20\x20CSS\x20URL:','No\x20local\x20pages\x20found.','isTTY'];a87_0x48e1=function(){return _0x215aab;};return a87_0x48e1();}export function startSpinner(_0x3e13e8){const _0x599772=a87_0xfd37;return a87_0x5d2ed3({'text':_0x3e13e8,'color':_0x599772(0xd5)})[_0x599772(0xca)]();}export function stopSpinner(_0x5ac266,_0x35def2,_0x1c1cb4){const _0xa124cd=a87_0xfd37;_0x1c1cb4?_0x5ac266[_0xa124cd(0xd8)](_0x35def2):_0x5ac266[_0xa124cd(0xc6)](_0x35def2);}export async function askConfirm(_0x4bae89){return onCancel(confirm({'message':_0x4bae89,'theme':{'prefix':''}}));}export async function askJsUrl(_0x1141f2){const _0x1d8e63=a87_0xfd37;while(!![]){const _0x68eae1=await onCancel(input({'message':_0x1d8e63(0xd2),'default':_0x1141f2,'theme':{'prefix':''}}));if(_0x68eae1['trim']()==='')throw CliErrors[_0x1d8e63(0xbf)](_0x1d8e63(0xbb));if(!/^https:\/\/.+\.js(\?.*)?$/['test'](_0x68eae1[_0x1d8e63(0xdb)]())){console['error'](a87_0x3e28e4[_0x1d8e63(0xda)](_0x1d8e63(0xc1)));continue;}const _0x1a3f5d=startSpinner('\x20\x20Checking\x20JS\x20URL\x20reachability...');try{const _0x41ece3=await isUrlReachable(_0x68eae1[_0x1d8e63(0xdb)]());stopSpinner(_0x1a3f5d,_0x1d8e63(0xcc),_0x41ece3);if(!_0x41ece3){console['error'](a87_0x3e28e4[_0x1d8e63(0xda)](_0x1d8e63(0xc7)));continue;}return _0x68eae1[_0x1d8e63(0xdb)]();}catch(_0x4a159d){stopSpinner(_0x1a3f5d,'JS\x20URL\x20check\x20failed',![]);throw _0x4a159d;}}}export async function askCssUrl(_0x4534a4){const _0x116060=a87_0xfd37;while(!![]){const _0x2e64e0=await onCancel(input({'message':_0x116060(0xe8),'default':_0x4534a4,'theme':{'prefix':''}}));if(_0x2e64e0[_0x116060(0xdb)]()==='')throw CliErrors[_0x116060(0xbf)]('Cancelled.');if(!/^https:\/\/.+\.css(\?.*)?$/['test'](_0x2e64e0[_0x116060(0xdb)]())){console[_0x116060(0xe6)](a87_0x3e28e4[_0x116060(0xda)](_0x116060(0xc4)));continue;}const _0x461370=startSpinner(_0x116060(0xc8));try{const _0x47a04c=await isUrlReachable(_0x2e64e0[_0x116060(0xdb)]());stopSpinner(_0x461370,_0x116060(0xe3),_0x47a04c);if(!_0x47a04c){console[_0x116060(0xe6)](a87_0x3e28e4[_0x116060(0xda)](_0x116060(0xde)));continue;}return _0x2e64e0[_0x116060(0xdb)]();}catch(_0x534bdb){stopSpinner(_0x461370,_0x116060(0xbe),![]);throw _0x534bdb;}}}export async function selectPages(_0xbe5163,_0x2fdd56,_0x133d62){const _0xaab100=a87_0xfd37,_0x2cafd2=_0xbe5163[_0xaab100(0xc9)](_0x4dc928=>({'name':_0x4dc928[_0xaab100(0xd9)]+'\x20\x20'+(_0x2fdd56[_0xaab100(0xdf)](_0x4dc928[_0xaab100(0xc3)])?a87_0x3e28e4[_0xaab100(0xd0)](_0xaab100(0xc5)):a87_0x3e28e4[_0xaab100(0xc0)](_0xaab100(0xe5))),'value':_0x4dc928[_0xaab100(0xd9)],'checked':_0x133d62?_0x133d62[_0xaab100(0xce)](_0x4dc928['label']):!_0x2fdd56[_0xaab100(0xdf)](_0x4dc928['path'])}));if(_0x2cafd2['length']===0x0)throw new Error(_0xaab100(0xb8));const _0x1b61d0=await onCancel(checkbox({'message':_0xaab100(0xc2),'choices':_0x2cafd2,'loop':![],'theme':{'prefix':''}}));if(_0x1b61d0[_0xaab100(0xcd)]===0x0)throw new Error(_0xaab100(0xdc));return _0xbe5163[_0xaab100(0xba)](_0x3152c1=>_0x1b61d0[_0xaab100(0xce)](_0x3152c1[_0xaab100(0xd9)]));}export function isInteractive(){const _0x304e9c=a87_0xfd37;return process[_0x304e9c(0xcf)][_0x304e9c(0xb9)]===!![];}export function requireInteractive(){const _0x2b64b9=a87_0xfd37;if(!isInteractive())throw new Error(_0x2b64b9(0xe0)+_0x2b64b9(0xd3));}
@@ -1 +1 @@
1
- const a88_0x4c875b=a88_0x2bdd;function a88_0x3f5b(){const _0x23885d=['4JwGMGs','595110mRhDjK','isDirectory','904566ScuvBb','endsWith','17950sAmZBL','495pYUSmw','16543274DqMJRO','11336KwsOyT','src/pages','trim','utf-8','slice','.tsx','split','match','push','filter','path','join','concat','replace','5jBeyPD','1088994oqMxZJ','index.tsx','360372SbPMiZ','\x5c.displayName\x5cs*=\x5cs*[\x22\x27]([^\x22\x27]+)[\x22\x27]','3479GQzwrI'];a88_0x3f5b=function(){return _0x23885d;};return a88_0x3f5b();}(function(_0xd5f306,_0x1de1fb){const _0x1fdb3f=a88_0x2bdd,_0x2e8325=_0xd5f306();while(!![]){try{const _0x430136=parseInt(_0x1fdb3f(0x140))/0x1+parseInt(_0x1fdb3f(0x144))/0x2+parseInt(_0x1fdb3f(0x146))/0x3*(parseInt(_0x1fdb3f(0x143))/0x4)+-parseInt(_0x1fdb3f(0x13d))/0x5*(-parseInt(_0x1fdb3f(0x13e))/0x6)+-parseInt(_0x1fdb3f(0x142))/0x7*(-parseInt(_0x1fdb3f(0x14b))/0x8)+-parseInt(_0x1fdb3f(0x149))/0x9*(-parseInt(_0x1fdb3f(0x148))/0xa)+-parseInt(_0x1fdb3f(0x14a))/0xb;if(_0x430136===_0x1de1fb)break;else _0x2e8325['push'](_0x2e8325['shift']());}catch(_0x59e937){_0x2e8325['push'](_0x2e8325['shift']());}}}(a88_0x3f5b,0x6b6b4));import{readdirSync,statSync,readFileSync}from'fs';function a88_0x2bdd(_0xf1a87b,_0x40af0b){_0xf1a87b=_0xf1a87b-0x135;const _0x3f5be5=a88_0x3f5b();let _0x2bdd5e=_0x3f5be5[_0xf1a87b];return _0x2bdd5e;}import{join,relative,resolve,sep}from'path';const pagesDir=resolve(process['cwd'](),a88_0x4c875b(0x14c));export function extractTitleFromComment(_0x45901d){const _0x296b3b=a88_0x4c875b;try{const _0x399eba=readFileSync(_0x45901d,_0x296b3b(0x14e)),_0x4c504=_0x399eba['match'](/^\s*\/\*\*?([\s\S]*?)\*\//);if(_0x4c504&&_0x4c504[0x1]){const _0x3b7be0=_0x4c504[0x1],_0x3a0ef6=_0x3b7be0['match'](/^\s*\*?\s*title\s*:\s*(.+)/im);if(_0x3a0ef6&&_0x3a0ef6[0x1])return _0x3a0ef6[0x1][_0x296b3b(0x14d)]();}let _0x556652=null;const _0x57c6f8=_0x399eba[_0x296b3b(0x136)](/export\s+default\s+([A-Z][a-zA-Z0-9]*)/);_0x57c6f8&&_0x57c6f8[0x1]&&(_0x556652=_0x57c6f8[0x1]);if(!_0x556652){const _0x4a6e19=_0x399eba[_0x296b3b(0x136)](/export\s+default\s+function\s+([A-Z][a-zA-Z0-9]*)/);_0x4a6e19&&_0x4a6e19[0x1]&&(_0x556652=_0x4a6e19[0x1]);}if(_0x556652){const _0x4ab662=new RegExp('\x5cb'+_0x556652+_0x296b3b(0x141)),_0x3cd11a=_0x399eba[_0x296b3b(0x136)](_0x4ab662);if(_0x3cd11a&&_0x3cd11a[0x1])return _0x3cd11a[0x1];return _0x556652;}return null;}catch(_0x5d54eb){return null;}}export function getLocalPages(_0x66ea94=pagesDir,_0x1bd494=pagesDir){const _0x2b0939=a88_0x4c875b;let _0x3de0a5=[];const _0x35f19a=readdirSync(_0x66ea94);return _0x35f19a['forEach'](_0x5c0f6d=>{const _0x418f3c=a88_0x2bdd,_0x313132=join(_0x66ea94,_0x5c0f6d),_0x41e805=statSync(_0x313132);if(_0x41e805&&_0x41e805[_0x418f3c(0x145)]())_0x3de0a5=_0x3de0a5[_0x418f3c(0x13b)](getLocalPages(_0x313132,_0x1bd494));else{if(_0x5c0f6d['endsWith'](_0x418f3c(0x150))){let _0x3b16e2=relative(_0x1bd494,_0x313132);_0x3b16e2[_0x418f3c(0x147)](_0x418f3c(0x13f))?_0x3b16e2=_0x3b16e2[_0x418f3c(0x13c)](/index\.tsx$/,''):_0x3b16e2=_0x3b16e2[_0x418f3c(0x13c)](/\.tsx$/,'');_0x3b16e2[_0x418f3c(0x147)](sep)&&(_0x3b16e2=_0x3b16e2[_0x418f3c(0x14f)](0x0,-0x1));const _0xd43c34=_0x3b16e2[_0x418f3c(0x135)](sep)[_0x418f3c(0x13a)]('/'),_0x158299=extractTitleFromComment(_0x313132),_0x2177bc=_0x158299||_0xd43c34;_0x3de0a5[_0x418f3c(0x137)]({'path':_0xd43c34['replaceAll']('$',':'),'label':_0x2177bc});}}}),_0x3de0a5[_0x2b0939(0x138)](_0x5d835c=>_0x5d835c[_0x2b0939(0x139)]!=='');}
1
+ (function(_0x281996,_0xbe01c5){const _0x51ca23=a88_0x1bfd,_0x46acd4=_0x281996();while(!![]){try{const _0x45c84e=-parseInt(_0x51ca23(0xc2))/0x1+parseInt(_0x51ca23(0xc3))/0x2+-parseInt(_0x51ca23(0xc5))/0x3+parseInt(_0x51ca23(0xcb))/0x4*(-parseInt(_0x51ca23(0xd3))/0x5)+-parseInt(_0x51ca23(0xd0))/0x6+-parseInt(_0x51ca23(0xca))/0x7*(parseInt(_0x51ca23(0xd2))/0x8)+parseInt(_0x51ca23(0xcc))/0x9*(parseInt(_0x51ca23(0xbe))/0xa);if(_0x45c84e===_0xbe01c5)break;else _0x46acd4['push'](_0x46acd4['shift']());}catch(_0x4c6430){_0x46acd4['push'](_0x46acd4['shift']());}}}(a88_0x133c,0x8e4c6));import{readdirSync,statSync,readFileSync}from'fs';import{join,relative,resolve,sep}from'path';function a88_0x1bfd(_0x4fbf21,_0x37ce85){_0x4fbf21=_0x4fbf21-0xbe;const _0x133cda=a88_0x133c();let _0x1bfdde=_0x133cda[_0x4fbf21];return _0x1bfdde;}function a88_0x133c(){const _0x2d2799=['filter','push','143767IdeBWS','793112AsLpbK','isDirectory','1216851iNUgDI','index.tsx','.tsx','split','replaceAll','280259vHuber','24ZJxGek','18RKbWGF','utf-8','concat','match','1036014mlSdtL','slice','24kvVYph','359510Uoxovt','endsWith','replace','7299370pVYJwV','path'];a88_0x133c=function(){return _0x2d2799;};return a88_0x133c();}const pagesDir=resolve(process['cwd'](),'src/pages');export function extractTitleFromComment(_0x35181e){const _0x33f2c7=a88_0x1bfd;try{const _0x13267e=readFileSync(_0x35181e,_0x33f2c7(0xcd)),_0xee2f53=_0x13267e[_0x33f2c7(0xcf)](/^\s*\/\*\*?([\s\S]*?)\*\//);if(_0xee2f53&&_0xee2f53[0x1]){const _0x2232cb=_0xee2f53[0x1],_0x2928c2=_0x2232cb[_0x33f2c7(0xcf)](/^\s*\*?\s*title\s*:\s*(.+)/im);if(_0x2928c2&&_0x2928c2[0x1])return _0x2928c2[0x1]['trim']();}let _0x4d2206=null;const _0x35856e=_0x13267e[_0x33f2c7(0xcf)](/export\s+default\s+([A-Z][a-zA-Z0-9]*)/);_0x35856e&&_0x35856e[0x1]&&(_0x4d2206=_0x35856e[0x1]);if(!_0x4d2206){const _0x5de73d=_0x13267e[_0x33f2c7(0xcf)](/export\s+default\s+function\s+([A-Z][a-zA-Z0-9]*)/);_0x5de73d&&_0x5de73d[0x1]&&(_0x4d2206=_0x5de73d[0x1]);}if(_0x4d2206){const _0x3bd1dc=new RegExp('\x5cb'+_0x4d2206+'\x5c.displayName\x5cs*=\x5cs*[\x22\x27]([^\x22\x27]+)[\x22\x27]'),_0x9dd9c7=_0x13267e['match'](_0x3bd1dc);if(_0x9dd9c7&&_0x9dd9c7[0x1])return _0x9dd9c7[0x1];return _0x4d2206;}return null;}catch(_0x1840db){return null;}}export function getLocalPages(_0x4111a1=pagesDir,_0x57973b=pagesDir){const _0x5e4622=a88_0x1bfd;let _0x180eca=[];const _0x1ce456=readdirSync(_0x4111a1);return _0x1ce456['forEach'](_0x5c1f37=>{const _0x42ca21=a88_0x1bfd,_0x100b76=join(_0x4111a1,_0x5c1f37),_0x2dd68d=statSync(_0x100b76);if(_0x2dd68d&&_0x2dd68d[_0x42ca21(0xc4)]())_0x180eca=_0x180eca[_0x42ca21(0xce)](getLocalPages(_0x100b76,_0x57973b));else{if(_0x5c1f37[_0x42ca21(0xd4)](_0x42ca21(0xc7))){let _0x229bec=relative(_0x57973b,_0x100b76);_0x229bec[_0x42ca21(0xd4)](_0x42ca21(0xc6))?_0x229bec=_0x229bec['replace'](/index\.tsx$/,''):_0x229bec=_0x229bec[_0x42ca21(0xd5)](/\.tsx$/,'');_0x229bec[_0x42ca21(0xd4)](sep)&&(_0x229bec=_0x229bec[_0x42ca21(0xd1)](0x0,-0x1));const _0x2b3064=_0x229bec[_0x42ca21(0xc8)](sep)['join']('/'),_0x4e788b=extractTitleFromComment(_0x100b76),_0x32a809=_0x4e788b||_0x2b3064;_0x180eca[_0x42ca21(0xc1)]({'path':_0x2b3064[_0x42ca21(0xc9)]('$',':'),'label':_0x32a809});}}}),_0x180eca[_0x5e4622(0xc0)](_0x1ad6ff=>_0x1ad6ff[_0x5e4622(0xbf)]!=='');}
@@ -1 +1 @@
1
- function a89_0x55cf(){const _0x362315=['path','trim','CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL','filter','6IGLIUo','73026FMZoRS','map','JS\x20URL\x20is\x20unreachable','allSettled','push','JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL','9495448uOJbwj','764476ApIufM','has','9PsRyaf','2779265naFyGj','status','errors','label','1666014EAwebF','extend','length','CSS\x20URL\x20is\x20unreachable','find','3094707YbQJaz','value','363077ymurTq'];a89_0x55cf=function(){return _0x362315;};return a89_0x55cf();}(function(_0x386e9d,_0x49b273){const _0x32bd1f=a89_0x5847,_0x2f17dc=_0x386e9d();while(!![]){try{const _0x28f822=-parseInt(_0x32bd1f(0x1b2))/0x1+-parseInt(_0x32bd1f(0x1b8))/0x2+-parseInt(_0x32bd1f(0x1ab))/0x3+parseInt(_0x32bd1f(0x1bf))/0x4+-parseInt(_0x32bd1f(0x1a7))/0x5*(parseInt(_0x32bd1f(0x1b7))/0x6)+parseInt(_0x32bd1f(0x1b0))/0x7+parseInt(_0x32bd1f(0x1be))/0x8*(parseInt(_0x32bd1f(0x1c1))/0x9);if(_0x28f822===_0x49b273)break;else _0x2f17dc['push'](_0x2f17dc['shift']());}catch(_0xad04e){_0x2f17dc['push'](_0x2f17dc['shift']());}}}(a89_0x55cf,0x4b87a));import{getLocalPages}from'../../../commands/menu/shared/local-pages.js';import{getOnlineMenuList,createMenus,updateMenuCdnUrl}from'../../../commands/menu/shared/service.js';import{isUrlReachable,isValidCssHttpsUrl,isValidJsHttpsUrl}from'../../../commands/menu/shared/valid-url.js';export function validateJsUrl(_0x422fc5){const _0x369f04=a89_0x5847,_0x21cba4=[];return!isValidJsHttpsUrl(_0x422fc5)&&_0x21cba4[_0x369f04(0x1bc)](_0x369f04(0x1bd)),{'ok':_0x21cba4[_0x369f04(0x1ad)]===0x0,'errors':_0x21cba4};}export function validateCssUrl(_0x270e3a){const _0x380246=a89_0x5847,_0x4d6c4f=[];return!isValidCssHttpsUrl(_0x270e3a)&&_0x4d6c4f[_0x380246(0x1bc)](_0x380246(0x1b5)),{'ok':_0x4d6c4f[_0x380246(0x1ad)]===0x0,'errors':_0x4d6c4f};}function a89_0x5847(_0x40498a,_0x4aa5d3){_0x40498a=_0x40498a-0x1a7;const _0x55cfbd=a89_0x55cf();let _0x5847c8=_0x55cfbd[_0x40498a];return _0x5847c8;}export async function validateJsUrlReachable(_0x52931a){const _0x5731b1=a89_0x5847,_0x1048b0=validateJsUrl(_0x52931a);if(!_0x1048b0['ok'])return _0x1048b0;const _0x32ca27=await isUrlReachable(_0x52931a);if(!_0x32ca27)_0x1048b0[_0x5731b1(0x1a9)]['push'](_0x5731b1(0x1ba));return{'ok':_0x1048b0['errors'][_0x5731b1(0x1ad)]===0x0,'errors':_0x1048b0['errors']};}export async function validateCssUrlReachable(_0x1be35b){const _0x5b5e4b=a89_0x5847,_0x55d5b9=validateCssUrl(_0x1be35b);if(!_0x55d5b9['ok'])return _0x55d5b9;const _0x338e50=await isUrlReachable(_0x1be35b);if(!_0x338e50)_0x55d5b9[_0x5b5e4b(0x1a9)][_0x5b5e4b(0x1bc)](_0x5b5e4b(0x1ae));return{'ok':_0x55d5b9[_0x5b5e4b(0x1a9)]['length']===0x0,'errors':_0x55d5b9['errors']};}export function buildCompareRows(_0x5dd7dc,_0x3309ad){const _0x878aff=a89_0x5847;return _0x5dd7dc[_0x878aff(0x1b9)](_0x3cb124=>({'label':_0x3cb124[_0x878aff(0x1aa)],'path':_0x3cb124[_0x878aff(0x1b3)],'local':!![],'online':_0x3309ad[_0x878aff(0x1c0)](_0x3cb124[_0x878aff(0x1b3)])}));}export function filterNewPages(_0x2e96b3,_0x3f596c,_0x4e31d1){const _0xe25848=a89_0x5847;if(_0x4e31d1&&_0x4e31d1[_0xe25848(0x1ad)]>0x0){const _0x578526=new Set(_0x4e31d1[_0xe25848(0x1b9)](_0x170112=>_0x170112[_0xe25848(0x1b4)]())),_0x279a41=_0x2e96b3[_0xe25848(0x1b6)](_0x2db880=>_0x578526[_0xe25848(0x1c0)](_0x2db880[_0xe25848(0x1aa)]));if(_0x279a41[_0xe25848(0x1ad)]===0x0)throw new Error('No\x20local\x20pages\x20matched\x20labels:\x20'+[..._0x578526]['join'](',\x20'));return _0x279a41;}return _0x2e96b3[_0xe25848(0x1b6)](_0xd606ad=>!_0x3f596c[_0xe25848(0x1c0)](_0xd606ad['path']));}export function filterPagesByLabels(_0x298696,_0x17b0d0){const _0x37c269=a89_0x5847,_0xc644f7=[],_0x4d40f0=[];for(const _0x50d9a3 of _0x17b0d0){const _0x5a6079=_0x50d9a3['trim'](),_0x557ed5=_0x298696[_0x37c269(0x1af)](_0x24c83f=>_0x24c83f[_0x37c269(0x1aa)]===_0x5a6079);if(_0x557ed5)_0xc644f7[_0x37c269(0x1bc)](_0x557ed5);else _0x4d40f0[_0x37c269(0x1bc)](_0x50d9a3);}return{'matched':_0xc644f7,'unmatched':_0x4d40f0};}export async function doCreateMenus(_0x5309f9,_0x3497ee,_0x56ea06,_0x488561){const _0x3485aa=a89_0x5847,_0x188805=await createMenus(_0x5309f9,_0x3497ee,_0x56ea06,_0x488561);return{'created':_0x188805['length'],'failed':0x0,'labels':_0x56ea06[_0x3485aa(0x1b9)](_0x27c82e=>_0x27c82e[_0x3485aa(0x1aa)]),'menus':_0x188805};}export function filterMenusWithResources(_0x35cf8f){const _0x1b697e=a89_0x5847;return _0x35cf8f[_0x1b697e(0x1b6)](_0x48ffd2=>_0x48ffd2['resources']['length']>0x0);}export async function doUpdateCdnUrls(_0x2af1da,_0x3d312a,_0x20f6e6,_0x2e0608){const _0x15500c=a89_0x5847,_0x384dc8=_0x20f6e6[_0x15500c(0x1b6)](_0x43689e=>_0x43689e['resources']['length']>0x0),_0x236cee=await Promise[_0x15500c(0x1bb)](_0x384dc8[_0x15500c(0x1b9)](_0x25f140=>updateMenuCdnUrl(_0x2af1da,_0x3d312a,{'id':_0x25f140['id'],'label':_0x25f140['label'],'path':_0x25f140[_0x15500c(0x1b3)],'resources':_0x2e0608,'extend':_0x25f140[_0x15500c(0x1ac)]??null}))),_0x32966f=_0x236cee[_0x15500c(0x1b6)](_0x54d433=>_0x54d433[_0x15500c(0x1a8)]==='fulfilled')[_0x15500c(0x1b9)](_0x2299a2=>_0x2299a2[_0x15500c(0x1b1)]),_0x250e1a=_0x236cee[_0x15500c(0x1b6)](_0x1d5283=>_0x1d5283[_0x15500c(0x1a8)]==='rejected')[_0x15500c(0x1ad)];return{'updated':_0x32966f[_0x15500c(0x1ad)],'failed':_0x250e1a,'menus':_0x32966f};}export async function fetchMenuData(_0x3eec81,_0x15d6d7){const _0x512ea8=a89_0x5847,_0x51541e=getLocalPages(),_0x60db89=await getOnlineMenuList(_0x3eec81,_0x15d6d7),_0x5d128b=new Set(_0x60db89[_0x512ea8(0x1b9)](_0x321128=>_0x321128[_0x512ea8(0x1b3)]));return{'localPages':_0x51541e,'onlineMenuList':_0x60db89,'onlinePaths':_0x5d128b};}export async function fetchOnlineMenuList(_0x78421a,_0x59eb29){return getOnlineMenuList(_0x78421a,_0x59eb29);}
1
+ (function(_0x9cf1da,_0x10a12c){const _0x3643d6=a89_0x4988,_0x58e3cb=_0x9cf1da();while(!![]){try{const _0x50bbd2=-parseInt(_0x3643d6(0xef))/0x1*(-parseInt(_0x3643d6(0xf8))/0x2)+parseInt(_0x3643d6(0xee))/0x3+-parseInt(_0x3643d6(0xed))/0x4*(parseInt(_0x3643d6(0x104))/0x5)+-parseInt(_0x3643d6(0xe7))/0x6+parseInt(_0x3643d6(0xf1))/0x7+-parseInt(_0x3643d6(0xf5))/0x8*(parseInt(_0x3643d6(0xf2))/0x9)+parseInt(_0x3643d6(0xe9))/0xa*(parseInt(_0x3643d6(0xe6))/0xb);if(_0x50bbd2===_0x10a12c)break;else _0x58e3cb['push'](_0x58e3cb['shift']());}catch(_0x17aa30){_0x58e3cb['push'](_0x58e3cb['shift']());}}}(a89_0x548d,0x520a7));function a89_0x548d(){const _0x3e0c12=['41585XhXcBq','map','6303HVKkqR','1166544GDndtj','No\x20local\x20pages\x20matched\x20labels:\x20','1450xCZAhe','join','CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL','length','292PFyhNB','1008870MxPWud','1omaFcf','path','1678376ysJZTQ','81gqKcEc','errors','fulfilled','21256fvHQvw','filter','allSettled','1004748yXEMsq','has','status','label','JS\x20URL\x20is\x20unreachable','resources','trim','push','value','rejected','find','JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL'];a89_0x548d=function(){return _0x3e0c12;};return a89_0x548d();}import{getLocalPages}from'../../../commands/menu/shared/local-pages.js';import{getOnlineMenuList,createMenus,updateMenuCdnUrl}from'../../../commands/menu/shared/service.js';import{isUrlReachable,isValidCssHttpsUrl,isValidJsHttpsUrl}from'../../../commands/menu/shared/valid-url.js';export function validateJsUrl(_0x13369e){const _0x4c381d=a89_0x4988,_0x2057b7=[];return!isValidJsHttpsUrl(_0x13369e)&&_0x2057b7['push'](_0x4c381d(0x103)),{'ok':_0x2057b7[_0x4c381d(0xec)]===0x0,'errors':_0x2057b7};}export function validateCssUrl(_0xddaf6a){const _0x458318=a89_0x4988,_0x4f4943=[];return!isValidCssHttpsUrl(_0xddaf6a)&&_0x4f4943['push'](_0x458318(0xeb)),{'ok':_0x4f4943[_0x458318(0xec)]===0x0,'errors':_0x4f4943};}export async function validateJsUrlReachable(_0x5dc428){const _0x279eca=a89_0x4988,_0x487393=validateJsUrl(_0x5dc428);if(!_0x487393['ok'])return _0x487393;const _0x3a41fc=await isUrlReachable(_0x5dc428);if(!_0x3a41fc)_0x487393[_0x279eca(0xf3)][_0x279eca(0xff)](_0x279eca(0xfc));return{'ok':_0x487393[_0x279eca(0xf3)][_0x279eca(0xec)]===0x0,'errors':_0x487393[_0x279eca(0xf3)]};}export async function validateCssUrlReachable(_0x2ce26b){const _0x45cbdf=a89_0x4988,_0x86e099=validateCssUrl(_0x2ce26b);if(!_0x86e099['ok'])return _0x86e099;const _0x3c4a77=await isUrlReachable(_0x2ce26b);if(!_0x3c4a77)_0x86e099[_0x45cbdf(0xf3)][_0x45cbdf(0xff)]('CSS\x20URL\x20is\x20unreachable');return{'ok':_0x86e099[_0x45cbdf(0xf3)][_0x45cbdf(0xec)]===0x0,'errors':_0x86e099['errors']};}export function buildCompareRows(_0x3bcd02,_0x2c7d93){const _0x17e6e4=a89_0x4988;return _0x3bcd02['map'](_0xeeacb2=>({'label':_0xeeacb2[_0x17e6e4(0xfb)],'path':_0xeeacb2[_0x17e6e4(0xf0)],'local':!![],'online':_0x2c7d93[_0x17e6e4(0xf9)](_0xeeacb2[_0x17e6e4(0xf0)])}));}export function filterNewPages(_0x32ee8f,_0x3b9eb0,_0x3760f8){const _0x26a376=a89_0x4988;if(_0x3760f8&&_0x3760f8[_0x26a376(0xec)]>0x0){const _0x52696b=new Set(_0x3760f8['map'](_0x25ef80=>_0x25ef80[_0x26a376(0xfe)]())),_0x174382=_0x32ee8f[_0x26a376(0xf6)](_0x598a53=>_0x52696b['has'](_0x598a53[_0x26a376(0xfb)]));if(_0x174382['length']===0x0)throw new Error(_0x26a376(0xe8)+[..._0x52696b][_0x26a376(0xea)](',\x20'));return _0x174382;}return _0x32ee8f[_0x26a376(0xf6)](_0x583e65=>!_0x3b9eb0[_0x26a376(0xf9)](_0x583e65[_0x26a376(0xf0)]));}export function filterPagesByLabels(_0x7655b9,_0x2077f6){const _0x57254c=a89_0x4988,_0x4dce5a=[],_0x115f0b=[];for(const _0x40763f of _0x2077f6){const _0x4636ab=_0x40763f[_0x57254c(0xfe)](),_0x222efd=_0x7655b9[_0x57254c(0x102)](_0x116636=>_0x116636[_0x57254c(0xfb)]===_0x4636ab);if(_0x222efd)_0x4dce5a[_0x57254c(0xff)](_0x222efd);else _0x115f0b[_0x57254c(0xff)](_0x40763f);}return{'matched':_0x4dce5a,'unmatched':_0x115f0b};}export async function doCreateMenus(_0x574c2c,_0x3db4b5,_0x274019,_0x4970db){const _0x16d08b=a89_0x4988,_0x2bf009=await createMenus(_0x574c2c,_0x3db4b5,_0x274019,_0x4970db);return{'created':_0x2bf009[_0x16d08b(0xec)],'failed':0x0,'labels':_0x274019[_0x16d08b(0xe5)](_0x547002=>_0x547002[_0x16d08b(0xfb)]),'menus':_0x2bf009};}export function filterMenusWithResources(_0x473fe6){const _0x3a52e1=a89_0x4988;return _0x473fe6['filter'](_0x49e959=>_0x49e959[_0x3a52e1(0xfd)][_0x3a52e1(0xec)]>0x0);}export async function doUpdateCdnUrls(_0x4064e3,_0x4de9c3,_0x57abd8,_0x47916d){const _0x172347=a89_0x4988,_0x59cba0=_0x57abd8['filter'](_0x100dfc=>_0x100dfc['resources']['length']>0x0),_0x1a1e12=await Promise[_0x172347(0xf7)](_0x59cba0['map'](_0x1bc266=>updateMenuCdnUrl(_0x4064e3,_0x4de9c3,{'id':_0x1bc266['id'],'label':_0x1bc266[_0x172347(0xfb)],'path':_0x1bc266[_0x172347(0xf0)],'resources':_0x47916d,'extend':_0x1bc266['extend']??null}))),_0x35f6d9=_0x1a1e12['filter'](_0x249f95=>_0x249f95['status']===_0x172347(0xf4))[_0x172347(0xe5)](_0x45a1bb=>_0x45a1bb[_0x172347(0x100)]),_0x20fe9f=_0x1a1e12[_0x172347(0xf6)](_0x1e09fb=>_0x1e09fb[_0x172347(0xfa)]===_0x172347(0x101))[_0x172347(0xec)];return{'updated':_0x35f6d9[_0x172347(0xec)],'failed':_0x20fe9f,'menus':_0x35f6d9};}function a89_0x4988(_0x5c8c08,_0x2c68d3){_0x5c8c08=_0x5c8c08-0xe5;const _0x548d10=a89_0x548d();let _0x498809=_0x548d10[_0x5c8c08];return _0x498809;}export async function fetchMenuData(_0x30930a,_0x49455e){const _0x61267d=a89_0x4988,_0x1b98c2=getLocalPages(),_0x5b4a03=await getOnlineMenuList(_0x30930a,_0x49455e),_0x3942fa=new Set(_0x5b4a03[_0x61267d(0xe5)](_0x2d52a3=>_0x2d52a3['path']));return{'localPages':_0x1b98c2,'onlineMenuList':_0x5b4a03,'onlinePaths':_0x3942fa};}export async function fetchOnlineMenuList(_0x1af9d7,_0x416762){return getOnlineMenuList(_0x1af9d7,_0x416762);}
@@ -1 +1 @@
1
- function a90_0x1507(_0x812022,_0x153c86){_0x812022=_0x812022-0x199;const _0x53f034=a90_0x53f0();let _0x15071f=_0x53f034[_0x812022];return _0x15071f;}(function(_0x4fdcfc,_0x420ea5){const _0x4f4c10=a90_0x1507,_0x466ef2=_0x4fdcfc();while(!![]){try{const _0x57ae9f=-parseInt(_0x4f4c10(0x19a))/0x1*(parseInt(_0x4f4c10(0x1b7))/0x2)+parseInt(_0x4f4c10(0x1ad))/0x3+-parseInt(_0x4f4c10(0x1b4))/0x4*(-parseInt(_0x4f4c10(0x1ab))/0x5)+parseInt(_0x4f4c10(0x19d))/0x6+parseInt(_0x4f4c10(0x19b))/0x7*(-parseInt(_0x4f4c10(0x1b9))/0x8)+parseInt(_0x4f4c10(0x1c0))/0x9+-parseInt(_0x4f4c10(0x1ae))/0xa*(parseInt(_0x4f4c10(0x1a4))/0xb);if(_0x57ae9f===_0x420ea5)break;else _0x466ef2['push'](_0x466ef2['shift']());}catch(_0x3105d5){_0x466ef2['push'](_0x466ef2['shift']());}}}(a90_0x53f0,0x29d89));import{getApiDomain}from'../../../constant/domain.js';function a90_0x53f0(){const _0x37ad52=['549492ltDsKi','create-menu','Fetched\x20','Fetching\x20online\x20menu\x20list...\x20(appCode:\x20','Fetch\x20menu\x20list','path','Menu\x20created\x20successfully:\x20','11kRVDgz','flat','isArray','Update\x20menu\x20assets\x20\x22','Server\x20returned\x20empty\x20menu\x20list','children','Create\x20menu\x20\x22','265ypaszt','Start\x20batch\x20menu\x20creation,\x20total\x20','998058bfoQCi','1572580uCGWIb','stringify','info','resources','push','all','2796FfSuXF','parse','procode','978uPCOZh','/smartapi/menu/find?appCode=','16ZlnedX','string','extend','import','Menu\x20assets\x20synced:\x20','/smartapi/menu/create','map','1402290lsNoPq','Creating\x20menu:\x20','POST','length','label','16ZHGvrA','982247fDDgEh','get-online-menu-list'];a90_0x53f0=function(){return _0x37ad52;};return a90_0x53f0();}import{getEnv,isProduction}from'../../../constant/env.js';import{logger}from'../../../utils/logger.js';import{platformFetch}from'../../../core/api-client.js';export async function getOnlineMenuList(_0x3de03c,_0x115d40){const _0x2e9424=a90_0x1507,_0x1a4436=getEnv();logger['info'](_0x2e9424(0x19c),isProduction(_0x1a4436)?_0x2e9424(0x1a0)+_0x3de03c+')':'Fetching\x20daily\x20menu\x20list...\x20(appCode:\x20'+_0x3de03c+')');const _0x5bc820=await platformFetch(getApiDomain()+_0x2e9424(0x1b8)+_0x3de03c,{'cookie':_0x115d40,'label':_0x2e9424(0x1a1)});if(!_0x5bc820)return logger[_0x2e9424(0x1b0)](_0x2e9424(0x19c),_0x2e9424(0x1a8)),[];return logger['info'](_0x2e9424(0x19c),_0x2e9424(0x19f)+_0x5bc820[_0x2e9424(0x1c3)]+'\x20online\x20menus\x20successfully'),_0x5bc820[_0x2e9424(0x1bf)](flattenMenuItem)[_0x2e9424(0x1a5)]();}function flattenMenuItem(_0xe0d182){const _0x22e9c3=a90_0x1507;let _0x5f0c33=[];try{const _0x5ef568=_0xe0d182[_0x22e9c3(0x1bb)]?.[_0x22e9c3(0x1b1)];if(typeof _0x5ef568===_0x22e9c3(0x1ba)){const _0x1acbc2=JSON[_0x22e9c3(0x1b5)](_0x5ef568);if(Array['isArray'](_0x1acbc2))_0x5f0c33=_0x1acbc2[_0x22e9c3(0x1bf)](String);}else Array[_0x22e9c3(0x1a6)](_0x5ef568)&&(_0x5f0c33=_0x5ef568[_0x22e9c3(0x1bf)](String));}catch{}const _0x52637c=[{'id':_0xe0d182['id'],'path':_0xe0d182[_0x22e9c3(0x1a2)],'label':_0xe0d182['label'],'resources':_0x5f0c33,'extend':_0xe0d182[_0x22e9c3(0x1bb)]??null}];if(_0xe0d182['children']&&_0xe0d182[_0x22e9c3(0x1a9)][_0x22e9c3(0x1c3)]>0x0)for(const _0x30e793 of _0xe0d182[_0x22e9c3(0x1a9)]){_0x52637c[_0x22e9c3(0x1b2)](...flattenMenuItem(_0x30e793));}return _0x52637c;}export async function createMenu(_0x3e74a4,_0x1d0571,_0x50f8ba){const _0x2f6654=a90_0x1507;logger[_0x2f6654(0x1b0)]('create-menu',_0x2f6654(0x1c1)+_0x50f8ba[_0x2f6654(0x199)]+'\x20('+_0x50f8ba[_0x2f6654(0x1a2)]+')');const _0x864cd2={'appCode':_0x3e74a4,'type':_0x2f6654(0x1b6),'sort':0x0,'extend':{'loadScriptMode':_0x2f6654(0x1bc),'resources':_0x50f8ba[_0x2f6654(0x1b1)]?JSON[_0x2f6654(0x1af)](_0x50f8ba['resources']):undefined},..._0x50f8ba},_0x1c5503=await platformFetch(getApiDomain()+_0x2f6654(0x1be),{'method':'POST','body':_0x864cd2,'cookie':_0x1d0571,'label':_0x2f6654(0x1aa)+_0x50f8ba[_0x2f6654(0x199)]+'\x22'});return logger[_0x2f6654(0x1b0)]('create-menu','Menu\x20created\x20successfully:\x20'+_0x50f8ba[_0x2f6654(0x199)]),_0x1c5503;}async function createSingleMenu(_0x1d3e3d,_0x12366f,_0x3a6100,_0x20a0be){const _0x35c583=a90_0x1507,_0x3c1c7e={'appCode':_0x1d3e3d,'type':_0x35c583(0x1b6),'sort':0x0,'extend':{'loadScriptMode':'import','resources':_0x20a0be?JSON[_0x35c583(0x1af)](_0x20a0be):undefined},'label':_0x3a6100['label'],'path':_0x3a6100[_0x35c583(0x1a2)]},_0x292ff3=await platformFetch(getApiDomain()+_0x35c583(0x1be),{'method':_0x35c583(0x1c2),'body':_0x3c1c7e,'cookie':_0x12366f,'label':_0x35c583(0x1aa)+_0x3a6100[_0x35c583(0x199)]+'\x22'});return logger[_0x35c583(0x1b0)](_0x35c583(0x19e),_0x35c583(0x1a3)+_0x3a6100[_0x35c583(0x199)]),_0x292ff3;}export async function createMenus(_0x3c6e51,_0x231077,_0x51a49b,_0x2fe25d){const _0x3d33eb=a90_0x1507;logger[_0x3d33eb(0x1b0)]('create-menus',_0x3d33eb(0x1ac)+_0x51a49b[_0x3d33eb(0x1c3)]);const _0x12b3ea=await Promise[_0x3d33eb(0x1b3)](_0x51a49b[_0x3d33eb(0x1bf)](_0x1e97a2=>createSingleMenu(_0x3c6e51,_0x231077,_0x1e97a2,_0x2fe25d)));return logger['info']('create-menus','Batch\x20menu\x20creation\x20completed,\x20total\x20'+_0x51a49b[_0x3d33eb(0x1c3)]),_0x12b3ea;}export async function updateMenuCdnUrl(_0x5b3090,_0x136ebe,_0x11a8f2){const _0x8d23f8=a90_0x1507;logger[_0x8d23f8(0x1b0)]('update-menu-cdn-url','Updating\x20menu\x20asset\x20links:\x20'+_0x11a8f2['label']+'\x20('+_0x11a8f2[_0x8d23f8(0x1a2)]+')');const _0x845d7e={'id':_0x11a8f2['id'],'appCode':_0x5b3090,'extend':{..._0x11a8f2['extend']??{},'loadScriptMode':_0x8d23f8(0x1bc),'resources':_0x11a8f2[_0x8d23f8(0x1b1)]?JSON[_0x8d23f8(0x1af)](_0x11a8f2[_0x8d23f8(0x1b1)]):undefined}},_0x2a013f=await platformFetch(getApiDomain()+'/smartapi/menu/update',{'method':_0x8d23f8(0x1c2),'body':_0x845d7e,'cookie':_0x136ebe,'label':_0x8d23f8(0x1a7)+_0x11a8f2[_0x8d23f8(0x199)]+'\x22'});return logger[_0x8d23f8(0x1b0)]('update-menu-cdn-url',_0x8d23f8(0x1bd)+_0x11a8f2[_0x8d23f8(0x199)],undefined),_0x2a013f;}
1
+ (function(_0x363d9a,_0x558bf9){const _0x55bcb5=a90_0x4875,_0x1ecceb=_0x363d9a();while(!![]){try{const _0x532d13=parseInt(_0x55bcb5(0x1dc))/0x1*(-parseInt(_0x55bcb5(0x1d2))/0x2)+-parseInt(_0x55bcb5(0x1cc))/0x3*(-parseInt(_0x55bcb5(0x1cf))/0x4)+parseInt(_0x55bcb5(0x1d3))/0x5*(parseInt(_0x55bcb5(0x1b5))/0x6)+-parseInt(_0x55bcb5(0x1b2))/0x7+parseInt(_0x55bcb5(0x1b3))/0x8+-parseInt(_0x55bcb5(0x1ce))/0x9+-parseInt(_0x55bcb5(0x1d9))/0xa*(-parseInt(_0x55bcb5(0x1c9))/0xb);if(_0x532d13===_0x558bf9)break;else _0x1ecceb['push'](_0x1ecceb['shift']());}catch(_0x4920d5){_0x1ecceb['push'](_0x1ecceb['shift']());}}}(a90_0x312d,0x9479f));import{getApiDomain}from'../../../constant/domain.js';import{getEnv,isProduction}from'../../../constant/env.js';import{logger}from'../../../utils/logger.js';function a90_0x4875(_0x38da91,_0xc9902d){_0x38da91=_0x38da91-0x1b1;const _0x312dc1=a90_0x312d();let _0x4875e4=_0x312dc1[_0x38da91];return _0x4875e4;}import{platformFetch}from'../../../core/api-client.js';export async function getOnlineMenuList(_0x3995f7,_0x35be54){const _0x40e3d1=a90_0x4875,_0x321a2a=getEnv();logger[_0x40e3d1(0x1be)](_0x40e3d1(0x1cb),isProduction(_0x321a2a)?'Fetching\x20online\x20menu\x20list...\x20(appCode:\x20'+_0x3995f7+')':_0x40e3d1(0x1c3)+_0x3995f7+')');const _0x5695d9=await platformFetch(getApiDomain()+'/smartapi/menu/find?appCode='+_0x3995f7,{'cookie':_0x35be54,'label':'Fetch\x20menu\x20list'});if(!_0x5695d9)return logger[_0x40e3d1(0x1be)](_0x40e3d1(0x1cb),_0x40e3d1(0x1d1)),[];return logger[_0x40e3d1(0x1be)](_0x40e3d1(0x1cb),_0x40e3d1(0x1b8)+_0x5695d9[_0x40e3d1(0x1b6)]+_0x40e3d1(0x1b1)),_0x5695d9['map'](flattenMenuItem)[_0x40e3d1(0x1c4)]();}function flattenMenuItem(_0x44dff5){const _0x58fadf=a90_0x4875;let _0x11d323=[];try{const _0x40d19b=_0x44dff5['extend']?.[_0x58fadf(0x1b9)];if(typeof _0x40d19b===_0x58fadf(0x1c6)){const _0x43d82a=JSON[_0x58fadf(0x1c8)](_0x40d19b);if(Array[_0x58fadf(0x1b7)](_0x43d82a))_0x11d323=_0x43d82a[_0x58fadf(0x1d7)](String);}else Array[_0x58fadf(0x1b7)](_0x40d19b)&&(_0x11d323=_0x40d19b[_0x58fadf(0x1d7)](String));}catch{}const _0x5cd078=[{'id':_0x44dff5['id'],'path':_0x44dff5[_0x58fadf(0x1d6)],'label':_0x44dff5[_0x58fadf(0x1c5)],'resources':_0x11d323,'extend':_0x44dff5[_0x58fadf(0x1d4)]??null}];if(_0x44dff5[_0x58fadf(0x1bd)]&&_0x44dff5['children'][_0x58fadf(0x1b6)]>0x0)for(const _0x1b1726 of _0x44dff5['children']){_0x5cd078[_0x58fadf(0x1d5)](...flattenMenuItem(_0x1b1726));}return _0x5cd078;}export async function createMenu(_0x1c4915,_0x3a430c,_0x3581dc){const _0x48966f=a90_0x4875;logger[_0x48966f(0x1be)](_0x48966f(0x1d0),_0x48966f(0x1c7)+_0x3581dc[_0x48966f(0x1c5)]+'\x20('+_0x3581dc[_0x48966f(0x1d6)]+')');const _0x3f6e3e={'appCode':_0x1c4915,'type':_0x48966f(0x1c2),'sort':0x0,'extend':{'loadScriptMode':_0x48966f(0x1d8),'resources':_0x3581dc[_0x48966f(0x1b9)]?JSON[_0x48966f(0x1cd)](_0x3581dc[_0x48966f(0x1b9)]):undefined},..._0x3581dc},_0x4e87bc=await platformFetch(getApiDomain()+_0x48966f(0x1b4),{'method':_0x48966f(0x1ba),'body':_0x3f6e3e,'cookie':_0x3a430c,'label':'Create\x20menu\x20\x22'+_0x3581dc[_0x48966f(0x1c5)]+'\x22'});return logger[_0x48966f(0x1be)](_0x48966f(0x1d0),_0x48966f(0x1db)+_0x3581dc[_0x48966f(0x1c5)]),_0x4e87bc;}function a90_0x312d(){const _0x3e36e1=['3287172GqJnQH','1840128tqIgnl','/smartapi/menu/create','54288ZXGfUs','length','isArray','Fetched\x20','resources','POST','update-menu-cdn-url','Start\x20batch\x20menu\x20creation,\x20total\x20','children','info','Batch\x20menu\x20creation\x20completed,\x20total\x20','Create\x20menu\x20\x22','all','procode','Fetching\x20daily\x20menu\x20list...\x20(appCode:\x20','flat','label','string','Creating\x20menu:\x20','parse','19810879NxlbwB','Menu\x20assets\x20synced:\x20','get-online-menu-list','6iyffvn','stringify','10774575POcbaf','361276uZygzy','create-menu','Server\x20returned\x20empty\x20menu\x20list','542978srpbet','185LiroDt','extend','push','path','map','import','10BCVHiT','Updating\x20menu\x20asset\x20links:\x20','Menu\x20created\x20successfully:\x20','1ZYZCVB','\x20online\x20menus\x20successfully'];a90_0x312d=function(){return _0x3e36e1;};return a90_0x312d();}async function createSingleMenu(_0x329ca1,_0x518486,_0x2704c5,_0x253906){const _0x101265=a90_0x4875,_0x33b194={'appCode':_0x329ca1,'type':'procode','sort':0x0,'extend':{'loadScriptMode':_0x101265(0x1d8),'resources':_0x253906?JSON[_0x101265(0x1cd)](_0x253906):undefined},'label':_0x2704c5['label'],'path':_0x2704c5[_0x101265(0x1d6)]},_0x381c83=await platformFetch(getApiDomain()+'/smartapi/menu/create',{'method':_0x101265(0x1ba),'body':_0x33b194,'cookie':_0x518486,'label':_0x101265(0x1c0)+_0x2704c5[_0x101265(0x1c5)]+'\x22'});return logger[_0x101265(0x1be)](_0x101265(0x1d0),_0x101265(0x1db)+_0x2704c5[_0x101265(0x1c5)]),_0x381c83;}export async function createMenus(_0x101ab8,_0x9a67a4,_0x4c633d,_0x5d1a15){const _0x1ada73=a90_0x4875;logger[_0x1ada73(0x1be)]('create-menus',_0x1ada73(0x1bc)+_0x4c633d[_0x1ada73(0x1b6)]);const _0x1a7179=await Promise[_0x1ada73(0x1c1)](_0x4c633d[_0x1ada73(0x1d7)](_0x34e60b=>createSingleMenu(_0x101ab8,_0x9a67a4,_0x34e60b,_0x5d1a15)));return logger['info']('create-menus',_0x1ada73(0x1bf)+_0x4c633d[_0x1ada73(0x1b6)]),_0x1a7179;}export async function updateMenuCdnUrl(_0xebfe6f,_0x928d72,_0x3ba981){const _0x4fc1c7=a90_0x4875;logger['info']('update-menu-cdn-url',_0x4fc1c7(0x1da)+_0x3ba981[_0x4fc1c7(0x1c5)]+'\x20('+_0x3ba981['path']+')');const _0x43639c={'id':_0x3ba981['id'],'appCode':_0xebfe6f,'extend':{..._0x3ba981[_0x4fc1c7(0x1d4)]??{},'loadScriptMode':_0x4fc1c7(0x1d8),'resources':_0x3ba981[_0x4fc1c7(0x1b9)]?JSON[_0x4fc1c7(0x1cd)](_0x3ba981['resources']):undefined}},_0x220b14=await platformFetch(getApiDomain()+'/smartapi/menu/update',{'method':'POST','body':_0x43639c,'cookie':_0x928d72,'label':'Update\x20menu\x20assets\x20\x22'+_0x3ba981[_0x4fc1c7(0x1c5)]+'\x22'});return logger[_0x4fc1c7(0x1be)](_0x4fc1c7(0x1bb),_0x4fc1c7(0x1ca)+_0x3ba981[_0x4fc1c7(0x1c5)],undefined),_0x220b14;}
@@ -1 +1 @@
1
- (function(_0x1b02a7,_0x578461){const _0x3183d2=a91_0x1d7b,_0x52085a=_0x1b02a7();while(!![]){try{const _0x3c767d=parseInt(_0x3183d2(0x119))/0x1*(parseInt(_0x3183d2(0x120))/0x2)+parseInt(_0x3183d2(0x10e))/0x3*(parseInt(_0x3183d2(0x111))/0x4)+-parseInt(_0x3183d2(0x129))/0x5+parseInt(_0x3183d2(0x115))/0x6+-parseInt(_0x3183d2(0x124))/0x7+-parseInt(_0x3183d2(0x118))/0x8+parseInt(_0x3183d2(0x12e))/0x9;if(_0x3c767d===_0x578461)break;else _0x52085a['push'](_0x52085a['shift']());}catch(_0x500adf){_0x52085a['push'](_0x52085a['shift']());}}}(a91_0xb7db,0x3a8d0));import{getLocalPages}from'../../../commands/menu/shared/local-pages.js';import{getOnlineMenuList,createMenus}from'../../../commands/menu/shared/service.js';import{isUrlReachable,isValidCssHttpsUrl,isValidJsHttpsUrl}from'../../../commands/menu/shared/valid-url.js';import{logger}from'../../../utils/logger.js';function a91_0x1d7b(_0x5193e6,_0x4fd2f0){_0x5193e6=_0x5193e6-0xff;const _0xb7db9c=a91_0xb7db();let _0x1d7bcb=_0xb7db9c[_0x5193e6];return _0x1d7bcb;}function validateParams(_0x1618ff){const _0x313086=a91_0x1d7b,_0x172779=[];return _0x1618ff['jsUrl']&&!isValidJsHttpsUrl(_0x1618ff[_0x313086(0x12a)])&&_0x172779['push']({'field':'jsUrl','message':_0x313086(0x112)}),_0x1618ff[_0x313086(0x103)]&&!isValidCssHttpsUrl(_0x1618ff[_0x313086(0x103)])&&_0x172779[_0x313086(0x11f)]({'field':'cssUrl','message':_0x313086(0x11d)}),_0x172779;}function a91_0xb7db(){const _0x14d8f3=['781884pmQpeL','pages','JS\x20URL\x20is\x20unreachable:\x20','end','field','cssUrl','utf8','Invalid\x20--params:\x20','split','string','object','trim','has','message','No\x20local\x20pages\x20matched\x20labels:\x20','length','1956zFEnzx','CSS\x20URL\x20is\x20unreachable:\x20','parse','1556joXLdN','JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL','info','label','939768RNmRSO','filter','data','2502088UJqYxc','1NEnhlI','Start\x20non-interactive\x20menu\x20sync','path','isArray','CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL','cwd','push','817832HHKfhH','join','--params.','Menu\x20sync\x20completed','257957zDAldS','isTTY','stdin','selectedLabels','startsWith','1583060sNjEFo','jsUrl','readableEnded','map','toString'];a91_0xb7db=function(){return _0x14d8f3;};return a91_0xb7db();}export async function runMenuSyncCore(_0x2ea35a,_0x2bfa65,_0x49098b=[],_0x47f9d0){const _0x4a1599=a91_0x1d7b,_0x3e5737=parseParamsFlag(_0x47f9d0),_0x496a9a=_0x49098b[_0x4a1599(0x10d)]>0x0?_0x49098b:_0x3e5737[_0x4a1599(0x127)],_0x3a0d82=_0x3e5737[_0x4a1599(0x12a)],_0x19b67b=_0x3e5737[_0x4a1599(0x103)],_0x58055b=[];if(_0x3a0d82)_0x58055b[_0x4a1599(0x11f)](_0x3a0d82);if(_0x19b67b)_0x58055b[_0x4a1599(0x11f)](_0x19b67b);const _0x100b91=validateParams(_0x3e5737);if(_0x100b91[_0x4a1599(0x10d)]>0x0){const _0x42b417=_0x100b91['map'](_0x4e5b88=>_0x4a1599(0x122)+_0x4e5b88[_0x4a1599(0x102)]+':\x20'+_0x4e5b88[_0x4a1599(0x10b)])[_0x4a1599(0x121)](';\x20');throw new Error(_0x4a1599(0x105)+_0x42b417);}logger['setLogPath'](process[_0x4a1599(0x11e)]()),logger[_0x4a1599(0x113)]('menu-sync',_0x4a1599(0x11a),{'appCode':_0x2ea35a,'selectedCount':_0x496a9a?.['length'],'jsUrl':_0x3a0d82,'cssUrl':_0x19b67b});if(_0x3a0d82){const _0x7bab8e=await isUrlReachable(_0x3a0d82);if(!_0x7bab8e)throw new Error(_0x4a1599(0x100)+_0x3a0d82);}if(_0x19b67b){const _0x10631a=await isUrlReachable(_0x19b67b);if(!_0x10631a)throw new Error(_0x4a1599(0x10f)+_0x19b67b);}const _0x5f281b=getLocalPages();if(_0x5f281b[_0x4a1599(0x10d)]===0x0)return{'created':0x0,'skipped':!![],'targetPages':[]};const _0x5dd794=await getOnlineMenuList(_0x2ea35a,_0x2bfa65),_0x4bcc84=new Set(_0x5dd794[_0x4a1599(0x12c)](_0x71172d=>_0x71172d[_0x4a1599(0x11b)]));let _0x1e65b9;if(_0x496a9a&&_0x496a9a[_0x4a1599(0x10d)]>0x0){const _0x415d79=new Set(_0x496a9a['map'](_0x42f204=>_0x42f204[_0x4a1599(0x109)]()));_0x1e65b9=_0x5f281b[_0x4a1599(0x116)](_0x15b313=>_0x415d79['has'](_0x15b313[_0x4a1599(0x114)]));if(_0x1e65b9[_0x4a1599(0x10d)]===0x0){const _0x474dc9=_0x5f281b[_0x4a1599(0x12c)](_0x219a5d=>_0x219a5d['label'])[_0x4a1599(0x121)](',\x20');throw new Error(_0x4a1599(0x10c)+[..._0x415d79]['join'](',\x20')+'\x0a\x20\x20Available\x20local\x20pages:\x20'+_0x474dc9);}}else _0x1e65b9=_0x5f281b['filter'](_0x47ec0d=>!_0x4bcc84[_0x4a1599(0x10a)](_0x47ec0d['path']));if(_0x1e65b9[_0x4a1599(0x10d)]===0x0)return{'created':0x0,'skipped':!![],'targetPages':[]};const _0x5201c0=await createMenus(_0x2ea35a,_0x2bfa65,_0x1e65b9,_0x58055b[_0x4a1599(0x10d)]>0x0?_0x58055b:undefined);return logger['info']('menu-sync',_0x4a1599(0x123),{'count':_0x1e65b9[_0x4a1599(0x10d)],'resources':_0x58055b}),{'created':_0x5201c0['length'],'skipped':![],'targetPages':_0x1e65b9,'menus':_0x5201c0};}export async function readPageLabelsFromStdin(){const _0x34e6fa=a91_0x1d7b;if(!process['stdin'][_0x34e6fa(0x125)]&&!process[_0x34e6fa(0x126)][_0x34e6fa(0x12b)])return new Promise(_0x28eb23=>{const _0xf3da9b=_0x34e6fa,_0x105dd2=[];process[_0xf3da9b(0x126)]['on'](_0xf3da9b(0x117),_0x5ed148=>_0x105dd2['push'](_0x5ed148)),process[_0xf3da9b(0x126)]['on'](_0xf3da9b(0x101),()=>{const _0x2b1460=_0xf3da9b,_0x1218f8=Buffer['concat'](_0x105dd2)[_0x2b1460(0x12d)](_0x2b1460(0x104)),_0x16a74d=_0x1218f8[_0x2b1460(0x106)]('\x0a')[_0x2b1460(0x12c)](_0xa55b3f=>_0xa55b3f['trim']())[_0x2b1460(0x116)](_0x381ca6=>_0x381ca6[_0x2b1460(0x10d)]>0x0&&!_0x381ca6[_0x2b1460(0x128)]('#'));_0x28eb23(_0x16a74d);}),setTimeout(()=>_0x28eb23([]),0x1f4);});return[];}function parseParamsFlag(_0x53b2b4){const _0x10c10a=a91_0x1d7b;if(!_0x53b2b4||typeof _0x53b2b4!=='string')return{};try{const _0x331afe=JSON[_0x10c10a(0x110)](_0x53b2b4);if(typeof _0x331afe!==_0x10c10a(0x108)||_0x331afe===null||Array['isArray'](_0x331afe))return{};return{'selectedLabels':Array[_0x10c10a(0x11c)](_0x331afe[_0x10c10a(0xff)])?_0x331afe[_0x10c10a(0xff)][_0x10c10a(0x12c)](String):undefined,'jsUrl':typeof _0x331afe[_0x10c10a(0x12a)]===_0x10c10a(0x107)?_0x331afe[_0x10c10a(0x12a)]['trim']():undefined,'cssUrl':typeof _0x331afe[_0x10c10a(0x103)]===_0x10c10a(0x107)?_0x331afe[_0x10c10a(0x103)]['trim']():undefined};}catch{return{};}}
1
+ (function(_0x2e0ef2,_0x1e96dc){const _0x1612f9=a91_0x3c10,_0x4ecc6e=_0x2e0ef2();while(!![]){try{const _0x48bdd0=parseInt(_0x1612f9(0x19c))/0x1+-parseInt(_0x1612f9(0x1ad))/0x2+parseInt(_0x1612f9(0x197))/0x3*(parseInt(_0x1612f9(0x1a9))/0x4)+-parseInt(_0x1612f9(0x1a1))/0x5+parseInt(_0x1612f9(0x19a))/0x6*(-parseInt(_0x1612f9(0x19d))/0x7)+parseInt(_0x1612f9(0x1b6))/0x8+-parseInt(_0x1612f9(0x1b2))/0x9*(-parseInt(_0x1612f9(0x1c4))/0xa);if(_0x48bdd0===_0x1e96dc)break;else _0x4ecc6e['push'](_0x4ecc6e['shift']());}catch(_0x4f809e){_0x4ecc6e['push'](_0x4ecc6e['shift']());}}}(a91_0x4015,0x9f929));import{getLocalPages}from'../../../commands/menu/shared/local-pages.js';import{getOnlineMenuList,createMenus}from'../../../commands/menu/shared/service.js';import{isUrlReachable,isValidCssHttpsUrl,isValidJsHttpsUrl}from'../../../commands/menu/shared/valid-url.js';function a91_0x4015(){const _0x6c7098=['1078446WhDdUP','21bSMoZI','\x0a\x20\x20Available\x20local\x20pages:\x20','toString','data','1132855hqhpJM','CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL','pages','field','push','object','label','isArray','7916GwlpQh','cssUrl','cwd','JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL','2079624KgdfsN','--params.','map','JS\x20URL\x20is\x20unreachable:\x20','join','19962zOrYkC','end','readableEnded','concat','4132536fsQsNH','Invalid\x20--params:\x20','stdin','Menu\x20sync\x20completed','path','info','has','isTTY','jsUrl','menu-sync','message','trim','setLogPath','filter','2770QYfyVa','startsWith','split','length','1413GfcDsN','selectedLabels','Start\x20non-interactive\x20menu\x20sync','2443032lhDEBG','utf8'];a91_0x4015=function(){return _0x6c7098;};return a91_0x4015();}import{logger}from'../../../utils/logger.js';function validateParams(_0x4a0076){const _0x25e9ad=a91_0x3c10,_0x95ef3b=[];return _0x4a0076[_0x25e9ad(0x1be)]&&!isValidJsHttpsUrl(_0x4a0076['jsUrl'])&&_0x95ef3b['push']({'field':_0x25e9ad(0x1be),'message':_0x25e9ad(0x1ac)}),_0x4a0076[_0x25e9ad(0x1aa)]&&!isValidCssHttpsUrl(_0x4a0076[_0x25e9ad(0x1aa)])&&_0x95ef3b['push']({'field':'cssUrl','message':_0x25e9ad(0x1a2)}),_0x95ef3b;}export async function runMenuSyncCore(_0x516e4a,_0x30f877,_0x5e510a=[],_0x33dfd2){const _0x12cd12=a91_0x3c10,_0x11db35=parseParamsFlag(_0x33dfd2),_0x578f96=_0x5e510a[_0x12cd12(0x196)]>0x0?_0x5e510a:_0x11db35[_0x12cd12(0x198)],_0x5385bc=_0x11db35['jsUrl'],_0x916c38=_0x11db35[_0x12cd12(0x1aa)],_0x2dc010=[];if(_0x5385bc)_0x2dc010['push'](_0x5385bc);if(_0x916c38)_0x2dc010['push'](_0x916c38);const _0x448b12=validateParams(_0x11db35);if(_0x448b12[_0x12cd12(0x196)]>0x0){const _0x1a6f20=_0x448b12[_0x12cd12(0x1af)](_0x452d94=>_0x12cd12(0x1ae)+_0x452d94[_0x12cd12(0x1a4)]+':\x20'+_0x452d94[_0x12cd12(0x1c0)])[_0x12cd12(0x1b1)](';\x20');throw new Error(_0x12cd12(0x1b7)+_0x1a6f20);}logger[_0x12cd12(0x1c2)](process[_0x12cd12(0x1ab)]()),logger[_0x12cd12(0x1bb)](_0x12cd12(0x1bf),_0x12cd12(0x199),{'appCode':_0x516e4a,'selectedCount':_0x578f96?.['length'],'jsUrl':_0x5385bc,'cssUrl':_0x916c38});if(_0x5385bc){const _0x57227b=await isUrlReachable(_0x5385bc);if(!_0x57227b)throw new Error(_0x12cd12(0x1b0)+_0x5385bc);}if(_0x916c38){const _0x15c5cb=await isUrlReachable(_0x916c38);if(!_0x15c5cb)throw new Error('CSS\x20URL\x20is\x20unreachable:\x20'+_0x916c38);}const _0x38a567=getLocalPages();if(_0x38a567['length']===0x0)return{'created':0x0,'skipped':!![],'targetPages':[]};const _0x45f68f=await getOnlineMenuList(_0x516e4a,_0x30f877),_0x398fe6=new Set(_0x45f68f[_0x12cd12(0x1af)](_0x1a3520=>_0x1a3520[_0x12cd12(0x1ba)]));let _0x179cea;if(_0x578f96&&_0x578f96[_0x12cd12(0x196)]>0x0){const _0x263599=new Set(_0x578f96[_0x12cd12(0x1af)](_0x3d86ad=>_0x3d86ad['trim']()));_0x179cea=_0x38a567['filter'](_0x2b0301=>_0x263599['has'](_0x2b0301[_0x12cd12(0x1a7)]));if(_0x179cea['length']===0x0){const _0x1c3b83=_0x38a567[_0x12cd12(0x1af)](_0x5a8af1=>_0x5a8af1['label'])[_0x12cd12(0x1b1)](',\x20');throw new Error('No\x20local\x20pages\x20matched\x20labels:\x20'+[..._0x263599]['join'](',\x20')+_0x12cd12(0x19e)+_0x1c3b83);}}else _0x179cea=_0x38a567['filter'](_0x596c02=>!_0x398fe6[_0x12cd12(0x1bc)](_0x596c02[_0x12cd12(0x1ba)]));if(_0x179cea[_0x12cd12(0x196)]===0x0)return{'created':0x0,'skipped':!![],'targetPages':[]};const _0x43d8a1=await createMenus(_0x516e4a,_0x30f877,_0x179cea,_0x2dc010[_0x12cd12(0x196)]>0x0?_0x2dc010:undefined);return logger[_0x12cd12(0x1bb)](_0x12cd12(0x1bf),_0x12cd12(0x1b9),{'count':_0x179cea[_0x12cd12(0x196)],'resources':_0x2dc010}),{'created':_0x43d8a1[_0x12cd12(0x196)],'skipped':![],'targetPages':_0x179cea,'menus':_0x43d8a1};}function a91_0x3c10(_0x5051f6,_0x51a424){_0x5051f6=_0x5051f6-0x195;const _0x401577=a91_0x4015();let _0x3c1024=_0x401577[_0x5051f6];return _0x3c1024;}export async function readPageLabelsFromStdin(){const _0x475f18=a91_0x3c10;if(!process['stdin'][_0x475f18(0x1bd)]&&!process[_0x475f18(0x1b8)][_0x475f18(0x1b4)])return new Promise(_0x486e09=>{const _0x5b3b71=_0x475f18,_0x39215a=[];process[_0x5b3b71(0x1b8)]['on'](_0x5b3b71(0x1a0),_0x1c5b97=>_0x39215a[_0x5b3b71(0x1a5)](_0x1c5b97)),process[_0x5b3b71(0x1b8)]['on'](_0x5b3b71(0x1b3),()=>{const _0x50133c=_0x5b3b71,_0x3e42fd=Buffer[_0x50133c(0x1b5)](_0x39215a)[_0x50133c(0x19f)](_0x50133c(0x19b)),_0x502d90=_0x3e42fd[_0x50133c(0x195)]('\x0a')[_0x50133c(0x1af)](_0x25d296=>_0x25d296[_0x50133c(0x1c1)]())[_0x50133c(0x1c3)](_0x1d0b5b=>_0x1d0b5b[_0x50133c(0x196)]>0x0&&!_0x1d0b5b[_0x50133c(0x1c5)]('#'));_0x486e09(_0x502d90);}),setTimeout(()=>_0x486e09([]),0x1f4);});return[];}function parseParamsFlag(_0x4916d5){const _0x183f3f=a91_0x3c10;if(!_0x4916d5||typeof _0x4916d5!=='string')return{};try{const _0x4e17b4=JSON['parse'](_0x4916d5);if(typeof _0x4e17b4!==_0x183f3f(0x1a6)||_0x4e17b4===null||Array['isArray'](_0x4e17b4))return{};return{'selectedLabels':Array[_0x183f3f(0x1a8)](_0x4e17b4[_0x183f3f(0x1a3)])?_0x4e17b4[_0x183f3f(0x1a3)][_0x183f3f(0x1af)](String):undefined,'jsUrl':typeof _0x4e17b4[_0x183f3f(0x1be)]==='string'?_0x4e17b4['jsUrl']['trim']():undefined,'cssUrl':typeof _0x4e17b4[_0x183f3f(0x1aa)]==='string'?_0x4e17b4[_0x183f3f(0x1aa)][_0x183f3f(0x1c1)]():undefined};}catch{return{};}}
@@ -1 +1 @@
1
- function a93_0x4062(_0x5dcc5c,_0x19318e){_0x5dcc5c=_0x5dcc5c-0xb0;const _0x23cd4b=a93_0x23cd();let _0x4062d4=_0x23cd4b[_0x5dcc5c];return _0x4062d4;}(function(_0x74550b,_0x253f49){const _0x11b225=a93_0x4062,_0x227c48=_0x74550b();while(!![]){try{const _0x3f4403=-parseInt(_0x11b225(0xb0))/0x1+parseInt(_0x11b225(0xe8))/0x2*(-parseInt(_0x11b225(0xe1))/0x3)+parseInt(_0x11b225(0xcc))/0x4+-parseInt(_0x11b225(0xbd))/0x5+-parseInt(_0x11b225(0xd8))/0x6*(-parseInt(_0x11b225(0xd0))/0x7)+parseInt(_0x11b225(0xd5))/0x8*(parseInt(_0x11b225(0xc4))/0x9)+parseInt(_0x11b225(0xbb))/0xa;if(_0x3f4403===_0x253f49)break;else _0x227c48['push'](_0x227c48['shift']());}catch(_0x8387e5){_0x227c48['push'](_0x227c48['shift']());}}}(a93_0x23cd,0xa762f));function a93_0x23cd(){const _0x56ffb4=['info','Start\x20non-interactive\x20menu\x20update','7469640TEcIVo','CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL','6850205PTNgqP','replace','setLogPath','map','field','dryRun','resources','522XombIm','endsWith','split','Pass\x20--params\x20\x27{\x22jsUrl\x22:\x22https://...js\x22,\x22cssUrl\x22:\x22https://...css\x22}\x27\x20to\x20update\x20assets.','CSS\x20URL\x20is\x20unreachable:\x20','message','menu-update','allSettled','4799436ezccZn','Use\x20--mode\x20patch\x20to\x20preserve\x20it,\x20pass\x20jsUrl,\x20or\x20add\x20--force\x20for\x20an\x20intentional\x20removal.','Invalid\x20--params:\x20menu\x20update\x20requires\x20at\x20least\x20one\x20explicit\x20JS/CSS\x20URL.\x20','.css','258797yPICTC','push','Invalid\x20--params:\x20','unshift','isArray','20928RvdRHC','Menu\x20update\x20completed','label','144SMVNhO','length','.\x20Allowed\x20values:\x20replace,\x20patch','status','string','toLowerCase','object','menu\x20update\x20would\x20remove\x20existing\x20JS\x20resource\x20for\x20\x22','fulfilled','387sXaZph','filter','some','cssUrl','patch','path','force','10942dUgVvJ','224440crBOSn','\x22\x20(','value','jsUrl','rejected','menu\x20update\x20will\x20remove\x20existing\x20CSS\x20resource\x20for\x20\x22','JS\x20URL\x20is\x20unreachable:\x20','trim',').\x20'];a93_0x23cd=function(){return _0x56ffb4;};return a93_0x23cd();}import{updateMenuCdnUrl,getOnlineMenuList}from'../../../commands/menu/shared/service.js';import{isUrlReachable,isValidCssHttpsUrl,isValidJsHttpsUrl}from'../../../commands/menu/shared/valid-url.js';import{logger}from'../../../utils/logger.js';function validateParams(_0x44aff8){const _0x42ea78=a93_0x4062,_0x4cba52=[];return _0x44aff8['jsUrl']&&!isValidJsHttpsUrl(_0x44aff8[_0x42ea78(0xb3)])&&_0x4cba52[_0x42ea78(0xd1)]({'field':_0x42ea78(0xb3),'message':'JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL'}),_0x44aff8[_0x42ea78(0xe4)]&&!isValidCssHttpsUrl(_0x44aff8[_0x42ea78(0xe4)])&&_0x4cba52['push']({'field':'cssUrl','message':_0x42ea78(0xbc)}),_0x4cba52;}export async function runMenuUpdateCore(_0x95199,_0x48e6f2,_0x40206a,_0x2cc426={}){const _0x4d74d4=a93_0x4062,_0x590efc=parseUpdateParamsFlag(_0x40206a),_0xa8cce8=normalizeMode(_0x2cc426['mode']),_0xb8a5ce=[];if(_0x590efc[_0x4d74d4(0xb3)])_0xb8a5ce[_0x4d74d4(0xd1)](_0x590efc[_0x4d74d4(0xb3)]);if(_0x590efc['cssUrl'])_0xb8a5ce['push'](_0x590efc[_0x4d74d4(0xe4)]);const _0x124fea=validateParams(_0x590efc);if(_0x124fea['length']>0x0){const _0xa4a427=_0x124fea[_0x4d74d4(0xc0)](_0x447b38=>'--params.'+_0x447b38[_0x4d74d4(0xc1)]+':\x20'+_0x447b38[_0x4d74d4(0xc9)])['join'](';\x20');throw new Error(_0x4d74d4(0xd2)+_0xa4a427);}if(_0xb8a5ce[_0x4d74d4(0xd9)]===0x0)throw new Error(_0x4d74d4(0xce)+_0x4d74d4(0xc7));logger[_0x4d74d4(0xbf)](process['cwd']()),logger['info'](_0x4d74d4(0xca),_0x4d74d4(0xba),{'appCode':_0x95199,'jsUrl':_0x590efc['jsUrl'],'cssUrl':_0x590efc[_0x4d74d4(0xe4)],'mode':_0xa8cce8,'dryRun':_0x2cc426[_0x4d74d4(0xc2)]===!![]});if(_0x590efc[_0x4d74d4(0xb3)]){const _0x42921a=await isUrlReachable(_0x590efc[_0x4d74d4(0xb3)]);if(!_0x42921a)throw new Error(_0x4d74d4(0xb6)+_0x590efc[_0x4d74d4(0xb3)]);}if(_0x590efc[_0x4d74d4(0xe4)]){const _0x26aa59=await isUrlReachable(_0x590efc[_0x4d74d4(0xe4)]);if(!_0x26aa59)throw new Error(_0x4d74d4(0xc8)+_0x590efc[_0x4d74d4(0xe4)]);}const _0x5452d7=await getOnlineMenuList(_0x95199,_0x48e6f2),_0x177f6e=_0x5452d7[_0x4d74d4(0xe2)](_0xf0656c=>_0xf0656c['resources'][_0x4d74d4(0xd9)]>0x0);if(_0x177f6e[_0x4d74d4(0xd9)]===0x0)return{'updated':0x0,'failed':0x0,'skipped':!![],'dryRun':_0x2cc426[_0x4d74d4(0xc2)]===!![]};const _0x23f40b=_0x177f6e[_0x4d74d4(0xc0)](_0x2cd541=>buildMenuUpdateDiff(_0x2cd541,_0x590efc,_0xa8cce8,_0x2cc426[_0x4d74d4(0xe7)]===!![]));if(_0x2cc426[_0x4d74d4(0xc2)])return{'updated':0x0,'failed':0x0,'skipped':![],'dryRun':!![],'diffs':_0x23f40b};const _0x353615=await Promise[_0x4d74d4(0xcb)](_0x177f6e[_0x4d74d4(0xc0)]((_0x257709,_0x48ea81)=>updateMenuCdnUrl(_0x95199,_0x48e6f2,{'id':_0x257709['id'],'label':_0x257709[_0x4d74d4(0xd7)],'path':_0x257709[_0x4d74d4(0xe6)],'resources':_0x23f40b[_0x48ea81]['after'][_0x4d74d4(0xc3)],'extend':_0x257709['extend']??null}))),_0x22fba6=_0x353615[_0x4d74d4(0xe2)](_0x259337=>_0x259337[_0x4d74d4(0xdb)]===_0x4d74d4(0xe0))[_0x4d74d4(0xc0)](_0xd09fcb=>_0xd09fcb[_0x4d74d4(0xb2)]),_0x342b41=_0x353615[_0x4d74d4(0xe2)](_0x10a89d=>_0x10a89d[_0x4d74d4(0xdb)]===_0x4d74d4(0xb4))[_0x4d74d4(0xd9)];return logger[_0x4d74d4(0xb9)](_0x4d74d4(0xca),_0x4d74d4(0xd6),{'count':_0x177f6e[_0x4d74d4(0xd9)],'resources':_0xb8a5ce}),{'updated':_0x22fba6[_0x4d74d4(0xd9)],'failed':_0x342b41,'skipped':![],'menus':_0x22fba6};}function normalizeMode(_0x5c1f30){const _0x2f207f=a93_0x4062;if(!_0x5c1f30)return _0x2f207f(0xbe);if(_0x5c1f30==='replace'||_0x5c1f30==='patch')return _0x5c1f30;throw new Error('Invalid\x20--mode:\x20'+_0x5c1f30+_0x2f207f(0xda));}function buildMenuUpdateDiff(_0x1f1d20,_0x479dca,_0x89f0ca,_0x473912){const _0x1d0e02=a93_0x4062,_0x1ef71c=[..._0x1f1d20[_0x1d0e02(0xc3)]],_0x4f9e2f=_0x89f0ca===_0x1d0e02(0xe5)?patchResources(_0x1ef71c,_0x479dca):replaceResources(_0x479dca),_0x3d4fdd=[],_0xf874e6=_0x1ef71c[_0x1d0e02(0xe3)](isJsResource),_0x2dff4e=_0x4f9e2f[_0x1d0e02(0xe3)](isJsResource);if(_0xf874e6&&!_0x2dff4e){const _0x221641=_0x1d0e02(0xdf)+_0x1f1d20[_0x1d0e02(0xd7)]+_0x1d0e02(0xb1)+_0x1f1d20[_0x1d0e02(0xe6)]+_0x1d0e02(0xb8)+_0x1d0e02(0xcd);if(!_0x473912)throw new Error(_0x221641);_0x3d4fdd[_0x1d0e02(0xd1)](_0x221641);}const _0x576553=_0x1ef71c[_0x1d0e02(0xe3)](isCssResource),_0x47a1e4=_0x4f9e2f[_0x1d0e02(0xe3)](isCssResource);return _0x576553&&!_0x47a1e4&&_0x3d4fdd[_0x1d0e02(0xd1)](_0x1d0e02(0xb5)+_0x1f1d20[_0x1d0e02(0xd7)]+_0x1d0e02(0xb1)+_0x1f1d20[_0x1d0e02(0xe6)]+').'),{'id':_0x1f1d20['id'],'label':_0x1f1d20[_0x1d0e02(0xd7)],'path':_0x1f1d20[_0x1d0e02(0xe6)],'mode':_0x89f0ca,'before':{'resources':_0x1ef71c},'after':{'resources':_0x4f9e2f},'warnings':_0x3d4fdd};}function replaceResources(_0x50364b){const _0x41218a=a93_0x4062;return[_0x50364b[_0x41218a(0xb3)],_0x50364b[_0x41218a(0xe4)]][_0x41218a(0xe2)](_0x5efaae=>!!_0x5efaae);}function patchResources(_0x45f357,_0x1015bb){const _0x2132ed=a93_0x4062;let _0x373a7a=![],_0x12c6e5=![];const _0x46f46d=[];for(const _0x5e3057 of _0x45f357){if(isJsResource(_0x5e3057)){if(_0x1015bb[_0x2132ed(0xb3)]&&!_0x373a7a)_0x46f46d[_0x2132ed(0xd1)](_0x1015bb[_0x2132ed(0xb3)]),_0x373a7a=!![];else!_0x1015bb[_0x2132ed(0xb3)]&&_0x46f46d['push'](_0x5e3057);continue;}if(isCssResource(_0x5e3057)){if(_0x1015bb[_0x2132ed(0xe4)]&&!_0x12c6e5)_0x46f46d[_0x2132ed(0xd1)](_0x1015bb[_0x2132ed(0xe4)]),_0x12c6e5=!![];else!_0x1015bb[_0x2132ed(0xe4)]&&_0x46f46d[_0x2132ed(0xd1)](_0x5e3057);continue;}_0x46f46d[_0x2132ed(0xd1)](_0x5e3057);}return _0x1015bb[_0x2132ed(0xb3)]&&!_0x373a7a&&_0x46f46d[_0x2132ed(0xd3)](_0x1015bb['jsUrl']),_0x1015bb[_0x2132ed(0xe4)]&&!_0x12c6e5&&_0x46f46d[_0x2132ed(0xd1)](_0x1015bb[_0x2132ed(0xe4)]),_0x46f46d;}function isJsResource(_0x509bda){const _0x37366d=a93_0x4062;return stripQuery(_0x509bda)[_0x37366d(0xdd)]()[_0x37366d(0xc5)]('.js');}function isCssResource(_0x122495){const _0x2a3722=a93_0x4062;return stripQuery(_0x122495)[_0x2a3722(0xdd)]()[_0x2a3722(0xc5)](_0x2a3722(0xcf));}function stripQuery(_0x26e27a){const _0x472b83=a93_0x4062;return _0x26e27a[_0x472b83(0xc6)]('?')[0x0]??_0x26e27a;}function parseUpdateParamsFlag(_0x53ea36){const _0x2eacca=a93_0x4062;if(!_0x53ea36||typeof _0x53ea36!=='string')return{};try{const _0x79523d=JSON['parse'](_0x53ea36);if(typeof _0x79523d!==_0x2eacca(0xde)||_0x79523d===null||Array[_0x2eacca(0xd4)](_0x79523d))return{};return{'jsUrl':typeof _0x79523d[_0x2eacca(0xb3)]===_0x2eacca(0xdc)?_0x79523d[_0x2eacca(0xb3)][_0x2eacca(0xb7)]():undefined,'cssUrl':typeof _0x79523d[_0x2eacca(0xe4)]===_0x2eacca(0xdc)?_0x79523d['cssUrl'][_0x2eacca(0xb7)]():undefined};}catch{return{};}}
1
+ function a93_0x5edd(){const _0x28eee9=['120rtekcN','trim','push','endsWith','JS\x20URL\x20is\x20unreachable:\x20','.js','Invalid\x20--mode:\x20','3780434TqPMhX','extend','17088038EhReLc','field','Invalid\x20--params:\x20menu\x20update\x20requires\x20at\x20least\x20one\x20explicit\x20JS/CSS\x20URL.\x20','menu-update','Invalid\x20--params:\x20','after','JS\x20URL\x20must\x20be\x20a\x20valid\x20https://...js\x20URL','string','596fLaMvF',').\x20','isArray','map','length','mode','2145625EyResK','245277XMLDza','allSettled','CSS\x20URL\x20is\x20unreachable:\x20','parse','setLogPath','force','some','info','object','path','toLowerCase','value','Pass\x20--params\x20\x27{\x22jsUrl\x22:\x22https://...js\x22,\x22cssUrl\x22:\x22https://...css\x22}\x27\x20to\x20update\x20assets.','status','unshift','label','jsUrl','patch','cssUrl','48qUNREX','Start\x20non-interactive\x20menu\x20update','resources','10pNdJgN','Use\x20--mode\x20patch\x20to\x20preserve\x20it,\x20pass\x20jsUrl,\x20or\x20add\x20--force\x20for\x20an\x20intentional\x20removal.','1378kkGgpt','split','filter','--params.','dryRun','fulfilled','join','CSS\x20URL\x20must\x20be\x20a\x20valid\x20https://...css\x20URL','\x22\x20(','4290NHeHSi','8167938FjJwRN'];a93_0x5edd=function(){return _0x28eee9;};return a93_0x5edd();}(function(_0x5aba88,_0x35615d){const _0x11bac7=a93_0x2952,_0x574ab0=_0x5aba88();while(!![]){try{const _0x145a10=-parseInt(_0x11bac7(0xbb))/0x1*(-parseInt(_0x11bac7(0xf1))/0x2)+parseInt(_0x11bac7(0xc4))/0x3*(parseInt(_0x11bac7(0xd7))/0x4)+parseInt(_0x11bac7(0xdd))/0x5+-parseInt(_0x11bac7(0xc5))/0x6+parseInt(_0x11bac7(0xcd))/0x7+parseInt(_0x11bac7(0xc6))/0x8*(-parseInt(_0x11bac7(0xde))/0x9)+parseInt(_0x11bac7(0xf4))/0xa*(parseInt(_0x11bac7(0xcf))/0xb);if(_0x145a10===_0x35615d)break;else _0x574ab0['push'](_0x574ab0['shift']());}catch(_0x49841e){_0x574ab0['push'](_0x574ab0['shift']());}}}(a93_0x5edd,0xf3d0d));import{updateMenuCdnUrl,getOnlineMenuList}from'../../../commands/menu/shared/service.js';import{isUrlReachable,isValidCssHttpsUrl,isValidJsHttpsUrl}from'../../../commands/menu/shared/valid-url.js';import{logger}from'../../../utils/logger.js';function validateParams(_0x11a612){const _0x5b0da7=a93_0x2952,_0x54105c=[];return _0x11a612['jsUrl']&&!isValidJsHttpsUrl(_0x11a612['jsUrl'])&&_0x54105c[_0x5b0da7(0xc8)]({'field':_0x5b0da7(0xee),'message':_0x5b0da7(0xd5)}),_0x11a612['cssUrl']&&!isValidCssHttpsUrl(_0x11a612[_0x5b0da7(0xf0)])&&_0x54105c[_0x5b0da7(0xc8)]({'field':_0x5b0da7(0xf0),'message':_0x5b0da7(0xc2)}),_0x54105c;}export async function runMenuUpdateCore(_0x153602,_0x5e0bd5,_0xed4187,_0x11b7d7={}){const _0xd7c97e=a93_0x2952,_0x13d0a8=parseUpdateParamsFlag(_0xed4187),_0x22666d=normalizeMode(_0x11b7d7[_0xd7c97e(0xdc)]),_0x3cf5b8=[];if(_0x13d0a8[_0xd7c97e(0xee)])_0x3cf5b8[_0xd7c97e(0xc8)](_0x13d0a8['jsUrl']);if(_0x13d0a8[_0xd7c97e(0xf0)])_0x3cf5b8['push'](_0x13d0a8['cssUrl']);const _0x477513=validateParams(_0x13d0a8);if(_0x477513[_0xd7c97e(0xdb)]>0x0){const _0x435e5f=_0x477513['map'](_0x21ccea=>_0xd7c97e(0xbe)+_0x21ccea[_0xd7c97e(0xd0)]+':\x20'+_0x21ccea['message'])[_0xd7c97e(0xc1)](';\x20');throw new Error(_0xd7c97e(0xd3)+_0x435e5f);}if(_0x3cf5b8[_0xd7c97e(0xdb)]===0x0)throw new Error(_0xd7c97e(0xd1)+_0xd7c97e(0xea));logger[_0xd7c97e(0xe2)](process['cwd']()),logger[_0xd7c97e(0xe5)](_0xd7c97e(0xd2),_0xd7c97e(0xf2),{'appCode':_0x153602,'jsUrl':_0x13d0a8['jsUrl'],'cssUrl':_0x13d0a8[_0xd7c97e(0xf0)],'mode':_0x22666d,'dryRun':_0x11b7d7[_0xd7c97e(0xbf)]===!![]});if(_0x13d0a8[_0xd7c97e(0xee)]){const _0x4eeb80=await isUrlReachable(_0x13d0a8[_0xd7c97e(0xee)]);if(!_0x4eeb80)throw new Error(_0xd7c97e(0xca)+_0x13d0a8[_0xd7c97e(0xee)]);}if(_0x13d0a8[_0xd7c97e(0xf0)]){const _0x10269f=await isUrlReachable(_0x13d0a8[_0xd7c97e(0xf0)]);if(!_0x10269f)throw new Error(_0xd7c97e(0xe0)+_0x13d0a8[_0xd7c97e(0xf0)]);}const _0x46a21d=await getOnlineMenuList(_0x153602,_0x5e0bd5),_0x15185b=_0x46a21d[_0xd7c97e(0xbd)](_0x587490=>_0x587490['resources']['length']>0x0);if(_0x15185b[_0xd7c97e(0xdb)]===0x0)return{'updated':0x0,'failed':0x0,'skipped':!![],'dryRun':_0x11b7d7[_0xd7c97e(0xbf)]===!![]};const _0x500e36=_0x15185b[_0xd7c97e(0xda)](_0xee3b7e=>buildMenuUpdateDiff(_0xee3b7e,_0x13d0a8,_0x22666d,_0x11b7d7[_0xd7c97e(0xe3)]===!![]));if(_0x11b7d7['dryRun'])return{'updated':0x0,'failed':0x0,'skipped':![],'dryRun':!![],'diffs':_0x500e36};const _0x4e6fbc=await Promise[_0xd7c97e(0xdf)](_0x15185b[_0xd7c97e(0xda)]((_0x35df81,_0x1c38f1)=>updateMenuCdnUrl(_0x153602,_0x5e0bd5,{'id':_0x35df81['id'],'label':_0x35df81['label'],'path':_0x35df81[_0xd7c97e(0xe7)],'resources':_0x500e36[_0x1c38f1][_0xd7c97e(0xd4)][_0xd7c97e(0xf3)],'extend':_0x35df81[_0xd7c97e(0xce)]??null}))),_0x71856f=_0x4e6fbc[_0xd7c97e(0xbd)](_0xd0f9c9=>_0xd0f9c9[_0xd7c97e(0xeb)]===_0xd7c97e(0xc0))['map'](_0x2930d8=>_0x2930d8[_0xd7c97e(0xe9)]),_0x13594b=_0x4e6fbc[_0xd7c97e(0xbd)](_0x2f0762=>_0x2f0762[_0xd7c97e(0xeb)]==='rejected')[_0xd7c97e(0xdb)];return logger[_0xd7c97e(0xe5)](_0xd7c97e(0xd2),'Menu\x20update\x20completed',{'count':_0x15185b[_0xd7c97e(0xdb)],'resources':_0x3cf5b8}),{'updated':_0x71856f[_0xd7c97e(0xdb)],'failed':_0x13594b,'skipped':![],'menus':_0x71856f};}function normalizeMode(_0xf6e9d0){const _0x320aec=a93_0x2952;if(!_0xf6e9d0)return'replace';if(_0xf6e9d0==='replace'||_0xf6e9d0===_0x320aec(0xef))return _0xf6e9d0;throw new Error(_0x320aec(0xcc)+_0xf6e9d0+'.\x20Allowed\x20values:\x20replace,\x20patch');}function buildMenuUpdateDiff(_0x59bab4,_0x2b3854,_0x2855fd,_0x5df3f4){const _0x24e5a0=a93_0x2952,_0x491367=[..._0x59bab4[_0x24e5a0(0xf3)]],_0x2ee080=_0x2855fd===_0x24e5a0(0xef)?patchResources(_0x491367,_0x2b3854):replaceResources(_0x2b3854),_0x3056fb=[],_0x5b0aa0=_0x491367[_0x24e5a0(0xe4)](isJsResource),_0x5789cc=_0x2ee080[_0x24e5a0(0xe4)](isJsResource);if(_0x5b0aa0&&!_0x5789cc){const _0x1fcad4='menu\x20update\x20would\x20remove\x20existing\x20JS\x20resource\x20for\x20\x22'+_0x59bab4['label']+_0x24e5a0(0xc3)+_0x59bab4[_0x24e5a0(0xe7)]+_0x24e5a0(0xd8)+_0x24e5a0(0xf5);if(!_0x5df3f4)throw new Error(_0x1fcad4);_0x3056fb[_0x24e5a0(0xc8)](_0x1fcad4);}const _0x2c5808=_0x491367['some'](isCssResource),_0x35d142=_0x2ee080[_0x24e5a0(0xe4)](isCssResource);return _0x2c5808&&!_0x35d142&&_0x3056fb[_0x24e5a0(0xc8)]('menu\x20update\x20will\x20remove\x20existing\x20CSS\x20resource\x20for\x20\x22'+_0x59bab4['label']+_0x24e5a0(0xc3)+_0x59bab4[_0x24e5a0(0xe7)]+').'),{'id':_0x59bab4['id'],'label':_0x59bab4[_0x24e5a0(0xed)],'path':_0x59bab4[_0x24e5a0(0xe7)],'mode':_0x2855fd,'before':{'resources':_0x491367},'after':{'resources':_0x2ee080},'warnings':_0x3056fb};}function replaceResources(_0x440517){const _0x5be23b=a93_0x2952;return[_0x440517[_0x5be23b(0xee)],_0x440517[_0x5be23b(0xf0)]][_0x5be23b(0xbd)](_0x1d06c2=>!!_0x1d06c2);}function a93_0x2952(_0xe2d54,_0x923118){_0xe2d54=_0xe2d54-0xbb;const _0x5edd7a=a93_0x5edd();let _0x2952fd=_0x5edd7a[_0xe2d54];return _0x2952fd;}function patchResources(_0x4c8150,_0x6c4d72){const _0x59505c=a93_0x2952;let _0x5a2b71=![],_0x2f0f8f=![];const _0x16f533=[];for(const _0x537411 of _0x4c8150){if(isJsResource(_0x537411)){if(_0x6c4d72['jsUrl']&&!_0x5a2b71)_0x16f533['push'](_0x6c4d72[_0x59505c(0xee)]),_0x5a2b71=!![];else!_0x6c4d72[_0x59505c(0xee)]&&_0x16f533[_0x59505c(0xc8)](_0x537411);continue;}if(isCssResource(_0x537411)){if(_0x6c4d72['cssUrl']&&!_0x2f0f8f)_0x16f533[_0x59505c(0xc8)](_0x6c4d72[_0x59505c(0xf0)]),_0x2f0f8f=!![];else!_0x6c4d72[_0x59505c(0xf0)]&&_0x16f533[_0x59505c(0xc8)](_0x537411);continue;}_0x16f533[_0x59505c(0xc8)](_0x537411);}return _0x6c4d72[_0x59505c(0xee)]&&!_0x5a2b71&&_0x16f533[_0x59505c(0xec)](_0x6c4d72[_0x59505c(0xee)]),_0x6c4d72[_0x59505c(0xf0)]&&!_0x2f0f8f&&_0x16f533[_0x59505c(0xc8)](_0x6c4d72[_0x59505c(0xf0)]),_0x16f533;}function isJsResource(_0xfc33e5){const _0x4c663b=a93_0x2952;return stripQuery(_0xfc33e5)[_0x4c663b(0xe8)]()['endsWith'](_0x4c663b(0xcb));}function isCssResource(_0x32cf23){const _0x58ff7d=a93_0x2952;return stripQuery(_0x32cf23)['toLowerCase']()[_0x58ff7d(0xc9)]('.css');}function stripQuery(_0x5f5ab4){const _0x1de855=a93_0x2952;return _0x5f5ab4[_0x1de855(0xbc)]('?')[0x0]??_0x5f5ab4;}function parseUpdateParamsFlag(_0x4c4410){const _0x809f7f=a93_0x2952;if(!_0x4c4410||typeof _0x4c4410!=='string')return{};try{const _0xdd6b00=JSON[_0x809f7f(0xe1)](_0x4c4410);if(typeof _0xdd6b00!==_0x809f7f(0xe6)||_0xdd6b00===null||Array[_0x809f7f(0xd9)](_0xdd6b00))return{};return{'jsUrl':typeof _0xdd6b00[_0x809f7f(0xee)]==='string'?_0xdd6b00[_0x809f7f(0xee)][_0x809f7f(0xc7)]():undefined,'cssUrl':typeof _0xdd6b00['cssUrl']===_0x809f7f(0xd6)?_0xdd6b00[_0x809f7f(0xf0)][_0x809f7f(0xc7)]():undefined};}catch{return{};}}
@@ -1 +1 @@
1
- (function(_0x4fbc51,_0x40a5e6){const _0xaa0365=a94_0x33ce,_0x3dfe80=_0x4fbc51();while(!![]){try{const _0x1fc4b3=-parseInt(_0xaa0365(0x17d))/0x1*(-parseInt(_0xaa0365(0x17f))/0x2)+parseInt(_0xaa0365(0x175))/0x3+parseInt(_0xaa0365(0x174))/0x4*(parseInt(_0xaa0365(0x177))/0x5)+parseInt(_0xaa0365(0x178))/0x6*(-parseInt(_0xaa0365(0x17c))/0x7)+parseInt(_0xaa0365(0x17a))/0x8+-parseInt(_0xaa0365(0x179))/0x9*(-parseInt(_0xaa0365(0x17e))/0xa)+-parseInt(_0xaa0365(0x176))/0xb;if(_0x1fc4b3===_0x40a5e6)break;else _0x3dfe80['push'](_0x3dfe80['shift']());}catch(_0x365d3c){_0x3dfe80['push'](_0x3dfe80['shift']());}}}(a94_0x5bea,0x3ed2f));export function isValidJsHttpsUrl(_0x24d2d1){const _0x236d73=a94_0x33ce;return/^https:\/\/.+\.js(\?.*)?$/['test'](_0x24d2d1[_0x236d73(0x17b)]());}export function isValidCssHttpsUrl(_0x10d649){const _0x819102=a94_0x33ce;return/^https:\/\/.+\.css(\?.*)?$/['test'](_0x10d649[_0x819102(0x17b)]());}function a94_0x33ce(_0x4d1abb,_0x42e8db){_0x4d1abb=_0x4d1abb-0x174;const _0x5beac3=a94_0x5bea();let _0x33ce63=_0x5beac3[_0x4d1abb];return _0x33ce63;}export async function isUrlReachable(_0xb690c3){try{const _0x3118a7=await fetch(_0xb690c3,{'method':'HEAD'});return _0x3118a7['ok'];}catch{return![];}}function a94_0x5bea(){const _0x2e1bf3=['10Smjikm','581754IYyFTX','884700LUVBCz','1617472PqBfIc','trim','21dvvGCL','6257oiTAjB','10GpYWRZ','58WrHqlh','10028nOIWbV','1105464vEHgsb','3379585BtIASW'];a94_0x5bea=function(){return _0x2e1bf3;};return a94_0x5bea();}
1
+ function a94_0x4cf8(){const _0x505cd3=['40128htkZcS','test','2227974lnqlrs','9hilsvf','3176jkSaLx','16axjReD','1678605RQkUBG','100KWUnfW','2538650LauwlC','528KwtcMb','trim','3746134JWlkih','173084cVYJDP','14lBwsnK'];a94_0x4cf8=function(){return _0x505cd3;};return a94_0x4cf8();}function a94_0x470c(_0x1fc40b,_0x1139ea){_0x1fc40b=_0x1fc40b-0x12d;const _0x4cf89a=a94_0x4cf8();let _0x470cc7=_0x4cf89a[_0x1fc40b];return _0x470cc7;}(function(_0x57dfcb,_0x744bc9){const _0x5143bc=a94_0x470c,_0x16a227=_0x57dfcb();while(!![]){try{const _0xec569a=parseInt(_0x5143bc(0x139))/0x1*(parseInt(_0x5143bc(0x138))/0x2)+parseInt(_0x5143bc(0x132))/0x3+-parseInt(_0x5143bc(0x130))/0x4*(-parseInt(_0x5143bc(0x133))/0x5)+parseInt(_0x5143bc(0x12e))/0x6+parseInt(_0x5143bc(0x137))/0x7*(-parseInt(_0x5143bc(0x131))/0x8)+parseInt(_0x5143bc(0x12f))/0x9*(-parseInt(_0x5143bc(0x134))/0xa)+-parseInt(_0x5143bc(0x135))/0xb*(parseInt(_0x5143bc(0x13a))/0xc);if(_0xec569a===_0x744bc9)break;else _0x16a227['push'](_0x16a227['shift']());}catch(_0x47b145){_0x16a227['push'](_0x16a227['shift']());}}}(a94_0x4cf8,0xa475f));export function isValidJsHttpsUrl(_0x3144f4){const _0x46de58=a94_0x470c;return/^https:\/\/.+\.js(\?.*)?$/[_0x46de58(0x12d)](_0x3144f4[_0x46de58(0x136)]());}export function isValidCssHttpsUrl(_0x3df162){const _0x39392e=a94_0x470c;return/^https:\/\/.+\.css(\?.*)?$/[_0x39392e(0x12d)](_0x3df162['trim']());}export async function isUrlReachable(_0x1fc0ca){try{const _0x46096d=await fetch(_0x1fc0ca,{'method':'HEAD'});return _0x46096d['ok'];}catch{return![];}}