monobill-mintui 0.6.709 → 0.6.710
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.
- package/dist/components/chunks/{date-picker-D3l2uFzg.js → date-picker-C0U4312C.js} +1 -1
- package/dist/components/chunks/{date-picker-DY0mlT4u.js → date-picker-MT1QYTbL.js} +1 -1
- package/dist/components/chunks/{popover-C1qiTAvR.js → popover-D5-jzS7p.js} +10 -2
- package/dist/components/chunks/{popover-6cborap6.js → popover-DFxM40QK.js} +1 -1
- package/dist/components/chunks/{select-ByoX89vD.js → select-B1T9k1wp.js} +1 -1
- package/dist/components/chunks/{select-Bs4-xwX6.js → select-DYbwUtkq.js} +1 -1
- package/dist/components/chunks/{time-picker-BczVLEX_.js → time-picker-BJY2sFyL.js} +1 -1
- package/dist/components/chunks/{time-picker-CEEByAUI.js → time-picker-DA-kUn8C.js} +1 -1
- package/dist/components/date-picker/browser.js +1 -1
- package/dist/components/date-picker/index.cjs +1 -1
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/datetime-picker/browser.js +2 -2
- package/dist/components/datetime-picker/index.cjs +1 -1
- package/dist/components/datetime-picker/index.js +2 -2
- package/dist/components/navigation/browser.js +1 -1
- package/dist/components/navigation/index.cjs +1 -1
- package/dist/components/navigation/index.js +1 -1
- package/dist/components/page/browser.js +1 -1
- package/dist/components/page/index.cjs +1 -1
- package/dist/components/page/index.js +1 -1
- package/dist/components/popover/Popover.d.ts.map +1 -1
- package/dist/components/popover/browser.js +1 -1
- package/dist/components/popover/index.cjs +1 -1
- package/dist/components/popover/index.js +1 -1
- package/dist/components/resource-table/browser.js +5 -5
- package/dist/components/resource-table/index.cjs +2 -2
- package/dist/components/resource-table/index.js +5 -5
- package/dist/components/select/browser.js +1 -1
- package/dist/components/select/index.cjs +1 -1
- package/dist/components/select/index.js +1 -1
- package/dist/components/side-navigation/browser.js +1 -1
- package/dist/components/side-navigation/index.cjs +1 -1
- package/dist/components/side-navigation/index.js +1 -1
- package/dist/components/tags/browser.js +1 -1
- package/dist/components/tags/index.cjs +1 -1
- package/dist/components/tags/index.js +1 -1
- package/dist/components/time-picker/browser.js +1 -1
- package/dist/components/time-picker/index.cjs +1 -1
- package/dist/components/time-picker/index.js +1 -1
- package/dist/components/tree/browser.js +1 -1
- package/dist/components/tree/index.cjs +1 -1
- package/dist/components/tree/index.js +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.css +1 -1
- package/dist/index.js +13 -5
- package/dist/resource-table.css +1 -1
- package/package.json +1 -1
|
@@ -22,8 +22,8 @@ __mintLoadStyle('datetime-picker', '../../datetime-picker.css')
|
|
|
22
22
|
import "../chunks/icon-hyFz3uhh.js";
|
|
23
23
|
import { t as e } from "../chunks/register-element-BFYmIynH.js";
|
|
24
24
|
import "../chunks/text-C-6UCBp-.js";
|
|
25
|
-
import "../chunks/date-picker-
|
|
26
|
-
import "../chunks/time-picker-
|
|
25
|
+
import "../chunks/date-picker-C0U4312C.js";
|
|
26
|
+
import "../chunks/time-picker-BJY2sFyL.js";
|
|
27
27
|
//#region src/components/datetime-picker/DateTimePicker.ts
|
|
28
28
|
var t = class extends HTMLElement {
|
|
29
29
|
constructor(...e) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
require(`../chunks/icon-CWOP4Com.js`);const e=require(`../chunks/register-element-tCL_F1YI.js`);require(`../chunks/text-CfvRRKGZ.js`),require(`../chunks/date-picker-DY0mlT4u.js`),require(`../chunks/time-picker-CEEByAUI.js`);var t=class extends HTMLElement{constructor(...e){super(...e),this._datePicker=null,this._timePicker=null,this._content=null,this._popoverContent=null,this._popoverObserver=null,this._hiddenInput=null,this._dateValue=``,this._timeValue=``,this._dateStageComplete=!1,this._ready=!1,this._writingValue=!1,this._displayControlBound=!1,this._prependSlotNodes=[],this._appendSlotNodes=[],this._slotObserver=null}static get observedAttributes(){return[`value`,`label`,`info`,`name`,`required`,`disabled`,`readonly`,`format`,`display-format`,`min`,`max`,`shortcuts`,`hours`,`minutes`,`seconds`,`error`,`error-message`]}connectedCallback(){this.classList.add(`mint-datetime-picker`),this._readValue(this.getAttribute(`value`)||``),this.render(),this._ready=!0,this._slotObserver=new MutationObserver(e=>{e.some(e=>e.type===`attributes`&&e.target.hasAttribute(`slot`)||e.type===`childList`&&e.target===this&&Array.from(e.addedNodes).some(e=>e instanceof HTMLElement&&(e.slot===`prepend`||e.slot===`append`)))&&this.render()}),this._slotObserver.observe(this,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`slot`]})}attributeChangedCallback(e,t,n){if(!(t===n||!this._ready||e===`value`&&this._writingValue)){if(e===`value`){this._readValue(n||``),this.render();return}if(e===`error`||e===`error-message`){this._syncState();return}this.render()}}get value(){return this.getAttribute(`value`)||``}set value(e){this.setValue(e||``)}getValue(){return this.getAttribute(`value`)||``}setValue(e){this._readValue(e),this._writingValue=!0,e?this.setAttribute(`value`,e):this.removeAttribute(`value`),this._writingValue=!1,this.render(),this._syncState()}_parseDate(e,t){let n=e.match(/^(\d{4})-(\d{2})-(\d{2})/);if(n)return new Date(Number(n[1]),Number(n[2])-1,Number(n[3]));let r={yyyy:`(\\d{4})`,yy:`(\\d{2})`,Y:`(\\d{4})`,y:`(\\d{2})`,mm:`(\\d{1,2})`,m:`(\\d{1,2})`,n:`(\\d{1,2})`,dd:`(\\d{1,2})`,d:`(\\d{1,2})`,j:`(\\d{1,2})`,M:`([A-Za-z]+)`,F:`([A-Za-z]+)`},i=Object.keys(r).sort((e,t)=>t.length-e.length),a=[],o=`^`;for(let e=0;e<t.length;){let n=i.find(n=>t.startsWith(n,e));n?(o+=r[n],a.push(n),e+=n.length):(o+=t[e].replace(/[.*+?^${}()|[\]\\]/g,`\\$&`),e++)}let s=e.match(RegExp(`${o}$`,`i`));if(!s)return null;let c=2e3,l=1,u=1;a.forEach((e,t)=>{let n=s[t+1];if(e===`Y`||e===`yyyy`)c=Number(n);else if(e===`y`||e===`yy`)c=Number(n)+2e3;else if(e===`m`||e===`mm`||e===`n`)l=Number(n);else if(e===`d`||e===`dd`||e===`j`)u=Number(n);else if(e===`M`||e===`F`){let e=new Date(`${n} 1, 2000`).getMonth();Number.isNaN(e)||(l=e+1)}});let d=new Date(c,l-1,u);return d.getFullYear()===c&&d.getMonth()===l-1&&d.getDate()===u?d:null}_formatDate(e,t){let n=e=>String(e).padStart(2,`0`),r={Y:String(e.getFullYear()),yyyy:String(e.getFullYear()),yy:String(e.getFullYear()).slice(-2),y:String(e.getFullYear()).slice(-2),mm:n(e.getMonth()+1),m:n(e.getMonth()+1),n:String(e.getMonth()+1),dd:n(e.getDate()),d:n(e.getDate()),j:String(e.getDate()),M:e.toLocaleString(void 0,{month:`short`}),F:e.toLocaleString(void 0,{month:`long`})};return t.replace(/yyyy|yy|mm|dd|Y|y|m|n|d|j|M|F/g,e=>r[e])}_readValue(e){let[t=``,n=``]=e.split(/[T ]/),r=this._parseDate(t,this.getAttribute(`format`)||`mm/dd/yyyy`);this._dateValue=r?this._formatDate(r,this.getAttribute(`format`)||`mm/dd/yyyy`):``,this._timeValue=n||``,this._dateStageComplete=!!r}_toISODate(){let e=this._parseDate(this._dateValue,this.getAttribute(`format`)||`mm/dd/yyyy`);return e?`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,`0`)}-${String(e.getDate()).padStart(2,`0`)}`:``}_syncValue(e=!1){let t=this._toISODate(),n=this._timeValue,r=t&&n?`${t}T${n}`:``;this._writingValue=!0,r?this.setAttribute(`value`,r):this.removeAttribute(`value`),this._writingValue=!1,this._hiddenInput&&(this._hiddenInput.value=r),e&&r&&(this.dispatchEvent(new Event(`input`,{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent(`change`,{detail:{value:r},bubbles:!0,composed:!0})))}_syncState(){this._datePicker&&(this._datePicker.setAttribute(`value`,this._dateValue),this._datePicker.setAttribute(`error`,this.getAttribute(`error`)||`false`),this._datePicker.setAttribute(`error-message`,this.getAttribute(`error-message`)||``),this._timePicker?.setAttribute(`error`,this.getAttribute(`error`)||`false`),this._timePicker?.setAttribute(`error-message`,this.getAttribute(`error-message`)||``),this._hiddenInput&&(this._hiddenInput.value=this.getValue()),this._syncCombinedDisplay())}render(){let e=this.getAttribute(`label`)||``,t=this.getAttribute(`info`)||``,n=this.getAttribute(`format`)||`mm/dd/yyyy`,r=this.getAttribute(`disabled`)===`true`,i=this.getAttribute(`readonly`)===`true`;this._collectAdornmentNodes(),this._displayControlBound=!1;let a=document.createElement(`mint-date-picker`);a.setAttribute(`class`,`mint-datetime-picker-date`),a.setAttribute(`keep-open-on-select`,`true`),a.setAttribute(`format`,n),a.setAttribute(`value`,this._dateValue),a.setAttribute(`label`,e),a.setAttribute(`info`,t),a.setAttribute(`display-format`,this.getAttribute(`display-format`)||`F j, Y`);for(let e of[`min`,`max`,`shortcuts`])this.hasAttribute(e)&&a.setAttribute(e,this.getAttribute(e)||``);r&&a.setAttribute(`disabled`,`true`),i&&a.setAttribute(`readonly`,`true`),this.hasAttribute(`required`)&&a.setAttribute(`required`,this.getAttribute(`required`)||`true`),this.hasAttribute(`error`)&&a.setAttribute(`error`,this.getAttribute(`error`)||`false`),this.hasAttribute(`error-message`)&&a.setAttribute(`error-message`,this.getAttribute(`error-message`)||``),this._prependSlotNodes.forEach(e=>a.appendChild(e)),this._appendSlotNodes.forEach(e=>a.appendChild(e)),a.addEventListener(`change`,e=>{e.stopPropagation();let t=e.detail?.value||a.value||``;this._parseDate(t,n)&&(this._dateValue=t,this._dateStageComplete=!0,this._syncValue(!1),this._syncCombinedDisplay(),this._openTimeStage())}),this._datePicker=a,this._bindCombinedDisplayControl();let o=document.createElement(`div`);o.className=`mint-datetime-picker-content`,this._content=o,this.innerHTML=``,this.appendChild(o),o.appendChild(a),this._hiddenInput=document.createElement(`input`),this._hiddenInput.type=`hidden`,this._hiddenInput.name=this.getAttribute(`name`)||``,this._hiddenInput.value=this.getValue(),this.appendChild(this._hiddenInput),this._waitForPopover()}_collectAdornmentNodes(){let e=[...this._prependSlotNodes,...this._appendSlotNodes,...Array.from(this.querySelectorAll(`[slot="prepend"], [slot="append"]`))];this._prependSlotNodes=e.filter(e=>e.getAttribute(`slot`)===`prepend`),this._appendSlotNodes=e.filter(e=>e.getAttribute(`slot`)===`append`)}_getPopover(){let e=this._datePicker,t=e?.getPopoverElement?.()||e?._popover;if(t)return t;let n=e?.querySelector?.(`.mint-date-picker-icon-button`)?.id;return n?document.querySelector(`mint-popover[trigger-id="${CSS.escape(n)}"]`):null}_getPopoverContent(e){return e.querySelector(`.popover-content`)||e}_waitForPopover(e=0){let t=this._getPopover();if(!t){e<120&&requestAnimationFrame(()=>this._waitForPopover(e+1));return}if(this._popoverContent=this._datePicker?.getPopoverContentElement?.()||this._getPopoverContent(t),this._bindCombinedDisplayControl(),this._syncCombinedDisplay(),this._popoverObserver?.disconnect(),this._popoverObserver=new MutationObserver(()=>{if(t.getAttribute(`open`)===`true`){let e=this._datePicker;typeof e?.refreshCalendar==`function`?e.refreshCalendar():e?._buildCalendar?.()}}),this._popoverObserver.observe(t,{attributes:!0,attributeFilter:[`open`]}),t.getAttribute(`open`)===`true`){let e=this._datePicker;typeof e?.refreshCalendar==`function`?e.refreshCalendar():e?._buildCalendar?.()}}_bindCombinedDisplayControl(){if(this._displayControlBound||!this._datePicker)return;this._displayControlBound=!0;let e=e=>{if(!e.target?.closest(`.mint-date-picker-field`)||this.getAttribute(`disabled`)===`true`||this.getAttribute(`readonly`)===`true`||e instanceof KeyboardEvent&&e.key!==`Enter`&&e.key!==` `)return;e.preventDefault(),e.stopImmediatePropagation();let t=this._getPopover();t?.open?t.open():t?.setAttribute(`open`,`true`)};this._datePicker.addEventListener(`click`,e,!0),this._datePicker.addEventListener(`keydown`,e,!0)}_openTimeStage(){queueMicrotask(()=>{let e=this._getPopover();if(e?.getAttribute(`open`)!==`true`){typeof e?.open==`function`?e.open():e?.setAttribute(`open`,`true`),requestAnimationFrame(()=>this._renderTimeStage());return}this._renderTimeStage()})}_renderTimeStage(){if(!this._popoverContent||!this._dateStageComplete)return;let e=document.createElement(`div`);e.className=`mint-datetime-picker-panel`;let t=document.createElement(`button`);t.type=`button`,t.className=`mint-datetime-picker-time-heading`,t.setAttribute(`aria-label`,`Change date, ${this._dateValue}`),t.textContent=this._getFormattedDate(),t.addEventListener(`click`,()=>{let e=this._datePicker;typeof e?.refreshCalendar==`function`?e.refreshCalendar():e?._buildCalendar?.()});let n=document.createElement(`mint-time-picker`),r=this.getAttribute(`disabled`)===`true`,i=this.getAttribute(`readonly`)===`true`;n.setAttribute(`inline`,`true`),n.setAttribute(`value`,this._timeValue||`09:00`),n.setAttribute(`label`,``);for(let e of[`hours`,`minutes`,`seconds`])this.hasAttribute(e)&&n.setAttribute(e,this.getAttribute(e)||``);r&&n.setAttribute(`disabled`,`true`),i&&n.setAttribute(`readonly`,`true`),n.addEventListener(`change`,()=>{this._timeValue=n.getValue?.()||n.getAttribute(`value`)||``,this._syncValue(!0),this._syncCombinedDisplay()}),n.addEventListener(`change`,e=>e.stopPropagation()),n.addEventListener(`input`,e=>e.stopPropagation()),this._timePicker=n,e.appendChild(t),e.appendChild(n),this._popoverContent.replaceChildren(e)}_syncCombinedDisplay(){let e=this._datePicker?.getDisplayElement?.()||this._datePicker?.querySelector(`.mint-date-picker-display`);if(!e||!this._dateValue)return;let t=this._getFormattedDate();e.textContent=this._timeValue?`${t} · ${this._formatTime(this._timeValue)}`:t,e.setAttribute(`aria-label`,`${this.getAttribute(`label`)||`Date and time`}: ${e.textContent}`)}_getFormattedDate(){let e=this._parseDate(this._dateValue,this.getAttribute(`format`)||`mm/dd/yyyy`);return e?this._formatDate(e,this.getAttribute(`display-format`)||`F j, Y`):this._dateValue}_formatTime(e){let[t=`00`,n=`00`,r]=e.split(`:`),i=Number(t),a=this.getAttribute(`hours`)!==`false`,o=this.getAttribute(`minutes`)!==`false`,s=this.getAttribute(`seconds`)===`true`;if(!a)return[o?n:``,s?r||`00`:``].filter(Boolean).join(`:`);let c=i%12||12;return`${[String(c),o?n:``,s?r||`00`:``].filter(Boolean).join(`:`)} ${i>=12?`pm`:`am`}`}};customElements.get(`mint-datetime-picker`)||e.t(`mint-datetime-picker`,t),module.exports=t;
|
|
1
|
+
require(`../chunks/icon-CWOP4Com.js`);const e=require(`../chunks/register-element-tCL_F1YI.js`);require(`../chunks/text-CfvRRKGZ.js`),require(`../chunks/date-picker-MT1QYTbL.js`),require(`../chunks/time-picker-DA-kUn8C.js`);var t=class extends HTMLElement{constructor(...e){super(...e),this._datePicker=null,this._timePicker=null,this._content=null,this._popoverContent=null,this._popoverObserver=null,this._hiddenInput=null,this._dateValue=``,this._timeValue=``,this._dateStageComplete=!1,this._ready=!1,this._writingValue=!1,this._displayControlBound=!1,this._prependSlotNodes=[],this._appendSlotNodes=[],this._slotObserver=null}static get observedAttributes(){return[`value`,`label`,`info`,`name`,`required`,`disabled`,`readonly`,`format`,`display-format`,`min`,`max`,`shortcuts`,`hours`,`minutes`,`seconds`,`error`,`error-message`]}connectedCallback(){this.classList.add(`mint-datetime-picker`),this._readValue(this.getAttribute(`value`)||``),this.render(),this._ready=!0,this._slotObserver=new MutationObserver(e=>{e.some(e=>e.type===`attributes`&&e.target.hasAttribute(`slot`)||e.type===`childList`&&e.target===this&&Array.from(e.addedNodes).some(e=>e instanceof HTMLElement&&(e.slot===`prepend`||e.slot===`append`)))&&this.render()}),this._slotObserver.observe(this,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[`slot`]})}attributeChangedCallback(e,t,n){if(!(t===n||!this._ready||e===`value`&&this._writingValue)){if(e===`value`){this._readValue(n||``),this.render();return}if(e===`error`||e===`error-message`){this._syncState();return}this.render()}}get value(){return this.getAttribute(`value`)||``}set value(e){this.setValue(e||``)}getValue(){return this.getAttribute(`value`)||``}setValue(e){this._readValue(e),this._writingValue=!0,e?this.setAttribute(`value`,e):this.removeAttribute(`value`),this._writingValue=!1,this.render(),this._syncState()}_parseDate(e,t){let n=e.match(/^(\d{4})-(\d{2})-(\d{2})/);if(n)return new Date(Number(n[1]),Number(n[2])-1,Number(n[3]));let r={yyyy:`(\\d{4})`,yy:`(\\d{2})`,Y:`(\\d{4})`,y:`(\\d{2})`,mm:`(\\d{1,2})`,m:`(\\d{1,2})`,n:`(\\d{1,2})`,dd:`(\\d{1,2})`,d:`(\\d{1,2})`,j:`(\\d{1,2})`,M:`([A-Za-z]+)`,F:`([A-Za-z]+)`},i=Object.keys(r).sort((e,t)=>t.length-e.length),a=[],o=`^`;for(let e=0;e<t.length;){let n=i.find(n=>t.startsWith(n,e));n?(o+=r[n],a.push(n),e+=n.length):(o+=t[e].replace(/[.*+?^${}()|[\]\\]/g,`\\$&`),e++)}let s=e.match(RegExp(`${o}$`,`i`));if(!s)return null;let c=2e3,l=1,u=1;a.forEach((e,t)=>{let n=s[t+1];if(e===`Y`||e===`yyyy`)c=Number(n);else if(e===`y`||e===`yy`)c=Number(n)+2e3;else if(e===`m`||e===`mm`||e===`n`)l=Number(n);else if(e===`d`||e===`dd`||e===`j`)u=Number(n);else if(e===`M`||e===`F`){let e=new Date(`${n} 1, 2000`).getMonth();Number.isNaN(e)||(l=e+1)}});let d=new Date(c,l-1,u);return d.getFullYear()===c&&d.getMonth()===l-1&&d.getDate()===u?d:null}_formatDate(e,t){let n=e=>String(e).padStart(2,`0`),r={Y:String(e.getFullYear()),yyyy:String(e.getFullYear()),yy:String(e.getFullYear()).slice(-2),y:String(e.getFullYear()).slice(-2),mm:n(e.getMonth()+1),m:n(e.getMonth()+1),n:String(e.getMonth()+1),dd:n(e.getDate()),d:n(e.getDate()),j:String(e.getDate()),M:e.toLocaleString(void 0,{month:`short`}),F:e.toLocaleString(void 0,{month:`long`})};return t.replace(/yyyy|yy|mm|dd|Y|y|m|n|d|j|M|F/g,e=>r[e])}_readValue(e){let[t=``,n=``]=e.split(/[T ]/),r=this._parseDate(t,this.getAttribute(`format`)||`mm/dd/yyyy`);this._dateValue=r?this._formatDate(r,this.getAttribute(`format`)||`mm/dd/yyyy`):``,this._timeValue=n||``,this._dateStageComplete=!!r}_toISODate(){let e=this._parseDate(this._dateValue,this.getAttribute(`format`)||`mm/dd/yyyy`);return e?`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,`0`)}-${String(e.getDate()).padStart(2,`0`)}`:``}_syncValue(e=!1){let t=this._toISODate(),n=this._timeValue,r=t&&n?`${t}T${n}`:``;this._writingValue=!0,r?this.setAttribute(`value`,r):this.removeAttribute(`value`),this._writingValue=!1,this._hiddenInput&&(this._hiddenInput.value=r),e&&r&&(this.dispatchEvent(new Event(`input`,{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent(`change`,{detail:{value:r},bubbles:!0,composed:!0})))}_syncState(){this._datePicker&&(this._datePicker.setAttribute(`value`,this._dateValue),this._datePicker.setAttribute(`error`,this.getAttribute(`error`)||`false`),this._datePicker.setAttribute(`error-message`,this.getAttribute(`error-message`)||``),this._timePicker?.setAttribute(`error`,this.getAttribute(`error`)||`false`),this._timePicker?.setAttribute(`error-message`,this.getAttribute(`error-message`)||``),this._hiddenInput&&(this._hiddenInput.value=this.getValue()),this._syncCombinedDisplay())}render(){let e=this.getAttribute(`label`)||``,t=this.getAttribute(`info`)||``,n=this.getAttribute(`format`)||`mm/dd/yyyy`,r=this.getAttribute(`disabled`)===`true`,i=this.getAttribute(`readonly`)===`true`;this._collectAdornmentNodes(),this._displayControlBound=!1;let a=document.createElement(`mint-date-picker`);a.setAttribute(`class`,`mint-datetime-picker-date`),a.setAttribute(`keep-open-on-select`,`true`),a.setAttribute(`format`,n),a.setAttribute(`value`,this._dateValue),a.setAttribute(`label`,e),a.setAttribute(`info`,t),a.setAttribute(`display-format`,this.getAttribute(`display-format`)||`F j, Y`);for(let e of[`min`,`max`,`shortcuts`])this.hasAttribute(e)&&a.setAttribute(e,this.getAttribute(e)||``);r&&a.setAttribute(`disabled`,`true`),i&&a.setAttribute(`readonly`,`true`),this.hasAttribute(`required`)&&a.setAttribute(`required`,this.getAttribute(`required`)||`true`),this.hasAttribute(`error`)&&a.setAttribute(`error`,this.getAttribute(`error`)||`false`),this.hasAttribute(`error-message`)&&a.setAttribute(`error-message`,this.getAttribute(`error-message`)||``),this._prependSlotNodes.forEach(e=>a.appendChild(e)),this._appendSlotNodes.forEach(e=>a.appendChild(e)),a.addEventListener(`change`,e=>{e.stopPropagation();let t=e.detail?.value||a.value||``;this._parseDate(t,n)&&(this._dateValue=t,this._dateStageComplete=!0,this._syncValue(!1),this._syncCombinedDisplay(),this._openTimeStage())}),this._datePicker=a,this._bindCombinedDisplayControl();let o=document.createElement(`div`);o.className=`mint-datetime-picker-content`,this._content=o,this.innerHTML=``,this.appendChild(o),o.appendChild(a),this._hiddenInput=document.createElement(`input`),this._hiddenInput.type=`hidden`,this._hiddenInput.name=this.getAttribute(`name`)||``,this._hiddenInput.value=this.getValue(),this.appendChild(this._hiddenInput),this._waitForPopover()}_collectAdornmentNodes(){let e=[...this._prependSlotNodes,...this._appendSlotNodes,...Array.from(this.querySelectorAll(`[slot="prepend"], [slot="append"]`))];this._prependSlotNodes=e.filter(e=>e.getAttribute(`slot`)===`prepend`),this._appendSlotNodes=e.filter(e=>e.getAttribute(`slot`)===`append`)}_getPopover(){let e=this._datePicker,t=e?.getPopoverElement?.()||e?._popover;if(t)return t;let n=e?.querySelector?.(`.mint-date-picker-icon-button`)?.id;return n?document.querySelector(`mint-popover[trigger-id="${CSS.escape(n)}"]`):null}_getPopoverContent(e){return e.querySelector(`.popover-content`)||e}_waitForPopover(e=0){let t=this._getPopover();if(!t){e<120&&requestAnimationFrame(()=>this._waitForPopover(e+1));return}if(this._popoverContent=this._datePicker?.getPopoverContentElement?.()||this._getPopoverContent(t),this._bindCombinedDisplayControl(),this._syncCombinedDisplay(),this._popoverObserver?.disconnect(),this._popoverObserver=new MutationObserver(()=>{if(t.getAttribute(`open`)===`true`){let e=this._datePicker;typeof e?.refreshCalendar==`function`?e.refreshCalendar():e?._buildCalendar?.()}}),this._popoverObserver.observe(t,{attributes:!0,attributeFilter:[`open`]}),t.getAttribute(`open`)===`true`){let e=this._datePicker;typeof e?.refreshCalendar==`function`?e.refreshCalendar():e?._buildCalendar?.()}}_bindCombinedDisplayControl(){if(this._displayControlBound||!this._datePicker)return;this._displayControlBound=!0;let e=e=>{if(!e.target?.closest(`.mint-date-picker-field`)||this.getAttribute(`disabled`)===`true`||this.getAttribute(`readonly`)===`true`||e instanceof KeyboardEvent&&e.key!==`Enter`&&e.key!==` `)return;e.preventDefault(),e.stopImmediatePropagation();let t=this._getPopover();t?.open?t.open():t?.setAttribute(`open`,`true`)};this._datePicker.addEventListener(`click`,e,!0),this._datePicker.addEventListener(`keydown`,e,!0)}_openTimeStage(){queueMicrotask(()=>{let e=this._getPopover();if(e?.getAttribute(`open`)!==`true`){typeof e?.open==`function`?e.open():e?.setAttribute(`open`,`true`),requestAnimationFrame(()=>this._renderTimeStage());return}this._renderTimeStage()})}_renderTimeStage(){if(!this._popoverContent||!this._dateStageComplete)return;let e=document.createElement(`div`);e.className=`mint-datetime-picker-panel`;let t=document.createElement(`button`);t.type=`button`,t.className=`mint-datetime-picker-time-heading`,t.setAttribute(`aria-label`,`Change date, ${this._dateValue}`),t.textContent=this._getFormattedDate(),t.addEventListener(`click`,()=>{let e=this._datePicker;typeof e?.refreshCalendar==`function`?e.refreshCalendar():e?._buildCalendar?.()});let n=document.createElement(`mint-time-picker`),r=this.getAttribute(`disabled`)===`true`,i=this.getAttribute(`readonly`)===`true`;n.setAttribute(`inline`,`true`),n.setAttribute(`value`,this._timeValue||`09:00`),n.setAttribute(`label`,``);for(let e of[`hours`,`minutes`,`seconds`])this.hasAttribute(e)&&n.setAttribute(e,this.getAttribute(e)||``);r&&n.setAttribute(`disabled`,`true`),i&&n.setAttribute(`readonly`,`true`),n.addEventListener(`change`,()=>{this._timeValue=n.getValue?.()||n.getAttribute(`value`)||``,this._syncValue(!0),this._syncCombinedDisplay()}),n.addEventListener(`change`,e=>e.stopPropagation()),n.addEventListener(`input`,e=>e.stopPropagation()),this._timePicker=n,e.appendChild(t),e.appendChild(n),this._popoverContent.replaceChildren(e)}_syncCombinedDisplay(){let e=this._datePicker?.getDisplayElement?.()||this._datePicker?.querySelector(`.mint-date-picker-display`);if(!e||!this._dateValue)return;let t=this._getFormattedDate();e.textContent=this._timeValue?`${t} · ${this._formatTime(this._timeValue)}`:t,e.setAttribute(`aria-label`,`${this.getAttribute(`label`)||`Date and time`}: ${e.textContent}`)}_getFormattedDate(){let e=this._parseDate(this._dateValue,this.getAttribute(`format`)||`mm/dd/yyyy`);return e?this._formatDate(e,this.getAttribute(`display-format`)||`F j, Y`):this._dateValue}_formatTime(e){let[t=`00`,n=`00`,r]=e.split(`:`),i=Number(t),a=this.getAttribute(`hours`)!==`false`,o=this.getAttribute(`minutes`)!==`false`,s=this.getAttribute(`seconds`)===`true`;if(!a)return[o?n:``,s?r||`00`:``].filter(Boolean).join(`:`);let c=i%12||12;return`${[String(c),o?n:``,s?r||`00`:``].filter(Boolean).join(`:`)} ${i>=12?`pm`:`am`}`}};customElements.get(`mint-datetime-picker`)||e.t(`mint-datetime-picker`,t),module.exports=t;
|
|
@@ -10,8 +10,8 @@ import '../../datetime-picker.css'
|
|
|
10
10
|
import "../chunks/icon-hyFz3uhh.js";
|
|
11
11
|
import { t as e } from "../chunks/register-element-BFYmIynH.js";
|
|
12
12
|
import "../chunks/text-C-6UCBp-.js";
|
|
13
|
-
import "../chunks/date-picker-
|
|
14
|
-
import "../chunks/time-picker-
|
|
13
|
+
import "../chunks/date-picker-C0U4312C.js";
|
|
14
|
+
import "../chunks/time-picker-BJY2sFyL.js";
|
|
15
15
|
//#region src/components/datetime-picker/DateTimePicker.ts
|
|
16
16
|
var t = class extends HTMLElement {
|
|
17
17
|
constructor(...e) {
|
|
@@ -21,7 +21,7 @@ __mintLoadStyle('navigation', '../../navigation.css')
|
|
|
21
21
|
import "../chunks/icon-hyFz3uhh.js";
|
|
22
22
|
import { t as e } from "../chunks/register-element-BFYmIynH.js";
|
|
23
23
|
import "../chunks/button-JPTyQfRs.js";
|
|
24
|
-
import "../chunks/popover-
|
|
24
|
+
import "../chunks/popover-D5-jzS7p.js";
|
|
25
25
|
import "../chunks/link-ACOyvLkd.js";
|
|
26
26
|
//#region src/components/navigation/Navigation.js
|
|
27
27
|
var t = 0, n = class extends HTMLElement {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
require(`../chunks/icon-CWOP4Com.js`);const e=require(`../chunks/register-element-tCL_F1YI.js`);require(`../chunks/button-B_yN18B-.js`),require(`../chunks/popover-
|
|
1
|
+
require(`../chunks/icon-CWOP4Com.js`);const e=require(`../chunks/register-element-tCL_F1YI.js`);require(`../chunks/button-B_yN18B-.js`),require(`../chunks/popover-DFxM40QK.js`),require(`../chunks/link-DVKhDl3O.js`);var t=0,n=class extends HTMLElement{static get observedAttributes(){return[`brand`,`brand-href`,`direction`,`label`,`open`,`fixed`]}constructor(){super(),this._built=!1,this._brand=null,this._brandLink=null,this._leadingActions=null,this._items=null,this._toggle=null,this._toggleLabel=null,this._mobileActions=null,this._mobileActionNodes=[],this._instanceId=++t,this._dropdowns=[],this._content=null,this._actions=null,this._activeDropdown=null,this._layoutObserver=null}connectedCallback(){this._built||this._build(),this._observeDropdowns(),this._syncResponsiveDropdowns(),this._syncMobileActions(),typeof ResizeObserver<`u`&&(this._layoutObserver=new ResizeObserver(()=>{this._syncResponsiveDropdowns(),this._syncMobileActions()}),this._layoutObserver.observe(this)),this._syncAttributes()}disconnectedCallback(){for(let e of this._dropdowns)e.observer?.disconnect();this._layoutObserver?.disconnect(),this._layoutObserver=null}attributeChangedCallback(e,t,n){t===n||!this._built||(e===`open`?this._syncOpenState():this._syncAttributes())}getDirection(){return this.getAttribute(`direction`)===`vertical`?`vertical`:`horizontal`}getBrand(){return this.getAttribute(`brand`)||``}getBrandHref(){return this.getAttribute(`brand-href`)||`/`}getLabel(){return this.getAttribute(`label`)||`Primary navigation`}_build(){let e=Array.from(this.childNodes),t=e.find(e=>e.nodeType===Node.ELEMENT_NODE&&e.getAttribute(`slot`)===`brand`),n=e.filter(e=>e.nodeType===Node.ELEMENT_NODE&&e.getAttribute(`slot`)===`leading-actions`),r=e.filter(e=>e.nodeType===Node.ELEMENT_NODE&&[`actions`,`mobile-actions`].includes(e.getAttribute(`slot`)));this._mobileActionNodes=r.filter(e=>e.getAttribute(`slot`)===`mobile-actions`);let i=e.filter(e=>e!==t&&!n.includes(e)&&!r.includes(e));this.replaceChildren();let a=document.createElement(`div`);a.className=`mint-navigation-shell`;let o=document.createElement(`div`);o.className=`mint-navigation-bar`,this._leadingActions=document.createElement(`div`),this._leadingActions.className=`mint-navigation-leading-actions`;for(let e of n)e.removeAttribute(`slot`),this._leadingActions.appendChild(e);this._brand=document.createElement(`div`),this._brand.className=`mint-navigation-brand`,t?(t.removeAttribute(`slot`),this._brand.appendChild(t)):this.getBrand()&&(this._brandLink=document.createElement(`mint-link`),this._brandLink.className=`mint-navigation-brand-link`,this._brandLink.textContent=this.getBrand(),this._brandLink.setAttribute(`href`,this.getBrandHref()),this._brand.appendChild(this._brandLink)),this._toggle=document.createElement(`mint-button`),this._toggle.className=`mint-navigation-toggle`,this._toggle.setAttribute(`aria-expanded`,`false`),this._toggle.addEventListener(`click`,()=>this.toggleMenu()),this._toggleLabel=document.createElement(`span`),this._toggleLabel.className=`mint-navigation-visually-hidden`,this._toggleLabel.textContent=`Open navigation menu`,this._toggle.append(this._toggleLabel),this._toggle.setAttribute(`variant`,`ghost`),this._toggle.setAttribute(`tone`,`action`),this._toggle.setAttribute(`button-type`,`button`),this._toggle.setAttribute(`icon`,`menu`),this._mobileActions=document.createElement(`div`),this._mobileActions.className=`mint-navigation-mobile-actions`,o.append(this._leadingActions,this._brand,this._mobileActions,this._toggle);let s=document.createElement(`div`);this._content=s,s.className=`mint-navigation-content`,this._items=document.createElement(`nav`),this._items.className=`mint-navigation-items`,this._items.setAttribute(`aria-label`,this.getLabel()),this._items.addEventListener(`click`,e=>{e.target.closest(`a, mint-link`)&&this.closeMenu()});let c=0;for(let e of i)if(e.nodeType!==Node.ELEMENT_NODE)this._items.appendChild(e);else if(e.tagName===`DETAILS`){let t=this._createDropdown(e,c++);this._items.append(t.trigger,t.popover),this._registerDropdown(t.trigger,t.popover)}else{let t=this._toMintLink(e);if(this._items.appendChild(t),t.nodeType===Node.ELEMENT_NODE&&t.tagName===`MINT-POPOVER`){let e=t.getAttribute(`trigger-id`),n=Array.from(this._items.querySelectorAll(`mint-button`)).find(t=>t.id===e);this._registerDropdown(n,t)}}let l=document.createElement(`div`);this._actions=l,l.className=`mint-navigation-actions`;for(let e of r)e.removeAttribute(`slot`),l.appendChild(e);let u=document.createElement(`section`);u.className=`mint-navigation-submenu`,u.setAttribute(`aria-label`,`Navigation submenu`);let d=document.createElement(`div`);d.className=`mint-navigation-submenu-header`;let f=document.createElement(`mint-button`);f.className=`mint-navigation-submenu-back`,f.setAttribute(`variant`,`ghost`),f.setAttribute(`tone`,`action`),f.setAttribute(`button-type`,`button`),f.setAttribute(`icon`,`arrow-left`),f.setAttribute(`aria-label`,`Back to main navigation`),f.addEventListener(`click`,()=>this._closeSubmenu());let p=document.createElement(`h3`);p.className=`mint-navigation-submenu-title`,d.append(f,p);let m=document.createElement(`nav`);m.className=`mint-navigation-submenu-items`,m.addEventListener(`click`,e=>{e.target.closest(`a, mint-link`)&&this.closeMenu()}),u.append(d,m),this._submenu=u,this._submenuTitle=p,this._submenuItems=m;for(let e of this._dropdowns)m.append(...e.submenuItems);s.append(this._items,l,u),a.append(o,s),this.appendChild(a),this._built=!0,this._syncMobileActions()}_syncMobileActions(){if(!this._mobileActions||!this._actions)return;let e=this._isMobileLayout()?this._mobileActions:this._actions;for(let t of this._mobileActionNodes)e.appendChild(t)}_toMintLink(e){if(e.nodeType!==Node.ELEMENT_NODE||e.tagName!==`A`)return e;let t=document.createElement(`mint-link`);for(;e.firstChild;)t.appendChild(e.firstChild);for(let n of Array.from(e.attributes))n.name!==`slot`&&t.setAttribute(n.name,n.value);return t}_createDropdown(e,t){let n=e.querySelector(`:scope > summary`),r=document.createElement(`mint-button`),i=`mint-navigation-${this._instanceId}-dropdown-${t}`,a=`${i}-popover`;if(r.id=i,r.className=`mint-navigation-dropdown-trigger`,r.setAttribute(`aria-haspopup`,`dialog`),r.setAttribute(`aria-expanded`,`false`),r.setAttribute(`aria-controls`,a),n){for(;n.firstChild;)r.appendChild(n.firstChild);n.remove()}else r.textContent=e.getAttribute(`label`)||`More`;r.setAttribute(`variant`,`ghost`),r.setAttribute(`tone`,`action`),r.setAttribute(`button-type`,`button`),r.setAttribute(`icon-position`,`right`);let o=document.createElement(`mint-popover`);o.id=a,o.className=`mint-navigation-dropdown`,o.setAttribute(`trigger-id`,i),o.setAttribute(`direction`,`down`),o.setAttribute(`aria-label`,`${r.textContent.trim()} links`);for(let t of Array.from(e.childNodes))o.appendChild(this._toMintLink(t));return{trigger:r,popover:o,observer:null}}_registerDropdown(e,t){if(!e||!t)return;t.id||=`mint-navigation-${this._instanceId}-popover-${this._dropdowns.length}`,e.classList.add(`mint-navigation-dropdown-trigger`),e.setAttribute(`aria-haspopup`,`dialog`),e.setAttribute(`aria-expanded`,String(t.hasAttribute(`open`))),e.setAttribute(`aria-controls`,t.id),t.classList.add(`mint-navigation-dropdown`),t.hasAttribute(`role`)||t.setAttribute(`role`,`group`),t.hasAttribute(`aria-label`)||t.setAttribute(`aria-label`,`${e.textContent.trim()} links`);let n=Array.from(t.querySelectorAll(`mint-link`)).map(e=>e.cloneNode(!0)),r={trigger:e,popover:t,observer:null,triggerId:t.getAttribute(`trigger-id`)||e.id,submenuItems:n};e.addEventListener(`click`,()=>{this._isMobileLayout()&&this._openSubmenu(r)}),this._dropdowns.push(r)}_observeDropdowns(){for(let e of this._dropdowns)e.observer||(e.observer=new MutationObserver(()=>{e.trigger.setAttribute(`aria-expanded`,String(e.popover.hasAttribute(`open`)))}),e.observer.observe(e.popover,{attributes:!0,attributeFilter:[`open`]}))}_isMobileLayout(){return this.getBoundingClientRect().width<=640}_syncResponsiveDropdowns(){let e=this._isMobileLayout();for(let t of this._dropdowns)e?(t.popover.hasAttribute(`open`)&&t.popover.close(),t.popover.getAttribute(`trigger-id`)&&t.popover.setAttribute(`trigger-id`,``)):t.triggerId&&t.popover.getAttribute(`trigger-id`)!==t.triggerId&&t.popover.setAttribute(`trigger-id`,t.triggerId);!e&&this._activeDropdown&&this._closeSubmenu()}_openSubmenu(e){this._isMobileLayout()&&(this._activeDropdown&&this._activeDropdown!==e&&this._activeDropdown.trigger.setAttribute(`aria-expanded`,`false`),this._activeDropdown=e,e.trigger.setAttribute(`aria-expanded`,`true`),this._submenuTitle.textContent=e.trigger.textContent.trim(),this._submenuItems.replaceChildren(...e.submenuItems),this._content.setAttribute(`data-submenu-open`,``))}_closeSubmenu(){this._activeDropdown?.trigger.setAttribute(`aria-expanded`,`false`),this._activeDropdown=null,this._content?.removeAttribute(`data-submenu-open`)}_syncAttributes(){if(this._brandLink){this._brandLink.setAttribute(`href`,this.getBrandHref());let e=this._brandLink.querySelector(`a`);e?e.textContent=this.getBrand():this._brandLink.textContent=this.getBrand()}this._items&&this._items.setAttribute(`aria-label`,this.getLabel()),this._syncOpenState()}_syncOpenState(){if(!this._toggle)return;let e=this.hasAttribute(`open`);this._toggle.setAttribute(`aria-expanded`,String(e));let t=e?`Close navigation menu`:`Open navigation menu`;this._toggle.setAttribute(`aria-label`,t),this._toggleLabel&&(this._toggleLabel.textContent=t),this._toggle.setAttribute(`icon`,e?`close`:`menu`)}openMenu(){this.setAttribute(`open`,``)}closeMenu(){this._closeSubmenu(),this.removeAttribute(`open`)}toggleMenu(){this.hasAttribute(`open`)?this.closeMenu():this.openMenu()}};typeof customElements<`u`&&!customElements.get(`mint-navigation`)&&e.t(`mint-navigation`,n),module.exports=n;
|
|
@@ -9,7 +9,7 @@ import '../../navigation.css'
|
|
|
9
9
|
import "../chunks/icon-hyFz3uhh.js";
|
|
10
10
|
import { t as e } from "../chunks/register-element-BFYmIynH.js";
|
|
11
11
|
import "../chunks/button-JPTyQfRs.js";
|
|
12
|
-
import "../chunks/popover-
|
|
12
|
+
import "../chunks/popover-D5-jzS7p.js";
|
|
13
13
|
import "../chunks/link-ACOyvLkd.js";
|
|
14
14
|
//#region src/components/navigation/Navigation.js
|
|
15
15
|
var t = 0, n = class extends HTMLElement {
|
|
@@ -22,7 +22,7 @@ import "../chunks/icon-hyFz3uhh.js";
|
|
|
22
22
|
import { t as e } from "../chunks/register-element-BFYmIynH.js";
|
|
23
23
|
import "../chunks/back-button-By8eO_KR.js";
|
|
24
24
|
import "../chunks/button-JPTyQfRs.js";
|
|
25
|
-
import "../chunks/popover-
|
|
25
|
+
import "../chunks/popover-D5-jzS7p.js";
|
|
26
26
|
//#region src/components/page/Page.js
|
|
27
27
|
var t = class extends HTMLElement {
|
|
28
28
|
static get observedAttributes() {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
require(`../chunks/icon-CWOP4Com.js`);const e=require(`../chunks/register-element-tCL_F1YI.js`);require(`../chunks/back-button-BGzrOtpx.js`),require(`../chunks/button-B_yN18B-.js`),require(`../chunks/popover-
|
|
1
|
+
require(`../chunks/icon-CWOP4Com.js`);const e=require(`../chunks/register-element-tCL_F1YI.js`);require(`../chunks/back-button-BGzrOtpx.js`),require(`../chunks/button-B_yN18B-.js`),require(`../chunks/popover-DFxM40QK.js`);var t=class extends HTMLElement{static get observedAttributes(){return[`heading`,`fallback-href`,`show-back-button`,`containered`]}constructor(){super(),this._actionsResizeObserver=null,this._actionsMutationObserver=null,this._actionsFrame=null,this._groupingActions=!1,this._actionFullWidthOriginal=new WeakMap,this._autoGroupedActions=new WeakSet,this._explicitOverflowActions=new WeakSet,this._root=this.attachShadow({mode:`open`}),this._root.innerHTML=`
|
|
2
2
|
<style>
|
|
3
3
|
/* The built-in back button lives inside this component's shadow root,
|
|
4
4
|
so document-level button.css cannot reach its light-DOM button. */
|
|
@@ -10,7 +10,7 @@ import "../chunks/icon-hyFz3uhh.js";
|
|
|
10
10
|
import { t as e } from "../chunks/register-element-BFYmIynH.js";
|
|
11
11
|
import "../chunks/back-button-By8eO_KR.js";
|
|
12
12
|
import "../chunks/button-JPTyQfRs.js";
|
|
13
|
-
import "../chunks/popover-
|
|
13
|
+
import "../chunks/popover-D5-jzS7p.js";
|
|
14
14
|
//#region src/components/page/Page.js
|
|
15
15
|
var t = class extends HTMLElement {
|
|
16
16
|
static get observedAttributes() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Popover.d.ts","sourceRoot":"","sources":["../../../src/components/popover/Popover.ts"],"names":[],"mappings":"AAEA,OAAO,gBAAgB,CAAA;AAyBvB,KAAK,gBAAgB,GAAG,IAAI,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,CAAA;AAQxD,cAAM,WAAY,SAAQ,WAAW;IACnC,4EAA4E;IAC5E,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,oBAAoB,CAAK;IACjD,mFAAmF;IACnF,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,6BAA6B,CAAM;IAC3D,kEAAkE;IAClE,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,6BAA6B,CAAK;IAE1D,MAAM,KAAK,kBAAkB,IAAI,MAAM,EAAE,CAaxC;IAED,OAAO,CAAC,QAAQ,CAA2B;IAC3C,OAAO,CAAC,QAAQ,CAA2B;IAC3C,OAAO,CAAC,eAAe,CAA2B;IAClD,OAAO,CAAC,iBAAiB,CAAgC;IACzD,OAAO,CAAC,oBAAoB,CAAoC;IAChE,OAAO,CAAC,oBAAoB,CAAoC;IAChE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,kBAAkB,CAAsB;IAChD,OAAO,CAAC,cAAc,CAAoC;IAC1D,OAAO,CAAC,cAAc,CAA4B;IAClD,OAAO,CAAC,iBAAiB,CAAgD;IACzE,OAAO,CAAC,QAAQ,CAAK;;IAOrB,iBAAiB,IAAI,IAAI;IAsBzB,oFAAoF;IACpF,OAAO,CAAC,SAAS;IAOjB,OAAO,CAAC,cAAc;IAwBtB,oBAAoB,IAAI,IAAI;IAuC5B,wBAAwB,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IAoB9F,KAAK,IAAI,MAAM;IAIf,UAAU,IAAI,MAAM;IA0BpB,YAAY,IAAI,gBAAgB;IAIhC,YAAY,IAAI,MAAM;IAItB,WAAW,IAAI,MAAM;IAIrB,OAAO,CAAC,cAAc;IAmBtB,cAAc,IAAI,OAAO;IAKzB,+FAA+F;IAC/F,eAAe,IAAI,QAAQ,GAAG,OAAO,GAAG,KAAK;IAM7C,yGAAyG;IACzG,sBAAsB,IAAI,OAAO;IAIjC,MAAM,IAAI,OAAO;IAKjB,IAAI,IAAI,IAAI;IAIZ,KAAK,IAAI,IAAI;IAIb,OAAO,CAAC,aAAa;IAuCrB,OAAO,CAAC,YAAY;IAQpB,OAAO,CAAC,sBAAsB;IA+B9B,OAAO,CAAC,qBAAqB;IAoC7B,OAAO,CAAC,qBAAqB;IAoB7B,OAAO,CAAC,mBAAmB;IAS3B,OAAO,CAAC,iBAAiB;IAOzB,OAAO,CAAC,WAAW;IAMnB,0GAA0G;IAC1G,OAAO,CAAC,yCAAyC;IAQjD,OAAO,CAAC,kBAAkB;
|
|
1
|
+
{"version":3,"file":"Popover.d.ts","sourceRoot":"","sources":["../../../src/components/popover/Popover.ts"],"names":[],"mappings":"AAEA,OAAO,gBAAgB,CAAA;AAyBvB,KAAK,gBAAgB,GAAG,IAAI,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,CAAA;AAQxD,cAAM,WAAY,SAAQ,WAAW;IACnC,4EAA4E;IAC5E,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,oBAAoB,CAAK;IACjD,mFAAmF;IACnF,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,6BAA6B,CAAM;IAC3D,kEAAkE;IAClE,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,6BAA6B,CAAK;IAE1D,MAAM,KAAK,kBAAkB,IAAI,MAAM,EAAE,CAaxC;IAED,OAAO,CAAC,QAAQ,CAA2B;IAC3C,OAAO,CAAC,QAAQ,CAA2B;IAC3C,OAAO,CAAC,eAAe,CAA2B;IAClD,OAAO,CAAC,iBAAiB,CAAgC;IACzD,OAAO,CAAC,oBAAoB,CAAoC;IAChE,OAAO,CAAC,oBAAoB,CAAoC;IAChE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,yBAAyB,CAAoC;IACrE,OAAO,CAAC,kBAAkB,CAAsB;IAChD,OAAO,CAAC,cAAc,CAAoC;IAC1D,OAAO,CAAC,cAAc,CAA4B;IAClD,OAAO,CAAC,iBAAiB,CAAgD;IACzE,OAAO,CAAC,QAAQ,CAAK;;IAOrB,iBAAiB,IAAI,IAAI;IAsBzB,oFAAoF;IACpF,OAAO,CAAC,SAAS;IAOjB,OAAO,CAAC,cAAc;IAwBtB,oBAAoB,IAAI,IAAI;IAuC5B,wBAAwB,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IAoB9F,KAAK,IAAI,MAAM;IAIf,UAAU,IAAI,MAAM;IA0BpB,YAAY,IAAI,gBAAgB;IAIhC,YAAY,IAAI,MAAM;IAItB,WAAW,IAAI,MAAM;IAIrB,OAAO,CAAC,cAAc;IAmBtB,cAAc,IAAI,OAAO;IAKzB,+FAA+F;IAC/F,eAAe,IAAI,QAAQ,GAAG,OAAO,GAAG,KAAK;IAM7C,yGAAyG;IACzG,sBAAsB,IAAI,OAAO;IAIjC,MAAM,IAAI,OAAO;IAKjB,IAAI,IAAI,IAAI;IAIZ,KAAK,IAAI,IAAI;IAIb,OAAO,CAAC,aAAa;IAuCrB,OAAO,CAAC,YAAY;IAQpB,OAAO,CAAC,sBAAsB;IA+B9B,OAAO,CAAC,qBAAqB;IAoC7B,OAAO,CAAC,qBAAqB;IAoB7B,OAAO,CAAC,mBAAmB;IAS3B,OAAO,CAAC,iBAAiB;IAOzB,OAAO,CAAC,WAAW;IAMnB,0GAA0G;IAC1G,OAAO,CAAC,yCAAyC;IAQjD,OAAO,CAAC,kBAAkB;IAuP1B,MAAM,IAAI,IAAI;IA+Od,OAAO,CAAC,sBAAsB;IAkC9B,OAAO,CAAC,gBAAgB;IAcxB,OAAO,CAAC,eAAe;IAwDvB,OAAO,CAAC,uBAAuB;IA+C/B,OAAO,CAAC,wBAAwB;IAWhC,OAAO,CAAC,mBAAmB;CAa5B;AAOD,eAAe,WAAW,CAAA"}
|
|
@@ -13,5 +13,5 @@ const __mintLoadStyle = (key, url) => {
|
|
|
13
13
|
__mintLoadStyle('theme', '../../theme.css')
|
|
14
14
|
__mintLoadStyle('stack', '../../stack.css')
|
|
15
15
|
__mintLoadStyle('popover', '../../popover.css')
|
|
16
|
-
import { t as e } from "../chunks/popover-
|
|
16
|
+
import { t as e } from "../chunks/popover-D5-jzS7p.js";
|
|
17
17
|
export { e as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require(`../chunks/popover-
|
|
1
|
+
const e=require(`../chunks/popover-DFxM40QK.js`);module.exports=e.t;
|
|
@@ -27,11 +27,11 @@ import "../chunks/spinner-B2sml0AG.js";
|
|
|
27
27
|
import "../chunks/button-JPTyQfRs.js";
|
|
28
28
|
import "../chunks/input-BTRS6ggP.js";
|
|
29
29
|
import "../chunks/caret-down-ZjQN2yKq.js";
|
|
30
|
-
import "../chunks/popover-
|
|
30
|
+
import "../chunks/popover-D5-jzS7p.js";
|
|
31
31
|
import { n as t } from "../chunks/ScrollFade-DvzPIk2A.js";
|
|
32
32
|
import "../chunks/search-BwjKBnv9.js";
|
|
33
33
|
import "../chunks/table-B_g7lNzN.js";
|
|
34
|
-
import "../chunks/select-
|
|
34
|
+
import "../chunks/select-B1T9k1wp.js";
|
|
35
35
|
//#region src/components/resource-table/utility-aliases.js
|
|
36
36
|
var n = {
|
|
37
37
|
"-mr-1": "rtu-8956a4275",
|
|
@@ -1218,11 +1218,11 @@ var n = {
|
|
|
1218
1218
|
}), a += "</tr>";
|
|
1219
1219
|
a += "</tbody>", a += "</table>", a += "</mint-table>", a += "</div>", a += this._paginationHostPlaceholderHtml();
|
|
1220
1220
|
} else {
|
|
1221
|
-
let e = this._virtualScrollActive() && (this._type === "provided" || this._type === "ajax" && this._loaded && !this._fetchError), t = e && this._virtualScrollRoot() === "table-body", n = this._escapeHtml(this._virtualMaxHeightCss()), o = t || this._fixedHeader(), s = this._fixedHeader() && this._fixedControls(), c = o ? " data-mint-rt-scroll-inner=\"\"" : "", l = "table-section" + (this._inMintCard ? " rounded-t-none" : ""), u = `mint-resource-table-mobile-list m-0 min-h-0 w-full list-none border-collapse overflow-x-hidden ${this._inMintCard ? "px-3.5 py-3.5" : "py-3"}
|
|
1221
|
+
let e = this._virtualScrollActive() && (this._type === "provided" || this._type === "ajax" && this._loaded && !this._fetchError), t = e && this._virtualScrollRoot() === "table-body", n = this._escapeHtml(this._virtualMaxHeightCss()), o = t || this._fixedHeader(), s = this._fixedHeader() && this._fixedControls(), c = o ? " data-mint-rt-scroll-inner=\"\"" : "", l = "table-section" + (this._inMintCard ? " rounded-t-none" : ""), u = `mint-resource-table-mobile-list m-0 min-h-0 w-full list-none border-collapse overflow-x-hidden ${this._inMintCard ? "px-3.5 py-3.5" : "py-3"}`, d = "";
|
|
1222
1222
|
if (t) {
|
|
1223
1223
|
let e = this._renderColgroupHtml();
|
|
1224
|
-
a += `<div id="mint-rt-vscroll-${this._tableId}" class="overflow-y-auto overflow-x-auto min-h-0 w-full" style="max-height: ${n}; scrollbar-gutter: stable; overscroll-behavior-x: contain; overscroll-behavior-y: none; overflow-anchor: none;">`, a += "<div class=\"
|
|
1225
|
-
} else a += "<div class=\"
|
|
1224
|
+
a += `<div id="mint-rt-vscroll-${this._tableId}" class="overflow-y-auto overflow-x-auto min-h-0 w-full" style="max-height: ${n}; scrollbar-gutter: stable; overscroll-behavior-x: contain; overscroll-behavior-y: none; overflow-anchor: none;">`, a += "<div class=\"mint-resource-table-desktop min-h-0 min-w-0\">", a += `<mint-table class="${l}"${c}>`, a += `<table id="${this._tableId}" class="w-full min-w-0 table-fixed">`, a += e, a += this._renderTheadHtml(!0, !0, !0, s);
|
|
1225
|
+
} else a += "<div class=\"mint-resource-table-desktop min-h-0 min-w-0\">", a += `<mint-table class="${l}"${c}>`, a += `<table id="${this._tableId}">`, e && (a += this._renderColgroupHtml()), a += this._renderTheadHtml(!0, !0, !!e, s);
|
|
1226
1226
|
if (a += "<tbody" + (e ? ` data-mint-rt-tbody="${this._tableId}"` : "") + ">", !this._fetching && !this._loading && !i && !e && r.forEach((e, t) => {
|
|
1227
1227
|
d += this._buildMobileListItemHtml(e, t, t === r.length - 1);
|
|
1228
1228
|
let n = typeof this._configuration.onRowClick == "function", i = n ? "cursor-pointer hover:bg-gray-50 dark:hover:bg-mint-elevated" : "";
|