@wistia/vhs 2.47.0-beta.044ab0c0.6dfd4fc → 2.47.0-beta.0d4b5f37.f00e969

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.
@@ -0,0 +1 @@
1
+ {"version":3,"file":"HideInVisualRegressionTests.d.ts","sourceRoot":"","sources":["../../../.storybook/components/HideInVisualRegressionTests.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,KAAK,gCAAgC,GAAG;IACtC,QAAQ,EAAE,SAAS,CAAC;CACrB,CAAC;AAIF,eAAO,MAAM,2BAA2B,kBAErC,gCAAgC,KAAG,WAOrC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const getRandomEmoji: (count?: number) => (string | undefined)[] | string | undefined;
2
+ //# sourceMappingURL=getRandomEmoji.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getRandomEmoji.d.ts","sourceRoot":"","sources":["../../../.storybook/helpers/getRandomEmoji.ts"],"names":[],"mappings":"AAuCA,eAAO,MAAM,cAAc,sBAAgB,CAAC,MAAM,GAAG,SAAS,CAAC,EAAE,GAAG,MAAM,GAAG,SAO5E,CAAC"}
@@ -0,0 +1,8 @@
1
+ type dictType = keyof typeof dictionary;
2
+ declare const dictionary: {
3
+ default: string[];
4
+ marketing: string[];
5
+ };
6
+ export declare const placeholderText: (wordCount?: number, dictionaryType?: dictType, addPeriod?: boolean, noSpaces?: boolean) => string;
7
+ export {};
8
+ //# sourceMappingURL=placeholderText.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"placeholderText.d.ts","sourceRoot":"","sources":["../../../.storybook/helpers/placeholderText.ts"],"names":[],"mappings":"AAEA,KAAK,QAAQ,GAAG,MAAM,OAAO,UAAU,CAAC;AAGxC,QAAA,MAAM,UAAU;;;CAGf,CAAC;AAMF,eAAO,MAAM,eAAe,wCAEV,QAAQ,oDAgBzB,CAAC"}
package/dist/index.cjs.js CHANGED
@@ -1,6 +1,6 @@
1
1
 
2
2
  /*
3
- * @license VHS v2.47.0-beta.044ab0c0.6dfd4fc
3
+ * @license VHS v2.47.0-beta.0d4b5f37.f00e969
4
4
  *
5
5
  * Copyright (c) 2021-2024, Wistia, Inc. and its affiliates.
6
6
  *
@@ -355,12 +355,81 @@
355
355
  margin: 0;
356
356
  }
357
357
  `,RP=({children:e})=>{if(M4())return null;let t=document.getElementById("toast-portal");return t?(0,k4.createPortal)(e,t):null},Ds=null,Ss=(0,xr.memo)(({actionInterceptor:e=void 0,actionLabel:t=T0,colorOverride:r=void 0,renderInPlace:n=!1,isOpen:o=!1,message:a,onClose:s,timeout:u=P0,variant:l=S0,...c})=>{let[p,m]=(0,xr.useState)(o),h=l==="error"||l==="warning"?"assertive":"polite",v=(0,xr.useCallback)(()=>{clearTimeout(Ds??void 0),Ds=null},[]),d=()=>{v(),s()},C=()=>{Ds=setTimeout(()=>{d()},u)};(0,xr.useEffect)(()=>(p&&!n&&C(),()=>{ln(Ds)&&v()})),(0,xr.useEffect)(()=>(m(o),()=>{ln(Ds)&&v()}),[o,v,m]);let y=$P(r,l,He());return(0,Hn.jsx)(n?xr.Fragment:RP,{children:(0,Hn.jsx)(Dh,{in:p,children:(0,Hn.jsxs)(FP,{accentColor:y,"aria-hidden":!p,onMouseEnter:v,onMouseLeave:C,renderInPlace:n,...c,children:[(0,Hn.jsxs)(BP,{"data-testid":"toast-message",children:[(0,Hn.jsx)(ps,{"aria-live":h,message:a}),a]}),(0,Hn.jsx)(Xe,{colorOverride:y,"data-testid":"toast-action",label:t,onClick:e??d,variant:"tertiary"})]},a)})})});Ss.displayName="Toast_VHS";i();var N4=require("react"),gl=(0,N4.createContext)(null);var Gn=require("react/jsx-runtime"),hl=({children:e})=>{let[t,r]=(0,Lr.useState)(void 0),[n,o]=(0,Lr.useState)(""),[a,s]=(0,Lr.useState)(void 0),[u,l]=(0,Lr.useState)(""),[c,p]=(0,Lr.useState)(!1),[m,g]=(0,Lr.useState)(void 0),[h,v]=(0,Lr.useState)(void 0),d=(0,Lr.useCallback)(({message:C,variant:y=S0,actionLabel:x=T0,actionInterceptor:D,timeout:E=P0,colorOverride:A})=>{r(D?()=>D:void 0),o(x),s(A),l(C),p(!0),g(E),v(y)},[]);return(0,Gn.jsxs)(Gn.Fragment,{children:[(0,Gn.jsx)(gl.Provider,{value:d,children:e}),(0,Gn.jsx)(Ss,{actionInterceptor:t,actionLabel:n,colorOverride:a,isOpen:c,message:u,onClose:()=>p(!1),timeout:m,variant:h}),(0,Gn.jsx)("div",{id:"toast-portal"})]})};i();var wr=require("react");i();var vl=require("react"),A0=(0,vl.createContext)({}),$0=()=>(0,vl.useContext)(A0);var L4=require("react/jsx-runtime"),bl=({children:e})=>{let r=(0,wr.useRef)(new Set).current,n=(0,wr.useCallback)(p=>r.values().next().value===p,[r]),o=(0,wr.useCallback)(()=>{let p=r.values().next().value;W1(p)&&p(!0)},[r]),a=(0,wr.useCallback)(()=>{let p=r.values().next().value;W1(p)&&p(!1)},[r]),s=(0,wr.useCallback)(p=>{r.add(p),n(p)&&o()},[r,n,o]),u=(0,wr.useCallback)(p=>{r.add(p),n(p)?(a(),r.delete(p),o()):r.delete(p)},[r,n,a,o]),l=(0,wr.useCallback)(p=>{r.delete(p)},[r]),c=(0,wr.useMemo)(()=>({attemptShowModal:s,attemptHideModal:u,removeModalFromQueue:l}),[s,u,l]);return(0,L4.jsx)(A0.Provider,{value:c,children:e})};i();var G4=require("styled-components");i();var V4=require("styled-components"),z4=V4.css`
358
- /* stylelint-disable */
359
- /* normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */
358
+ /* Box sizing rules */
359
+ *,
360
+ *::before,
361
+ *::after {
362
+ box-sizing: border-box;
363
+ }
364
+
365
+ /* Remove default margin */
366
+ body,
367
+ h1,
368
+ h2,
369
+ h3,
370
+ h4,
371
+ p,
372
+ figure,
373
+ blockquote,
374
+ dl,
375
+ dd {
376
+ margin: 0;
377
+ }
360
378
 
361
- /* Document
362
- ========================================================================== */
379
+ /* Remove list styles on ul, ol elements with a list role, which suggests default styling will be removed */
380
+ ul[role='list'],
381
+ ol[role='list'] {
382
+ list-style: none;
383
+ }
384
+
385
+ /* Set core root defaults */
386
+ html:focus-within {
387
+ scroll-behavior: smooth;
388
+ }
389
+
390
+ /* Set core body defaults */
391
+ body {
392
+ min-height: 100vh;
393
+ text-rendering: optimizespeed;
394
+ line-height: 1.5;
395
+ }
396
+
397
+ /* A elements that don't have a class get default styles */
398
+ a:not([class]) {
399
+ text-decoration-skip-ink: auto;
400
+ }
363
401
 
402
+ /* Make images easier to work with */
403
+ img,
404
+ picture {
405
+ max-width: 100%;
406
+ display: block;
407
+ }
408
+
409
+ /* Inherit fonts for inputs and buttons */
410
+ input,
411
+ button,
412
+ textarea,
413
+ select {
414
+ font: inherit;
415
+ }
416
+
417
+ /* Remove all animations and transitions for people that prefer not to see them */
418
+ @media (prefers-reduced-motion: reduce) {
419
+ html:focus-within {
420
+ scroll-behavior: auto;
421
+ }
422
+
423
+ *,
424
+ *::before,
425
+ *::after {
426
+ animation-duration: 0.01ms !important;
427
+ animation-iteration-count: 1 !important;
428
+ transition-duration: 0.01ms !important;
429
+ scroll-behavior: auto !important;
430
+ }
431
+ }
432
+ `;i();var _4=require("styled-components"),H4=_4.css`
364
433
  /**
365
434
  * 1. Correct the line height in all browsers.
366
435
  * 2. Prevent adjustments of font size after orientation changes in iOS.
@@ -368,6 +437,7 @@
368
437
 
369
438
  html {
370
439
  line-height: 1.15; /* 1 */
440
+ /* stylelint-disable-next-line property-no-vendor-prefix */
371
441
  -webkit-text-size-adjust: 100%; /* 2 */
372
442
  }
373
443
 
@@ -420,6 +490,7 @@
420
490
  */
421
491
 
422
492
  pre {
493
+ /* stylelint-disable-next-line font-family-no-duplicate-names */
423
494
  font-family: monospace, monospace; /* 1 */
424
495
  font-size: 1em; /* 2 */
425
496
  }
@@ -463,6 +534,7 @@
463
534
  code,
464
535
  kbd,
465
536
  samp {
537
+ /* stylelint-disable-next-line font-family-no-duplicate-names */
466
538
  font-family: monospace, monospace; /* 1 */
467
539
  font-size: 1em; /* 2 */
468
540
  }
@@ -556,6 +628,7 @@
556
628
  [type='button'],
557
629
  [type='reset'],
558
630
  [type='submit'] {
631
+ /* stylelint-disable-next-line property-no-vendor-prefix */
559
632
  -webkit-appearance: button;
560
633
  }
561
634
 
@@ -648,6 +721,7 @@
648
721
  */
649
722
 
650
723
  [type='search'] {
724
+ /* stylelint-disable-next-line property-no-vendor-prefix */
651
725
  -webkit-appearance: textfield; /* 1 */
652
726
  outline-offset: -2px; /* 2 */
653
727
  }
@@ -657,6 +731,7 @@
657
731
  */
658
732
 
659
733
  [type='search']::-webkit-search-decoration {
734
+ /* stylelint-disable-next-line property-no-vendor-prefix */
660
735
  -webkit-appearance: none;
661
736
  }
662
737
 
@@ -666,6 +741,7 @@
666
741
  */
667
742
 
668
743
  ::-webkit-file-upload-button {
744
+ /* stylelint-disable-next-line property-no-vendor-prefix */
669
745
  -webkit-appearance: button; /* 1 */
670
746
  font: inherit; /* 2 */
671
747
  }
@@ -707,8 +783,7 @@
707
783
  [hidden] {
708
784
  display: none;
709
785
  }
710
- /* stylelint-enable */
711
- `;i();var _4=require("styled-components"),H4=_4.css`
786
+
712
787
  /**
713
788
  * 1. Change from 'content-box' so that 'width' calculations are unaffected by 'padding' or 'border'
714
789
  * 2. Ensure the iOS tap highlight is transparent