PageSourceSearch

https://lifehacker.ru/_nuxt/v7.12-DGvoinqf.js

js lifehacker.ru collected 2026-09-24 08:30:54 UTC 6,237 bytes, 2 lines download raw bytes

1import{b1 as m,aO as O,aP as s,aT as w,bv as B,bB as h,aY as y,b0 as D,ch as P,bE as b,aU as n,aX as e,b4 as T,b5 as N,bF as F,aW as _,bz as d,aQ as r,aV as C,b6 as L,aR as M}from"./v7.12-_pfsIBSO.js";import{v as S}from"./v7.12-BvaIoJo6.js";import{B as R}from"./v7.12-CI99TMth.js";import{T as V}from"./v7.12-TY8S4trn.js";import"./v7.12-Bw-GIxtj.js";const c=(t,o)=>{const i=new Date(Number(t));return i.setDate(t.getDate()+o),i},q=m({name:"BaseButton",props:{text:{type:String,required:!0},tagName:{type:String,default:"button"}}},"$v_e0JleO7C");function H(t,o,i,f,g,k){return s(),O(y(t.tagName),{class:"base-button"},{default:w(()=>[B(h(t.text),1)]),_:1})}const E=D(q,[["render",H],["__scopeId","data-v-a48d0fca"]]),I=m({name:"BaseDropDown",directives:{clickOutside:S},props:{options:{type:Array,required:!0},defaultOption:{type:String,required:!0}},data(){return{showDropDown:!1,currentOption:""}},methods:{clickDropDown(){this.showDropDown=!this.showDropDown},clickOption(t){this.currentOption=t,this.$emit("changeOption",t)},handleClickOutside(){this.showDropDown=!1}}},"$a2XdcUwNRN"),U={class:"dropdown__options"},X=["onClick"];function z(t,o,i,f,g,k){const u=P("click-outside");return b((s(),n("div",{class:_(["dropdown",{"dropdown--active":t.showDropDown}]),onClick:o[0]||(o[0]=(...a)=>t.clickDropDown&&t.clickDropDown(...a))},[e("p",null,h(t.currentOption||t.defaultOption),1),b(e("ul",U,[(s(!0),n(T,null,N(t.options,(a,p)=>(s(),n("li",{key:p,onClick:$=>t.clickOption(a)},h(a),9,X))),128))],512),[[F,t.showDropDown]]),(s(),n("svg",{class:_(["dropdown__image",{"dropdown__image-rotate":t.showDropDown}]),xmlns:"http://www.w3.org/2000/svg",width:"16",height:"10",viewBox:"0 0 16 10",fill:"none"},[...o[1]||(o[1]=[e("path",{d:"M14.0925 1.5456L7.54688 8.0912L1.00127 1.5456",stroke:"#969698","stroke-width":"2","stroke-linecap":"round"},null,-1)])],2))],2)),[[u,t.handleClickOutside]])}const A=D(I,[["render",z],["__scopeId","data-v-5b8d5cad"]]),v=["января","февраля","марта","апреля","мая","июня","июля","августа","сентября","октября","ноября","декабря"],J=m({name:"OvulationCalculator",components:{BaseButton:E,BaseDropDown:A,Transition:V,BaseCalendar:R},data(){return{selectPeriod:"28",options:["21","22","23","24","25","26","27","28","29","30","31","32","33","34","35"],showPopup:!1,showResult:!1,isFirstCount:!0,date:null,ovulationText:"",fertilityText:""}},methods:{changeStatePopup(t=!1){this.showPopup=t},handleClickOutside(){this.showPopup=!1},calcDateOvulaton(){if(this.date){const t=c(this.date,Number(this.selectPeriod)-14);this.ovulationText=t.getDate()+" "+v[t.getMonth()]}},calcDateFertility(){if(this.date){const t=c(this.date,Number(this.selectPeriod)-14-4),o=c(this.date,Number(this.selectPeriod)-14+1);this.fertilityText=`${t.getDate()} ${v[t.getMonth()]} — ${o.getDate()} ${v[o.getMonth()]}`}}}},"$FrqXREdwci"),Q={class:"ovulation-calculator"},W={class:"ovulation-settings"},Y={class:"ovulation-settings__calendar"},j={class:"ovulation-settings__period"},G={class:"ovulation-calculator-popup"},K={key:0,class:"ovulation-calculator-popup__description"},Z={key:0,class:"ovulation-result"},x={class:"ovulation-result-container"},tt=["innerHTML"],ot={class:"ovulation-result-container"},et=["innerHTML"];function st(t,o,i,f,g,k){const u=d("BaseCalendar"),a=d("BaseDropDown"),p=L,$=d("BaseButton");return s(),n("div",Q,[e("div",W,[e("div",Y,[o[4]||(o[4]=e("p",{class:"ovulation-settings__title"},"Дата начала последней менструации",-1)),r(u,{date:t.date,"primary-color":"#b9356f","hover-color":"#a73064","hover-color-popover":"rgba(185, 53, 111, 0.1)",class:"ovulation-settings__calendar-select",onUpdateDate:o[0]||(o[0]=l=>t.date=l)},null,8,["date"])]),e("div",j,[o[5]||(o[5]=e("p",{class:"ovulation-settings__title"},"Продолжительность цикла",-1)),r(p,null,{default:w(()=>[r(a,{"default-option":t.selectPeriod,options:t.options,class:"ovulation-settings__period-select",onChangeOption:o[1]||(o[1]=l=>t.selectPeriod=l)},null,8,["default-option","options"])]),_:1})])]),e("div",G,[e("p",{class:"ovulation-calculator-popup__text",onClick:o[2]||(o[2]=l=>t.changeStatePopup(!t.showPopup))},[o[7]||(o[7]=B(" У меня другая продолжительность ",-1)),(s(),n("svg",{class:_(["ovulation-calculator-popup__image",{"ovulation-calculator-popup__image-rotate":t.showPopup}]),xmlns:"http://www.w3.org/2000/svg",width:"16",height:"10",viewBox:"0 0 16 10",fill:"none"},[...o[6]||(o[6]=[e("path",{d:"M14.0925 1.5456L7.54688 8.0912L1.00127 1.5456",stroke:"#B9356F","stroke-width":"2","stroke-linecap":"round"},null,-1)])],2))]),r(M,{name:"fade"},{default:w(()=>[t.showPopup?(s(),n("div",K,[...o[8]||(o[8]=[e("p",{class:"ovulation-calculator-popup__description-text"}," У большинства женщин цикл составляет 28 дней, но допускаются колебания от 21 до 35 дней. Если ваша средняя продолжительность цикла не укладывается в этот диапазон, мы не сможем рассчитать дату овуляции. Чтобы получить корректную информацию, рекомендуем обратиться к гинекологу. ",-1)])])):C("",!0)]),_:1}
1)]),r($,{class:"ovulation-calculator__btn",text:t.isFirstCount?"Рассчитать":"Рассчитать заново",disabled:!t.date,onClick:o[3]||(o[3]=l=>(t.showResult=!0,t.isFirstCount=!1,t.calcDateOvulaton(),t.calcDateFertility()))},null,8,["text","disabled"]),t.showResult?(s(),n("div",Z,[e("div",x,[o[9]||(o[9]=e("p",{class:"ovulation-result__title"},"Дата овуляции",-1)),e("p",{class:"ovulation-result__text",innerHTML:t.ovulationText},null,8,tt)]),o[11]||(o[11]=e("div",{class:"ovulation-result__separator"},null,-1)),e("div",ot,[o[10]||(o[10]=e("p",{class:"ovulation-result__title"},"Окно фертильности",-1)),e("p",{class:"ovulation-result__text",innerHTML:t.fertilityText},null,8,et)])])):C("",!0)])}const ut=D(J,[["render",st],["__scopeId","data-v-a52c77f7"]]);export{ut as default};
2//# sourceMappingURL=v7.12-DGvoinqf.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.