efficient-shell 6.4.0 → 7.10.0

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 (90) hide show
  1. package/README.md +88 -22
  2. package/dist/Browser-VCRHLL3W.js +43 -0
  3. package/dist/Calculator-HFF54RNH.js +29 -0
  4. package/dist/ConfirmDialog-6LAVAGDE.js +1 -0
  5. package/dist/CurrencyConverter-SAIDT4WN.js +21 -0
  6. package/dist/{Documents-ADFEHEUW.js → Documents-OWPQE6D6.js} +27 -27
  7. package/dist/Files-UCNAQWGM.js +87 -0
  8. package/dist/Notepad-NNYMEU7M.js +25 -0
  9. package/dist/PdfViewer-PHABUM7K.js +1 -0
  10. package/dist/PomodoroTimer-AV3YE2WJ.js +91 -0
  11. package/dist/Preview-PWFREL75.js +182 -0
  12. package/dist/Sidebar-3IB3YIWC.js +44 -0
  13. package/dist/Spreadsheet-F5BXANOO.js +37 -0
  14. package/dist/Stock-EP2SB76N.js +16 -0
  15. package/dist/{Weather-BLO354GM.js → Weather-62FA6T6O.js} +35 -35
  16. package/dist/WorldClock-C3A6PZYM.js +32 -0
  17. package/dist/apps/index.js +1 -1
  18. package/dist/bin/ui-check.js +1 -1
  19. package/dist/brand.css +1 -1
  20. package/dist/{chunk-YX2IMURA.js → chunk-7BX3JQBP.js} +10 -10
  21. package/dist/{chunk-MORDXCV6.js → chunk-7HLTPMQV.js} +1 -1
  22. package/dist/{chunk-4JZZLUGG.js → chunk-B4PGVDB6.js} +1 -1
  23. package/dist/chunk-B4XGJA3N.js +1 -0
  24. package/dist/{chunk-7PGHRG6J.js → chunk-BQ7GR7H6.js} +11 -11
  25. package/dist/{chunk-R5VRLW5Z.js → chunk-BXW5WAEX.js} +1 -1
  26. package/dist/{chunk-SK5DL6JX.js → chunk-FTJ2G343.js} +14 -14
  27. package/dist/{chunk-XO2AMGVU.js → chunk-GGSG7HSD.js} +1 -1
  28. package/dist/{chunk-ZEIKSMFR.js → chunk-ICN533ML.js} +8 -8
  29. package/dist/{chunk-I534M65N.js → chunk-ITCBLL72.js} +2 -2
  30. package/dist/{chunk-GWDVD3VQ.js → chunk-JQRIAZDP.js} +23 -23
  31. package/dist/{chunk-WOEFPBQF.js → chunk-KBOYLXAT.js} +1 -1
  32. package/dist/chunk-KSLOSQKN.js +29 -0
  33. package/dist/{chunk-UUYPUKP7.js → chunk-M4TRVJTO.js} +1 -1
  34. package/dist/{chunk-CXJQ42XT.js → chunk-MFDZYZZX.js} +15 -15
  35. package/dist/chunk-NGUH7T5V.js +1 -0
  36. package/dist/chunk-QRCDQPJA.js +1 -0
  37. package/dist/{chunk-5K76RQML.js → chunk-RBKIYZ7H.js} +1 -1
  38. package/dist/{chunk-GJ37JCC2.js → chunk-RUHUTZN4.js} +1 -1
  39. package/dist/{chunk-I2H2CKID.js → chunk-SCJT2XXU.js} +1 -1
  40. package/dist/{chunk-QJHWLDEN.js → chunk-THM35LAN.js} +71 -71
  41. package/dist/{chunk-5LUN632W.js → chunk-UJL5J7GX.js} +4 -4
  42. package/dist/chunk-UZJ6RYMF.js +9 -0
  43. package/dist/chunk-W6BQVATM.js +1016 -0
  44. package/dist/{chunk-VR6TR575.js → chunk-XN7CAWSZ.js} +3 -3
  45. package/dist/{chunk-IHZL3GJU.js → chunk-Y56GRZ2Q.js} +1 -1
  46. package/dist/chunk-YMWCZKUN.js +12 -0
  47. package/dist/{chunk-Q5O5UMJY.js → chunk-Z2TTHY7G.js} +2 -2
  48. package/dist/{chunk-2SSRFEOZ.js → chunk-ZGUQLVY4.js} +5 -3
  49. package/dist/{chunk-HQLAISFX.js → chunk-ZRU5F2XT.js} +4 -4
  50. package/dist/file-intake/index.js +1 -1
  51. package/dist/i18n/index.d.ts +1 -1
  52. package/dist/icons/efficient-looks.js +20 -10
  53. package/dist/icons/efficient.d.ts +7 -5
  54. package/dist/icons/efficient.js +51 -48
  55. package/dist/icons/index.d.ts +1 -1
  56. package/dist/icons/index.js +1 -1
  57. package/dist/{index-D5bms_uA.d.ts → index-Cevszdp8.d.ts} +296 -90
  58. package/dist/index.d.ts +3 -3
  59. package/dist/index.js +632 -639
  60. package/dist/locales/zh-Hans.d.ts +1 -1
  61. package/dist/locales/zh-Hans.js +1 -1
  62. package/dist/map/index.js +10 -10
  63. package/dist/markdown/index.js +4 -4
  64. package/dist/page-tabs/index.js +5 -5
  65. package/dist/pdf/index.js +1 -1
  66. package/dist/{strings-fYzxZPn4.d.ts → strings-BQtq9300.d.ts} +17 -2
  67. package/dist/telemetry/index.js +1 -1
  68. package/dist/ui/index.d.ts +2 -2
  69. package/dist/ui/index.js +1 -1
  70. package/dist/ui.css +50 -54
  71. package/package.json +1 -1
  72. package/dist/Browser-USPZWDYH.js +0 -43
  73. package/dist/Calculator-FP5HUWCW.js +0 -29
  74. package/dist/ConfirmDialog-3TIHKJRT.js +0 -1
  75. package/dist/CurrencyConverter-XD5LYOCD.js +0 -21
  76. package/dist/Files-BVUVRNC5.js +0 -87
  77. package/dist/Notepad-WJI5ODGS.js +0 -25
  78. package/dist/PdfViewer-226I3LSD.js +0 -1
  79. package/dist/PomodoroTimer-GEMQHIPJ.js +0 -91
  80. package/dist/Preview-HNSEYNZL.js +0 -182
  81. package/dist/Sidebar-PVHZPNIY.js +0 -44
  82. package/dist/Spreadsheet-6Z5ACGTT.js +0 -37
  83. package/dist/Stock-X3LIU4ZX.js +0 -16
  84. package/dist/WorldClock-BAH7QFRG.js +0 -32
  85. package/dist/chunk-5MDQNFOG.js +0 -9
  86. package/dist/chunk-DBXZS7OA.js +0 -29
  87. package/dist/chunk-K6DKX55N.js +0 -1
  88. package/dist/chunk-PFKMIPZH.js +0 -1028
  89. package/dist/chunk-S3LGKIZ3.js +0 -12
  90. package/dist/chunk-SBF5A6XV.js +0 -1
