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B,IAC1D,MAAS,CAAE,KAAM,MAAO,CAAC,CAC3B,EAAGA,EAAmB,UAAW,UAAW,CAAC,KAAG,KAAgB,IAC9D,MAAS,CAAE,KAAM,QAAS,QAAS,EAAG,CAAC,CACzC,EAAGA,EAAmB,UAAW,QAAS,CAAC,EAAGA,KAAqB,KAAgB,IACjF,MAAc,yBAAyB,CACzC,EAAGA,CAAkB,C","sources":["webpack://nuxt-app/./node_modules/@88labs/tsukuri-components-vue/libs/wc-tsukuri-progress-bar-6IBIFUGE.js"],"sourcesContent":["import {\n __decorateClass\n} from \"./chunk-MTCJUXR4.js\";\nimport {\n $enum,\n createParser\n} from \"./chunk-KYGNPTYE.js\";\nimport \"./chunk-JO2RVYIO.js\";\nimport {\n SuppressAnimationController\n} from \"./chunk-BBOFWZ7B.js\";\nimport \"./chunk-444UF7LD.js\";\nimport {\n ValidatePropertiesController,\n validateBoolean,\n validateNumber,\n validateString\n} from \"./chunk-Z77RWYJX.js\";\n\n// ../../components/components/ProgressBar/libs/chunk-HJJRXHHE.js\nimport {\n LitElement,\n html,\n nothing,\n unsafeCSS\n} from \"lit\";\nimport { customElement, property } from \"lit/decorators.js\";\nimport { styleMap } from \"lit/directives/style-map.js\";\nvar progress_bar_default = '@keyframes tsukuri-progress-bar-indeterminate{0%{left:-2.5%}14.29%{left:2.5%;width:5%}28.57%{left:12.5%;width:15%}42.86%{left:42%;width:40%}57.14%{left:58%;width:40%}71.43%{left:87.5%;width:15%}85.71%{left:97.5%;width:5%}to{left:102.5%}}[data-tsukuri-component=progress-bar]{--_progress-percent:0;--_progress-bar-color:var(--color-sys-surface3-object-interactive);--_progress-bar-radius:8px 0 0 8px;--_progress-animation:none;box-sizing:border-box;display:flex;flex-direction:column;gap:8px;max-width:744px;width:100%}[data-tsukuri-component=progress-bar][data-tsukuri-state-progress-bar-has-label=false]{min-width:48px}[data-tsukuri-component=progress-bar][data-tsukuri-state-progress-bar-error=true]{--_progress-bar-color:var(--color-sys-surface3-object-critical)}[data-tsukuri-component=progress-bar][data-tsukuri-state-progress-bar-state=Complete]{--_progress-bar-color:var(--color-sys-surface3-object-success);--_progress-bar-radius:8px}[data-tsukuri-component=progress-bar][data-tsukuri-state-progress-bar-state=Indeterminate]{--_progress-bar-radius:8px;--_progress-animation:0.7s linear 0.1s 1 normal forwards running tsukuri-progress-bar-indeterminate}[data-tsukuri-node-progress-bar=track]{background-color:var(--color-sys-surface3-surface-primary);border-radius:8px;height:8px;overflow:hidden;position:relative;width:100%}[data-tsukuri-node-progress-bar=track]:after{animation:var(--_progress-animation);animation-iteration-count:infinite;background-color:var(--_progress-bar-color);border-radius:var(--_progress-bar-radius);content:\"\";height:8px;left:0;position:absolute;top:0;transform:translateZ(1);transform-box:fill-box;transform-origin:50% 50%;width:var(--_progress-percent)}[data-tsukuri-node-progress-bar=label-wrapper]{align-items:flex-end;display:flex;flex-direction:row;font-family:var(--font-sys-family-yakumono),var(--font-sys-family-en),var(--font-sys-family),sans-serif;font-size:var(--size-sys-text-label-large);gap:24px;justify-content:space-between;line-height:var(--size-sys-line-height-label-large)}[data-tsukuri-node-progress-bar=label]{color:var(--color-sys-text-regular);overflow-wrap:anywhere}[data-tsukuri-node-progress-bar=value]{color:var(--color-sys-text-secondary)}', isValueType = $enum(\"percent\", \"fraction\", \"none\"), toValueType = createParser(isValueType, \"percent\"), isIndeterminateLabel = $enum(\"processing\", \"reading\"), toIndeterminateLabel = createParser(\n isIndeterminateLabel,\n \"processing\"\n), toState = (max, current) => max <= 0 || current < 0 ? \"Indeterminate\" : max <= current ? \"Complete\" : \"Determinate\", isUsingLabel = (labels) => labels.label !== \"\" || labels.actionLabel !== \"\" && labels.targetLabel !== \"\", toLabel = (state, labels, isError) => labels.label !== \"\" ? labels.label : isUsingLabel(labels) ? isError ? `${labels.actionLabel}\\u304C\\u4E2D\\u65AD\\u3055\\u308C\\u307E\\u3057\\u305F` : state === \"Determinate\" ? `${labels.targetLabel}\\u3092${labels.actionLabel}\\u3057\\u3066\\u3044\\u307E\\u3059...` : state === \"Indeterminate\" ? labels.indeterminateLabel === \"processing\" ? \"\\u51E6\\u7406\\u4E2D...\" : \"\\u8AAD\\u307F\\u8FBC\\u307F\\u4E2D...\" : state === \"Complete\" ? `${labels.actionLabel}\\u304C\\u5B8C\\u4E86\\u3057\\u307E\\u3057\\u305F` : \"\" : \"\", toValue = (value, type) => {\n if (type === \"none\" || value.current < 0 || value.max <= 0) return \"\";\n let current = value.current >= value.max ? value.max : value.current;\n return type === \"fraction\" ? `${current}/${value.max}` : type === \"percent\" ? `${Math.ceil(current / value.max * 100)}%` : \"\";\n}, toPercent = (value) => {\n if (value.current < 0 || value.max <= 0) return \"0\";\n let current = value.current >= value.max ? value.max : value.current;\n return `${Math.ceil(current / value.max * 100)}%`;\n}, ProgressBarController = class {\n constructor(host) {\n this.host = host, new SuppressAnimationController(this.host);\n }\n get progressPercent() {\n return toPercent({\n max: this.host.max,\n current: this.host.current\n });\n }\n get barState() {\n return toState(this.host.max, this.host.current);\n }\n get valueText() {\n return toValue(\n {\n max: this.host.max,\n current: this.host.current\n },\n this.host.valueType\n );\n }\n get labelText() {\n return toLabel(this.barState, this.host, this.host.error);\n }\n get hasLabel() {\n return this.valueText.length !== 0 || this.labelText.length !== 0;\n }\n get state() {\n return {\n label: this.labelText,\n value: this.valueText,\n hasLabel: this.hasLabel,\n barState: this.barState,\n percent: this.progressPercent\n };\n }\n}, style_default = \":host([data-tsukuri-components=progress-bar]){display:block}\", TsukuriProgressBar = class extends LitElement {\n constructor() {\n super(), this.description = \"\\u9032\\u6357\\u72B6\\u6CC1\", this.label = \"\", this.valueType = \"percent\", this.targetLabel = \"\", this.actionLabel = \"\", this.indeterminateLabel = \"processing\", this.max = -1, this.current = -1, this.error = !1, new ValidatePropertiesController(this, {\n description: validateString(\"\\u9032\\u6357\\u72B6\\u6CC1\"),\n label: validateString(),\n valueType: toValueType,\n targetLabel: validateString(),\n actionLabel: validateString(),\n indeterminateLabel: toIndeterminateLabel,\n max: validateNumber(-1),\n current: validateNumber(-1),\n error: validateBoolean\n }), this.controller = new ProgressBarController(this);\n }\n render() {\n let { label, value, hasLabel, barState, percent } = this.controller.state, contents = [];\n return hasLabel && contents.push(\n html`
${label}
${value}
`\n ), contents.push(html`
`), html`
${contents}
`;\n }\n};\nTsukuriProgressBar.styles = [\n unsafeCSS(progress_bar_default),\n unsafeCSS(style_default)\n], __decorateClass([\n property({ type: String })\n], TsukuriProgressBar.prototype, \"description\", 2), __decorateClass([\n property({ type: String })\n], TsukuriProgressBar.prototype, \"label\", 2), __decorateClass([\n property({ type: String, converter: toValueType, attribute: \"value-type\" })\n], TsukuriProgressBar.prototype, \"valueType\", 2), __decorateClass([\n property({ type: String, attribute: \"target-label\" })\n], TsukuriProgressBar.prototype, \"targetLabel\", 2), __decorateClass([\n property({ type: String, attribute: \"action-label\" })\n], TsukuriProgressBar.prototype, \"actionLabel\", 2), __decorateClass([\n property({\n type: String,\n attribute: \"indeterminate-label\",\n converter: toIndeterminateLabel\n })\n], TsukuriProgressBar.prototype, \"indeterminateLabel\", 2), __decorateClass([\n property({ type: Number })\n], TsukuriProgressBar.prototype, \"max\", 2), __decorateClass([\n property({ type: Number })\n], TsukuriProgressBar.prototype, \"current\", 2), __decorateClass([\n property({ type: Boolean, reflect: !0 })\n], TsukuriProgressBar.prototype, \"error\", 2), TsukuriProgressBar = __decorateClass([\n customElement(\"wc-tsukuri-progress-bar\")\n], TsukuriProgressBar);\nexport {\n TsukuriProgressBar\n};\n//# sourceMappingURL=wc-tsukuri-progress-bar-6IBIFUGE.js.map"],"names":["progress_bar_default","isValueType","toValueType","isIndeterminateLabel","toIndeterminateLabel","toState","max","current","isUsingLabel","labels","toLabel","state","isError","toValue","value","type","toPercent","ProgressBarController","host","style_default","TsukuriProgressBar","label","hasLabel","barState","percent","contents"],"sourceRoot":""}