import{r as t,h as s,g as e,c as i}from"./p-e964d29c.js";import{d as l}from"./p-f499c978.js";import{d as a}from"./p-7b48c7c5.js";import{h as d}from"./p-11286511.js";import"./p-4f46f4bb.js";const r={"Upcoming payments":"Kommande betalningar"},h=class{constructor(s){t(this,s)}componentWillLoad(){this.t=a.create({sv:r},this.element)}render(){return[s("table",null,s("tr",{color:"light"},s("td",null,this.t("Upcoming payments"))),this.dates?this.dates.map((t=>s("tr",null,s("td",null,l.DateTime.localize(l.DateTime.parse(t)).slice(0,10))))):[])]}get element(){return e(this)}};h.style=".sc-ig-future-due-dates-h{display:block}[hidden].sc-ig-future-due-dates-h{display:none}.sc-ig-future-due-dates-h>table.sc-ig-future-due-dates{border:1px solid rgb(var(--smoothly-medium-color));width:100%;height:100%}tr.sc-ig-future-due-dates:first-of-type{border-bottom:1px solid rgb(var(--smoothly-medium-color));font-weight:bold}td.sc-ig-future-due-dates{padding:.3em}";const o={"-2":"third to last","-1":"second to last",0:"last"},n={frequency:"frekvens",offset:"offset",daily:"daglig",weekly:"veckovis",monthly:"månadsvis",quarterly:"kvartalsvis",yearly:"årlig",date:"datum",month:"månad",weekday:"veckodag",monday:"måndag",tuesday:"tisdag",wednesday:"onsdag",thursday:"torsdag",friday:"fredag",saturday:"lördag",sunday:"söndag",january:"januari",february:"februari",march:"mars",may:"maj",june:"juni",july:"juli",august:"augusti",october:"oktober",first:"första",second:"andra",third:"tredje","-2":"tredje sista dagen","-1":"andra sista dagen",0:"sista dagen"},u=class{constructor(s){t(this,s),this.notice=i(this,"notice",7),this.advanced=!1}componentWillLoad(){this.t=a.create({sv:n,en:o},this.element),this.frequency="object"==typeof this.schedule?this.schedule.frequency:this.schedule,this.offset=d.is(this.schedule)&&"daily"!=this.schedule.frequency?this.schedule.offset:void 0,this.divisor=d.is(this.schedule)?this.schedule.divisor:void 0}render(){return[s("section",null,s("label",null,this.t("frequency")),s("smoothly-display",{type:"text",value:this.t(this.frequency)})),"quarterly"!=this.frequency&&"yearly"!=this.frequency||null==this.offset?[]:s("section",null,s("label",null,this.t("month")),s("smoothly-display",{type:"text",value:this.t(Array.isArray(this.offset)?d.months[this.offset[0]]:d.months[this.offset])})),"monthly"!=this.frequency&&("yearly"!=this.frequency&&"quarterly"!=this.frequency||!Array.isArray(this.offset))||null==this.offset?[]:s("section",null,s("label",null,this.t("date")),s("smoothly-display",{type:"text",value:this.t(Array.isArray(this.offset)?(this.offset[1]+1).toString():(this.offset+1).toString())})),"weekly"!=this.frequency||Array.isArray(this.offset)||null==this.offset?[]:s("section",null,s("label",null,this.t("weekday")),s("smoothly-display",{type:"text",value:this.t(d.weekdays[this.offset-1])})),null!=this.divisor?s("section",null,s("label",null,this.t("divisor")),s("smoothly-display",{type:"text",value:Array.isArray(this.divisor)?this.divisor[0].toString()+" / "+this.divisor[1].toString():this.divisor.toString()})):[]]}get element(){return e(this)}};u.style=".sc-ig-schedule-h{width:100%;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-pack:distribute;justify-content:space-around}[hidden].sc-ig-schedule-h{display:none}.sc-ig-schedule-h>section.sc-ig-schedule{width:100%}.sc-ig-schedule-h>section.sc-ig-schedule>label.sc-ig-schedule{font-weight:bold;text-align:left;padding-bottom:.2em;text-transform:capitalize}.sc-ig-schedule-h>section.sc-ig-schedule>smoothly-display.sc-ig-schedule{width:10em;max-width:10em;text-transform:capitalize;-ms-flex-item-align:start;align-self:flex-start}";export{h as ig_future_due_dates,u as ig_schedule}