@@ -1,12 +0,0 @@
1
- import{solidSurfaceStyle as t}from"./chunk-7IQ3B77H.js";import{registerModalEscapeInterceptor as e,escapeSurfaceAbove as o,onOverlayOpen as i,Z_LAYERS as r}from"./chunk-FIEA5CGB.js";import{useBrowserLayoutEffect as n}from"./chunk-D65T4H6J.js";import{forwardRef as a,useId as l,useState as s,useRef as h,useEffect as c,isValidElement as d,cloneElement as m}from"react";import{createPortal as u}from"react-dom";import{jsxs as f,jsx as g,Fragment as p}from"react/jsx-runtime";var b="aria-disabled:cursor-not-allowed aria-disabled:opacity-60",x="inline-flex items-center justify-center rounded-(--radius-control) font-medium transition-colors rosh-focus-ring focus-visible:ring-2 disabled:cursor-not-allowed disabled:opacity-60 "+b,w={primary:"bg-blue-600 text-white shadow-sm hover:bg-blue-700 focus-visible:ring-[color:var(--rosh-focus-ring-strong)]",secondary:"border border-gray-300 bg-white text-gray-700 shadow-sm hover:bg-gray-50 focus-visible:ring-[color:var(--rosh-focus-ring)]","secondary-danger":"border border-red-300 bg-white text-red-600 shadow-sm hover:bg-red-50 focus-visible:ring-[color:var(--rosh-focus-ring-invalid)]",ghost:"text-gray-700 hover:bg-gray-100 focus-visible:ring-[color:var(--rosh-focus-ring)]","ghost-danger":"text-red-600 hover:bg-red-50 focus-visible:ring-[color:var(--rosh-focus-ring-invalid)]",danger:"bg-red-600 text-white shadow-sm hover:bg-red-700 focus-visible:ring-[color:var(--rosh-focus-ring-invalid-strong)]",link:"text-blue-600 underline-offset-4 hover:underline focus-visible:ring-[color:var(--rosh-focus-ring)]"},v={sm:"gap-1 px-2.5 py-1 text-xs",md:"gap-1.5 px-3 py-1.5 text-sm",lg:"gap-2 px-4 py-2.5 text-sm","touch-sm":"gap-1.5 h-11 px-4 text-base",touch:"gap-2 h-14 px-5 text-base","touch-lg":"gap-2 h-16 px-6 text-lg","touch-xl":"gap-3 h-20 px-8 text-2xl"},y="inline-flex items-center font-medium transition-colors rosh-focus-ring focus-visible:ring-2 disabled:cursor-not-allowed disabled:opacity-60 "+b,M={sm:"gap-1 text-xs",md:"gap-1.5 text-sm",lg:"gap-2 text-sm","touch-sm":"gap-1.5 text-base",touch:"gap-2 text-base","touch-lg":"gap-2 text-lg","touch-xl":"gap-3 text-2xl"},N={sm:"h-6 w-6",md:"h-8 w-8",lg:"h-10 w-10","touch-sm":"h-11 w-11",touch:"h-14 w-14","touch-lg":"h-16 w-16","touch-xl":"h-20 w-20"};function W({variant:t="primary",size:e="md",block:o=!1,className:i=""}={}){const r="link"===t;return[r?y:x,w[t],r?M[e]:v[e],o?"w-full":"",i].filter(Boolean).join(" ")}function k({variant:t="ghost",size:e="md",pressed:o=!1,className:i=""}={}){const r=!o||"ghost"!==t&&"secondary"!==t?w[t]:"bg-blue-50 text-blue-700 hover:bg-blue-100 focus-visible:ring-[color:var(--rosh-focus-ring)]";return[x,r,N[e],"shrink-0 p-0",i].filter(Boolean).join(" ")}var B=448,C=240,H=8,E=()=>({left:0,right:window.innerWidth,top:0,bottom:window.innerHeight});function j(t){const e=E(),o=t?.closest?.("[data-modal-panel]");if(!o)return e;const i=o.getBoundingClientRect();return i.width<=0||i.height<=0?e:{left:Math.max(e.left,i.left),right:Math.min(e.right,i.right),top:Math.max(e.top,i.top),bottom:Math.min(e.bottom,i.bottom)}}var z=/* @__PURE__ */new Set(["hidden","clip","auto","scroll"]);var R={top:"bottom",bottom:"top",left:"right",right:"left"},T={top:["right","left"],bottom:["right","left"],left:["top","bottom"],right:["top","bottom"]};function F(t,e,o){return{top:t.top-o-(e.top+8),bottom:e.bottom-8-(t.bottom+o),left:t.left-o-(e.left+8),right:e.right-8-(t.right+o)}}var I=(t,e,o)=>Math.max(e,Math.min(t,o));function L(t,e,o){let i=NaN,r=NaN,n=NaN,a=NaN,l=NaN;const s=()=>{const e=t()?.getBoundingClientRect();if(!e)return!1;const s=o?o():NaN,h=e.left!==i||e.top!==r||e.right!==n||e.bottom!==a||s!==l&&!(Number.isNaN(s)&&Number.isNaN(l));return i=e.left,r=e.top,n=e.right,a=e.bottom,l=s,h};s();const h=()=>{s(),e()};let c=requestAnimationFrame(function t(){s()&&e(),c=requestAnimationFrame(t)});return window.addEventListener("scroll",h,!0),window.addEventListener("resize",h),()=>{cancelAnimationFrame(c),window.removeEventListener("scroll",h,!0),window.removeEventListener("resize",h)}}function A({trigger:t,menu:e,bounds:o,align:i,side:r}){const n=F(t,o,4),a="bottom"===r?"top":"bottom",l=e.height>n[r]&&(e.height<=n[a]||n[a]>n[r])?a:r,s=Math.max(Math.min(e.height,96),n[l]),h=Math.min(e.height,s),c=I("bottom"===l?t.bottom+4:t.top-4-h,o.top+8,o.bottom-8-h),d=Math.max(0,o.right-o.left-16),m=Math.min(e.width,d);return{left:I("start"===i?t.left:t.right-m,o.left+8,o.right-8-m),top:c,side:l,maxHeight:s,maxWidth:d}}function D(t,e,o={}){const{matchTriggerWidth:i=!1,preferredMaxWidth:r=B,preferredMaxHeight:a=C,popupRef:l}=o,[h,c]=s(null);return n(()=>{if(!e)return void c(null);const o=()=>{const e=t.current,o=e?.getBoundingClientRect();if(!o)return;const n=j(e),s=n.bottom-o.bottom-4-8,h=o.top-n.top-4-8,d=s<Math.min(a,160)&&h>s,m=Math.max(96,Math.min(a,d?h:s)),u=Math.max(0,n.right-n.left-16),f={minWidth:o.width,maxWidth:Math.min(r,u),maxHeight:m};if(i){const t=Math.min(o.width,u);f.width=t,f.maxWidth=t,f.left=Math.min(Math.max(n.left+8,o.left),n.right-8-t)}else if(l&&n.right-8-o.left<f.maxWidth&&Math.min(o.right,n.right-8)-n.left-8<f.maxWidth){const t=l.current?.offsetWidth??0,e=t>0?Math.min(t,f.maxWidth):f.maxWidth;f.left=Math.max(n.left+8,Math.min(o.left,n.right-8-e))}else if(n.right-8-o.left<f.maxWidth){const t=Math.min(o.right,n.right-8);f.right=window.innerWidth-t,f.maxWidth=Math.min(f.maxWidth,Math.max(0,t-n.left-8))}else f.left=Math.max(n.left+8,o.left);d?f.bottom=window.innerHeight-o.top+4:f.top=o.bottom+4,c(f)};return o(),L(()=>t.current,o,l?()=>l.current?.offsetWidth??NaN:void 0)},[e,t,i,r,a,l]),h}function S({point:t,menu:e,bounds:o}){const i={left:t.x,right:t.x,top:t.y,bottom:t.y},r=o.right-8-t.x,n=t.x-(o.left+8);return A({trigger:i,menu:e,bounds:o,align:e.width<=r||r>=n?"start":"end",side:"bottom"})}var $={top:"bottom-full left-1/2 -translate-x-1/2 mb-3",bottom:"top-full left-1/2 -translate-x-1/2 mt-3",left:"right-full top-1/2 -translate-y-1/2 mr-3",right:"left-full top-1/2 -translate-y-1/2 ml-3"};function q({content:a,side:p="top",delay:b=200,children:x,className:w="relative inline-flex",describe:v=!0}){const[y,M]=s(!1),N=y&&!(null==a||!1===a||""===a),[W,k]=s(null),B=h(void 0),C=h(null),H=h(null),A=l(),D=h(!1),S=()=>{window.clearTimeout(B.current),D.current||(B.current=window.setTimeout(()=>M(!0),b))},q=()=>{window.clearTimeout(B.current),M(!1)},P=()=>{D.current=!0,q()},G=()=>{D.current=!1,q()};c(()=>()=>window.clearTimeout(B.current),[]),n(()=>{if(!N)return void k(null);const t=()=>{const t=C.current,e=H.current;if(!t||!e)return;const o=j(t),i=Math.max(0,o.right-o.left-16),r=Math.max(0,o.bottom-o.top-16);e.style.maxWidth=`${i}px`,e.style.maxHeight=`${r}px`;const n=e.getBoundingClientRect();if(n.width<=0||n.height<=0)return;const a=t.getBoundingClientRect();if(!function(t){const e=t.getBoundingClientRect();if(e.width<=0&&e.height<=0&&0===e.left&&0===e.top)return null;const o=E(),i={left:Math.max(o.left,e.left),right:Math.min(o.right,e.right),top:Math.max(o.top,e.top),bottom:Math.min(o.bottom,e.bottom)};let r=getComputedStyle(t).position;for(let e=t.parentElement;e&&e!==document.documentElement&&"fixed"!==r;e=e.parentElement){const t=getComputedStyle(e);if("absolute"===r&&"static"===t.position)continue;r=t.position;const o=z.has(t.overflowX),n=z.has(t.overflowY);if(!o&&!n)continue;const a=e.getBoundingClientRect();a.width<=0&&a.height<=0||(o&&(i.left=Math.max(i.left,a.left),i.right=Math.min(i.right,a.right)),n&&(i.top=Math.max(i.top,a.top),i.bottom=Math.min(i.bottom,a.bottom)))}return i.right>=i.left&&i.bottom>=i.top?i:null}(t))return void q();const l=function(t,e,o,i,r){const n=F(t,i,r),a=t=>n[t]-("top"===t||"bottom"===t?e.height:e.width),l=[o,R[o],...T[o]],s=l.find(t=>a(t)>=0)??l.reduce((t,e)=>a(e)>a(t)?e:t),h=(t.left+t.right)/2,c=(t.top+t.bottom)/2;let d,m;switch(s){case"top":d=h-e.width/2,m=t.top-r-e.height;break;case"bottom":d=h-e.width/2,m=t.bottom+r;break;case"left":d=t.left-r-e.width,m=c-e.height/2;break;case"right":d=t.right+r,m=c-e.height/2}return{side:s,left:I(d,i.left+8,i.right-8-e.width),top:I(m,i.top+8,i.bottom-8-e.height)}}(a,n,p,o,12),s=function(t,e,o,i,r){const{side:n,left:a,top:l}=e,s=a+o.width,h=l+o.height;if({top:t.top-h,bottom:l-t.bottom,left:t.left-s,right:a-t.right}[n]<r)return null;const c=(t,e,o)=>o<2*i?e+o/2:Math.max(e+i,Math.min(t,e+o-i)),d=(t.left+t.right)/2,m=(t.top+t.bottom)/2;switch(n){case"top":return{side:n,x:c(d,a,o.width),y:h};case"bottom":return{side:n,x:c(d,a,o.width),y:l};case"left":return{side:n,x:s,y:c(m,l,o.height)};case"right":return{side:n,x:a,y:c(m,l,o.height)}}}(a,l,n,16,6),h={anchor:{left:a.left,top:a.top,width:a.width,height:a.height},left:l.left-a.left,top:l.top-a.top,maxWidth:i,maxHeight:r,side:l.side,arrow:s&&{left:s.x-a.left,top:s.y-a.top}};k(t=>{return t&&(o=h,(e=t).anchor.left===o.anchor.left&&e.anchor.top===o.anchor.top&&e.anchor.width===o.anchor.width&&e.anchor.height===o.anchor.height&&e.left===o.left&&e.top===o.top&&e.maxWidth===o.maxWidth&&e.maxHeight===o.maxHeight&&e.side===o.side&&e.arrow?.left===o.arrow?.left&&e.arrow?.top===o.arrow?.top)?t:h;var e,o})};return t(),L(()=>C.current,t)},[N,p,a]),c(()=>{if(!N)return;const t=e(t=>"Escape"===t.key&&(q(),!o(C.current))),r=i(q);return()=>{t(),r()}},[N]);const J=N&&v?A:void 0,Q=d(x)?m(x,{"aria-describedby":[x.props["aria-describedby"],J].filter(Boolean).join(" ")||void 0}):x,X=N?t():void 0;/* @__PURE__ */
2
- return f("span",{ref:C,className:w,"aria-describedby":d(x)?void 0:J,onMouseEnter:S,onMouseLeave:G,onFocus:S,onBlur:G,onPointerDown:P,onClick:P,children:[Q,N&&u(
3
- /* @__PURE__ */f("span",{className:"pointer-events-none fixed left-0 top-0",style:{zIndex:r.hint,...W?.anchor},children:[
4
- /* @__PURE__ */g("span",{ref:H,id:A,role:"tooltip",className:`pointer-events-none absolute z-[300] box-border w-max overflow-hidden whitespace-normal break-words text-start rounded-md px-2 py-1 text-xs text-gray-800 ${W?"":$[p]}`,style:{...X,...W&&{left:W.left,top:W.top,maxWidth:W.maxWidth,maxHeight:W.maxHeight}},children:a}),(!W||W.arrow)&&
5
- /* @__PURE__ */g("span",{"aria-hidden":"true",className:"rosh-tooltip-arrow","data-side":W?.side??p,style:{background:X?.background,"--rosh-tooltip-edge":X?.border,...W?.arrow&&{left:W.arrow.left,top:W.arrow.top}}})]}),document.body)]})}var P=t=>!0===t||"true"===t;function G(t){t.preventDefault(),t.stopPropagation()}var J=(t,e)=>[t,e].filter(Boolean).join(" ")||void 0;function Q({reason:t,id:e,block:o=!1,children:i}){/* @__PURE__ */
6
- return f(p,{children:[
7
- /* @__PURE__ */g(q,{content:t,describe:!1,className:o?"relative flex w-full":"relative inline-flex",children:i}),
8
- /* @__PURE__ */g("span",{id:e,className:"sr-only",children:t})]})}function X(){/* @__PURE__ */
9
- return f("svg",{className:"h-3.5 w-3.5 animate-spin",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true",children:[
10
- /* @__PURE__ */g("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),
11
- /* @__PURE__ */g("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8v4a4 4 0 00-4 4H4z"})]})}var Y=a(function({variant:t="primary",size:e="md",loading:o=!1,leftIcon:i,rightIcon:r,block:n=!1,disabled:a,type:s="button",children:h,className:c="",disabledReason:d,onClick:m,"aria-disabled":u,"aria-describedby":p,...b},x){const w=l(),v=a||o,y=null!=d&&""!==d,M=v&&y,N=!v&&P(u),k=N&&y,B=M||k?w:void 0,C=/* @__PURE__ */f("button",{ref:x,type:s,disabled:v,"aria-busy":o||void 0,"aria-disabled":!!N||u,"aria-describedby":J(p,B),onClick:N?G:m,className:W({variant:t,size:e,block:n,className:c}),...b,children:[o?/* @__PURE__ */g(X,{}):i,h,!o&&r]});return k?/* @__PURE__ */g(Q,{reason:d,id:w,block:n,children:C}):M?/* @__PURE__ */f("span",{className:n?"flex w-full flex-col gap-1":"inline-flex flex-col items-start gap-1",children:[C,
12
- /* @__PURE__ */g("span",{id:B,className:"text-xs text-red-600",children:d})]}):C});export{Y as Button_default,C as MENU_MAX_HEIGHT,Q as OffWithReason,B as POPUP_MAX_WIDTH,q as Tooltip,H as VIEWPORT_MARGIN,W as buttonClasses,J as describedByWith,L as followAnchor,k as iconButtonClasses,P as isAriaDisabled,S as placeAtPoint,A as placeMenu,j as popupBounds,G as swallowPress,D as useDropdownPosition};
@@ -1 +0,0 @@
1
- var r="6.4.0",a=r;export{a as APP_VERSION,r as VERSION};