@astl/astrolabe 0.1.3 → 0.1.4
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/CHANGELOG.md +14 -0
- package/dist/cdn/astrolabe-editor.js +3 -3
- package/dist/cdn/astrolabe-player.js +1 -1
- package/dist/cdn/astrolabe.js +1 -1
- package/dist/cdn/astrolabe.standalone.js +1084 -1075
- package/dist/cdn/chunks/{audio-B0LSIn5N.js → audio-Biof5aA3.js} +2 -2
- package/dist/cdn/chunks/{audio-B0LSIn5N.js.map → audio-Biof5aA3.js.map} +1 -1
- package/dist/cdn/chunks/{block-styles-CKo9x7Vt.js → block-styles-CCtSFM4j.js} +2 -2
- package/dist/cdn/chunks/{block-styles-CKo9x7Vt.js.map → block-styles-CCtSFM4j.js.map} +1 -1
- package/dist/cdn/chunks/{book-CHzDDaim.js → book-IFipARhv.js} +2 -2
- package/dist/cdn/chunks/{book-CHzDDaim.js.map → book-IFipARhv.js.map} +1 -1
- package/dist/cdn/chunks/{callout-QFLFLPc5.js → callout-CuajbbYY.js} +2 -2
- package/dist/cdn/chunks/{callout-QFLFLPc5.js.map → callout-CuajbbYY.js.map} +1 -1
- package/dist/cdn/chunks/{categorise-BO2tNVJ3.js → categorise-Cm6kXLXw.js} +2 -2
- package/dist/cdn/chunks/{categorise-BO2tNVJ3.js.map → categorise-Cm6kXLXw.js.map} +1 -1
- package/dist/cdn/chunks/{chip-styles-Dme5daTO.js → chip-styles--gboWK2Z.js} +2 -2
- package/dist/cdn/chunks/{chip-styles-Dme5daTO.js.map → chip-styles--gboWK2Z.js.map} +1 -1
- package/dist/cdn/chunks/{choice-CExBvqKj.js → choice-BSpB6LHl.js} +2 -2
- package/dist/cdn/chunks/{choice-CExBvqKj.js.map → choice-BSpB6LHl.js.map} +1 -1
- package/dist/cdn/chunks/{color-control-Cl5cuMSO.js → color-control-1kkdM8ns.js} +2 -2
- package/dist/cdn/chunks/{color-control-Cl5cuMSO.js.map → color-control-1kkdM8ns.js.map} +1 -1
- package/dist/cdn/chunks/{crossword-Cb-a3Tjj.js → crossword-BdOAEPcL.js} +2 -2
- package/dist/cdn/chunks/{crossword-Cb-a3Tjj.js.map → crossword-BdOAEPcL.js.map} +1 -1
- package/dist/cdn/chunks/{definitions-CNX90WtL.js → definitions-BybSa1mq.js} +2 -2
- package/dist/cdn/chunks/{definitions-CNX90WtL.js.map → definitions-BybSa1mq.js.map} +1 -1
- package/dist/cdn/chunks/{directive-helpers-D7lOZKnB.js → directive-helpers-US6zRjJ1.js} +2 -2
- package/dist/cdn/chunks/{directive-helpers-D7lOZKnB.js.map → directive-helpers-US6zRjJ1.js.map} +1 -1
- package/dist/cdn/chunks/{drop-vRXndjHu.js → drop-D4NQ0WK_.js} +2 -2
- package/dist/cdn/chunks/{drop-vRXndjHu.js.map → drop-D4NQ0WK_.js.map} +1 -1
- package/dist/cdn/chunks/{flash-cards-0NrrKdrx.js → flash-cards-D4ebb5m6.js} +2 -2
- package/dist/cdn/chunks/{flash-cards-0NrrKdrx.js.map → flash-cards-D4ebb5m6.js.map} +1 -1
- package/dist/cdn/chunks/{gap-lor-khst.js → gap-D-Sipuyu.js} +2 -2
- package/dist/cdn/chunks/{gap-lor-khst.js.map → gap-D-Sipuyu.js.map} +1 -1
- package/dist/cdn/chunks/{help-C-woafz5.js → help-CmCFuNXk.js} +2 -2
- package/dist/cdn/chunks/{help-C-woafz5.js.map → help-CmCFuNXk.js.map} +1 -1
- package/dist/cdn/chunks/{help-form-DhIyMziw.js → help-form-Di2NtKDp.js} +2 -2
- package/dist/cdn/chunks/{help-form-DhIyMziw.js.map → help-form-Di2NtKDp.js.map} +1 -1
- package/dist/cdn/chunks/{hotspot-oel1Eelo.js → hotspot-B3bvqVzf.js} +2 -2
- package/dist/cdn/chunks/{hotspot-oel1Eelo.js.map → hotspot-B3bvqVzf.js.map} +1 -1
- package/dist/cdn/chunks/{image-drop-Dkprw0Kn.js → image-drop-vLc2B7rF.js} +2 -2
- package/dist/cdn/chunks/{image-drop-Dkprw0Kn.js.map → image-drop-vLc2B7rF.js.map} +1 -1
- package/dist/cdn/chunks/{image-label-Dm5shQSh.js → image-label-DsKxQDTQ.js} +2 -2
- package/dist/cdn/chunks/{image-label-Dm5shQSh.js.map → image-label-DsKxQDTQ.js.map} +1 -1
- package/dist/cdn/chunks/{inline-styles-CTgXWnHb.js → inline-styles-CFNlb6f2.js} +2 -2
- package/dist/cdn/chunks/{inline-styles-CTgXWnHb.js.map → inline-styles-CFNlb6f2.js.map} +1 -1
- package/dist/cdn/chunks/{insert-menu-Cn2E54V9.js → insert-menu-DAQglwtG.js} +2 -2
- package/dist/cdn/chunks/{insert-menu-Cn2E54V9.js.map → insert-menu-DAQglwtG.js.map} +1 -1
- package/dist/cdn/chunks/{issue-list-CQKAW39i.js → issue-list-CzSmohtT.js} +2 -2
- package/dist/cdn/chunks/{issue-list-CQKAW39i.js.map → issue-list-CzSmohtT.js.map} +1 -1
- package/dist/cdn/chunks/{live-jdiyYln2.js → live-qnReIRtj.js} +2 -2
- package/dist/cdn/chunks/{live-jdiyYln2.js.map → live-qnReIRtj.js.map} +1 -1
- package/dist/cdn/chunks/{long-answer-CtzClLAx.js → long-answer-NSWJiK0z.js} +2 -2
- package/dist/cdn/chunks/{long-answer-CtzClLAx.js.map → long-answer-NSWJiK0z.js.map} +1 -1
- package/dist/cdn/chunks/{mark-words-CpH3gTcX.js → mark-words-BKu-_uIl.js} +2 -2
- package/dist/cdn/chunks/{mark-words-CpH3gTcX.js.map → mark-words-BKu-_uIl.js.map} +1 -1
- package/dist/cdn/chunks/{match-DKE_4o-x.js → match-BpnJGW_5.js} +21 -13
- package/dist/cdn/chunks/match-BpnJGW_5.js.map +1 -0
- package/dist/cdn/chunks/{memory-B6hSyHyz.js → memory-BgTHujsU.js} +2 -2
- package/dist/cdn/chunks/{memory-B6hSyHyz.js.map → memory-BgTHujsU.js.map} +1 -1
- package/dist/cdn/chunks/{option-styles-WKzjKmCH.js → option-styles-B2sBX5Oz.js} +2 -2
- package/dist/cdn/chunks/{option-styles-WKzjKmCH.js.map → option-styles-B2sBX5Oz.js.map} +1 -1
- package/dist/cdn/chunks/{order-BhG_6IC-.js → order-B9gqH5wm.js} +2 -2
- package/dist/cdn/chunks/{order-BhG_6IC-.js.map → order-B9gqH5wm.js.map} +1 -1
- package/dist/cdn/chunks/{picture-view-BKnAyScQ.js → picture-view-Deodu_mb.js} +2 -2
- package/dist/cdn/chunks/{picture-view-BKnAyScQ.js.map → picture-view-Deodu_mb.js.map} +1 -1
- package/dist/cdn/chunks/{repeat-CY2W2URZ.js → repeat-BDXokpxQ.js} +2 -2
- package/dist/cdn/chunks/{repeat-CY2W2URZ.js.map → repeat-BDXokpxQ.js.map} +1 -1
- package/dist/cdn/chunks/{runtime-DxAbpr3S.js → runtime-C25QK5B0.js} +3 -3
- package/dist/cdn/chunks/{runtime-DxAbpr3S.js.map → runtime-C25QK5B0.js.map} +1 -1
- package/dist/cdn/chunks/{scan-jWgPnVxA.js → scan-BVhxT2Hw.js} +2 -2
- package/dist/cdn/chunks/{scan-jWgPnVxA.js.map → scan-BVhxT2Hw.js.map} +1 -1
- package/dist/cdn/chunks/{select-DTA3dJzr.js → select-DPpKJwSg.js} +2 -2
- package/dist/cdn/chunks/{select-DTA3dJzr.js.map → select-DPpKJwSg.js.map} +1 -1
- package/dist/cdn/chunks/select-QZ35cyns.js +2 -0
- package/dist/cdn/chunks/select-QZ35cyns.js.map +1 -0
- package/dist/cdn/chunks/{source-view-BlJ2mRns.js → source-view-gqFlZzwR.js} +2 -2
- package/dist/cdn/chunks/{source-view-BlJ2mRns.js.map → source-view-gqFlZzwR.js.map} +1 -1
- package/dist/cdn/chunks/{style-form-D1C2sHzg.js → style-form-DuR0EEum.js} +2 -2
- package/dist/cdn/chunks/{style-form-D1C2sHzg.js.map → style-form-DuR0EEum.js.map} +1 -1
- package/dist/cdn/chunks/{style-popups-BobgX1WK.js → style-popups-Bcl5imdP.js} +2 -2
- package/dist/cdn/chunks/{style-popups-BobgX1WK.js.map → style-popups-Bcl5imdP.js.map} +1 -1
- package/dist/cdn/chunks/{style-rules-ChqPVgZn.js → style-rules-ozpLz2ec.js} +2 -2
- package/dist/cdn/chunks/{style-rules-ChqPVgZn.js.map → style-rules-ozpLz2ec.js.map} +1 -1
- package/dist/cdn/chunks/{styled-Dmx5Yjv7.js → styled-bQqnDxBf.js} +2 -2
- package/dist/cdn/chunks/{styled-Dmx5Yjv7.js.map → styled-bQqnDxBf.js.map} +1 -1
- package/dist/cdn/chunks/{styles-CXkkL_Qi.js → styles-DiY3VA_T.js} +5 -5
- package/dist/cdn/chunks/styles-DiY3VA_T.js.map +1 -0
- package/dist/cdn/chunks/surface-CIz1z2oY.js +1059 -0
- package/dist/cdn/chunks/surface-CIz1z2oY.js.map +1 -0
- package/dist/cdn/chunks/{true-false-DP3MO599.js → true-false-C-S6RmZY.js} +2 -2
- package/dist/cdn/chunks/{true-false-DP3MO599.js.map → true-false-C-S6RmZY.js.map} +1 -1
- package/dist/cdn/chunks/{video-j9MCH6Kw.js → video-Dae8Gguf.js} +2 -2
- package/dist/cdn/chunks/{video-j9MCH6Kw.js.map → video-Dae8Gguf.js.map} +1 -1
- package/dist/cdn/chunks/{word-bank-ARjwUKZf.js → word-bank-CsIle0Ro.js} +2 -2
- package/dist/cdn/chunks/{word-bank-ARjwUKZf.js.map → word-bank-CsIle0Ro.js.map} +1 -1
- package/dist/cdn/chunks/{word-search-AHvM7yCJ.js → word-search-IOCwqo3y.js} +2 -2
- package/dist/cdn/chunks/{word-search-AHvM7yCJ.js.map → word-search-IOCwqo3y.js.map} +1 -1
- package/package.json +9 -9
- package/dist/cdn/chunks/match-DKE_4o-x.js.map +0 -1
- package/dist/cdn/chunks/styles-CXkkL_Qi.js.map +0 -1
- package/dist/cdn/chunks/surface-BhmSAte0.js +0 -1058
- package/dist/cdn/chunks/surface-BhmSAte0.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @astl/astrolabe
|
|
2
2
|
|
|
3
|
+
## 0.1.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [8d3dc51]
|
|
8
|
+
- @astl/tokens@0.1.4
|
|
9
|
+
- @astl/editor@0.1.4
|
|
10
|
+
- @astl/editor-tiptap@0.1.4
|
|
11
|
+
- @astl/components@0.1.4
|
|
12
|
+
- @astl/player@0.1.4
|
|
13
|
+
- @astl/server@0.1.4
|
|
14
|
+
- @astl/core@0.1.4
|
|
15
|
+
- @astl/engine@0.1.4
|
|
16
|
+
|
|
3
17
|
## 0.1.3
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{S as e,_ as t,a as n,b as r,c as i,d as a,f as o,g as s,h as c,i as l,l as u,m as d,n as f,o as p,p as m,r as ee,s as te,t as h,u as ne,v as re,w as ie,x as ae,y as oe}from"./chunks/definitions-CNX90WtL.js";import{$ as se,$t as ce,A as le,At as ue,B as de,Bt as fe,C as g,Ct as pe,D as me,Dt as he,E as _,Et as ge,F as _e,Ft as ve,G as ye,Gt as be,H as xe,Ht as Se,I as Ce,It as we,J as Te,Jt as Ee,K as v,Kt as De,L as Oe,Lt as ke,M as y,Mt as Ae,N as je,Nt as Me,O as Ne,Ot as Pe,P as Fe,Pt as b,Q as Ie,Qt as Le,R as Re,Rt as ze,Sn as Be,St as Ve,T as x,Tt as He,U as Ue,Ut as We,V as Ge,Vt as Ke,W as qe,Wt as Je,X as Ye,Xt as Xe,Y as Ze,Yt as Qe,Z as $e,Zt as et,_n as tt,_t as nt,a as rt,an as it,at,b as S,bn as ot,bt as st,cn as ct,ct as lt,dn as ut,dt,en as ft,et as pt,fn as mt,ft as ht,gn as gt,gt as _t,hn as vt,ht as yt,in as bt,it as xt,j as St,jt as C,k as Ct,kt as wt,ln as Tt,lt as Et,mn as Dt,mt as Ot,nn as kt,nt as At,on as jt,ot as Mt,pn as Nt,pt as Pt,q as Ft,qt as It,rn as Lt,rt as Rt,sn as zt,st as Bt,tn as Vt,tt as Ht,un as Ut,ut as Wt,v as w,vn as Gt,vt as Kt,wt as qt,xn as Jt,xt as Yt,y as Xt,yn as Zt,yt as Qt,z as $t,zt as en}from"./chunks/runtime-DxAbpr3S.js";import{r as tn}from"./chunks/audio-manifest-B9FWQzRy.js";import{r as nn}from"./chunks/callout-manifest-Cb12O4jl.js";import{r as rn}from"./chunks/categorise-manifest-C_hEDVYQ.js";import{r as an}from"./chunks/choice-manifest-C-XahD7m.js";import{r as on}from"./chunks/crossword-manifest-2qlu7AYd.js";import{r as sn}from"./chunks/drop-manifest-bzNOa5ks.js";import{r as cn}from"./chunks/flash-cards-manifest-B8nWXbRy.js";import{r as ln}from"./chunks/gap-manifest-RSydA41N.js";import{r as un}from"./chunks/hotspot-manifest-CNs1oiZ_.js";import{r as dn}from"./chunks/image-drop-manifest-BZ6hCoAd.js";import{r as fn}from"./chunks/image-label-manifest--1CLRJzd.js";import{r as pn}from"./chunks/long-answer-manifest-BYJpZRtB.js";import{r as mn}from"./chunks/mark-words-manifest-Cs2pXCEx.js";import{r as hn}from"./chunks/match-manifest-D0UfoajU.js";import{r as gn}from"./chunks/memory-manifest-D1589iR0.js";import{r as _n}from"./chunks/order-manifest-J5IXN0he.js";import{r as vn}from"./chunks/select-manifest-BBMbvdkH.js";import{r as yn}from"./chunks/true-false-manifest-B4exv60u.js";import{r as bn}from"./chunks/video-manifest-8OwkhhAI.js";import{r as xn}from"./chunks/word-bank-manifest-C1FSo1kH.js";import{o as Sn}from"./chunks/word-search-manifest-Fg1a59Z1.js";import{d as Cn,n as wn,r as Tn,s as En,u as Dn}from"./chunks/scan-jWgPnVxA.js";import{a as On,c as kn,d as An,f as T,i as E,l as jn,n as D,o as O,r as Mn,s as Nn,t as Pn}from"./chunks/insert-menu-Cn2E54V9.js";import{n as Fn,t as k}from"./chunks/messages-Qzse5KMX.js";import{n as In,s as Ln,t as Rn}from"./chunks/style-model-ZXNe_c8R.js";import{n as A,r as j,t as M}from"./chunks/styles-CXkkL_Qi.js";import{c as zn,r as Bn,s as Vn}from"./chunks/directive-helpers-D7lOZKnB.js";import{t as N}from"./chunks/live-jdiyYln2.js";import{i as Hn,n as Un,r as Wn,t as Gn}from"./chunks/issue-list-CQKAW39i.js";import{t as Kn}from"./chunks/roving-focus-BxGgi2DD.js";var qn={manifest:tn,messages:e,label:`editor.label`,description:`editor.description`,icon:`speaker-high`,idPrefix:`audio`,template:`<astl-audio id="{{id}}" label="{{t:template.label}}"><astl-transcript>{{t:template.transcript}}</astl-transcript></astl-audio>`,fields:[{kind:`attribute`,name:`label`,label:`editor.title`,help:`editor.titleHelp`},{kind:`attribute`,name:`src`,label:`editor.src`,help:`editor.srcHelp`,accept:`audio/*`},{kind:`text-list`,tag:`astl-transcript`,label:`editor.transcript`,help:`editor.transcriptHelp`,multiline:!0}]},Jn={manifest:nn,messages:ae,label:`editor.label`,description:`editor.description`,icon:`info`,idPrefix:`callout`,template:`<astl-callout id="{{id}}" kind="tip"><p>{{t:template.text}}</p></astl-callout>`,fields:[{kind:`attribute`,name:`kind`,label:`editor.kind`}]},Yn={manifest:rn,messages:r,label:`editor.label`,description:`editor.description`,icon:`kanban`,idPrefix:`cat`,template:`<astl-categorise id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-category id="a">{{t:template.categoryA}}</astl-category><astl-category id="b">{{t:template.categoryB}}</astl-category><astl-card id="a1" category="a">{{t:template.cardA1}}</astl-card><astl-card id="a2" category="a">{{t:template.cardA2}}</astl-card><astl-card id="b1" category="b">{{t:template.cardB1}}</astl-card><astl-card id="b2" category="b">{{t:template.cardB2}}</astl-card></astl-categorise>`,templates:[{id:`sort-into-groups`,label:`template.sort.label`,description:`template.sort.description`,template:`<h3>{{t:template.sort.heading}}</h3><p>{{t:template.sort.instruction}}</p><astl-categorise id="{{id}}"><astl-prompt>{{t:template.sort.prompt}}</astl-prompt><astl-category id="a">{{t:template.sort.groupA}}</astl-category><astl-category id="b">{{t:template.sort.groupB}}</astl-category><astl-card id="a1" category="a">{{t:template.sort.card1}}</astl-card><astl-card id="b1" category="b">{{t:template.sort.card2}}</astl-card><astl-card id="a2" category="a">{{t:template.sort.card3}}</astl-card><astl-card id="b2" category="b">{{t:template.sort.card4}}</astl-card></astl-categorise>`}],fields:[{kind:`child-choice`,tag:`astl-card`,attribute:`category`,options:`astl-category`,label:`editor.cardCategories`,help:`editor.cardCategoriesHelp`},{kind:`child-table`,tag:`astl-category`,columns:[{attribute:`palette`,label:`editor.palette`}],label:`editor.groups`,help:`editor.groupsHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},Xn={manifest:an,messages:oe,label:`editor.label`,description:`editor.description`,icon:`list-checks`,idPrefix:`choice`,template:`<astl-choice id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-option id="a" correct>{{t:template.option1}}</astl-option><astl-option id="b">{{t:template.option2}}</astl-option><astl-option id="c">{{t:template.option3}}</astl-option></astl-choice>`,templates:[{id:`multiple-choice`,label:`template.choice.label`,description:`template.choice.description`,template:`<h3>{{t:template.choice.heading}}</h3><p>{{t:template.choice.instruction}}</p><astl-choice id="{{id}}"><astl-prompt>{{t:template.choice.prompt}}</astl-prompt><astl-option id="a">{{t:template.choice.option1}}</astl-option><astl-option id="b" correct>{{t:template.choice.option2}}</astl-option><astl-option id="c">{{t:template.choice.option3}}</astl-option></astl-choice>`}],fields:[{kind:`child-flag`,tag:`astl-option`,attribute:`correct`,label:`editor.correctOptions`},{kind:`attribute`,name:`multiple`,label:`editor.multiple`},{kind:`attribute`,name:`shuffle`,label:`editor.shuffle`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},Zn=e=>`<astl-crossword id="{{id}}" rows="5" columns="5">${e}<astl-crossword-word id="w1" answer="{{t:template.crossword.across}}" row="0" column="0" direction="across">{{t:template.crossword.acrossClue}}</astl-crossword-word><astl-crossword-word id="w2" answer="{{t:template.crossword.down}}" row="0" column="0" direction="down">{{t:template.crossword.downClue}}</astl-crossword-word></astl-crossword>`,Qn={manifest:on,messages:re,label:`editor.label`,description:`editor.description`,icon:`grid-four`,idPrefix:`crossword`,template:Zn(`<astl-prompt>{{t:template.crossword.prompt}}</astl-prompt>`),templates:[{id:`crossword`,label:`template.crossword`,description:`template.crossword.description`,template:`<h3>{{t:template.crossword.heading}}</h3><p>{{t:template.crossword.prompt}}</p>${Zn(``)}`}],fields:[{kind:`attribute`,name:`rows`,label:`editor.rows`},{kind:`attribute`,name:`columns`,label:`editor.columns`},{kind:`child-table`,tag:`astl-crossword-word`,label:`editor.words`,help:`editor.wordsHelp`,columns:[{attribute:`answer`,label:`editor.answer`},{attribute:`row`,label:`editor.row`},{attribute:`column`,label:`editor.column`},{attribute:`direction`,label:`editor.direction`}]},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},$n={manifest:sn,messages:t,label:`editor.label`,description:`editor.description`,icon:`arrow-square-in`,idPrefix:`drop`,template:`<astl-drop id="{{id}}" answer="a" bank=""></astl-drop>`,companion:{tag:`astl-word-bank`,attribute:`bank`},fields:[{kind:`attribute`,name:`answer`,label:`editor.answer`,help:`editor.answerHelp`,options:{from:`bank`,tag:`astl-word`}},{kind:`attribute`,name:`bank`,label:`editor.bank`,help:`editor.bankHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},er=`https://assets.example.org/flash-cards/`,P=(e,t)=>`<astl-front>${e}</astl-front><astl-back>{{t:template.cards.${t}}}</astl-back>`,tr=e=>`<img src="${er}${e}.svg" alt="{{t:template.cards.${e}}}" width="96" height="96">`,nr={manifest:cn,messages:s,label:`editor.label`,description:`editor.description`,icon:`cards`,idPrefix:`cards`,template:`<astl-flash-cards id="{{id}}"><astl-front>{{t:template.front}}</astl-front><astl-back>{{t:template.back}}</astl-back></astl-flash-cards>`,templates:[{id:`flash-cards`,label:`editor.template.cards`,description:`editor.template.cards.description`,template:`<h3>{{t:template.cards.title}}</h3><p>{{t:template.cards.instruction}}</p><astl-flash-cards id="{{id}}">`+P(tr(`sun`),`sunBack`)+P(tr(`moon`),`moonBack`)+P(`{{t:template.cards.mars}}`,`marsBack`)+P(`{{t:template.cards.saturn}}`,`saturnBack`)+`</astl-flash-cards>`}],fields:[{kind:`text-list`,tag:`astl-back`,label:`editor.backs`,help:`editor.backsHelp`}]},rr={manifest:ln,messages:c,label:`editor.label`,description:`editor.description`,icon:`text-t`,idPrefix:`gap`,template:`<astl-gap id="{{id}}" answer="{{selection}}"></astl-gap>`,templates:[{id:`fill-the-gaps`,label:`template.fill.label`,description:`template.fill.description`,template:`<h3>{{t:template.fill.heading}}</h3><p>{{t:template.fill.instruction}}</p><p>{{t:template.fill.start}} <astl-gap id="{{id}}" answer="{{t:template.fill.answer1}}"></astl-gap> {{t:template.fill.middle}} <astl-gap answer="{{t:template.fill.answer2}}"></astl-gap>{{t:template.fill.end}}</p>`}],fields:[{kind:`attribute`,name:`answer`,label:`editor.answer`},{kind:`text-list`,tag:`astl-alt`,label:`editor.alternatives`,help:`editor.alternativesHelp`},{kind:`attribute`,name:`type`,label:`editor.type`},{kind:`attribute`,name:`case`,label:`editor.case`},{kind:`attribute`,name:`marks`,label:`editor.marks`,help:`editor.marksHelp`},{kind:`attribute`,name:`tolerance`,label:`editor.tolerance`},{kind:`attribute`,name:`width`,label:`editor.width`},{kind:`attribute`,name:`points`,label:`editor.points`}]},ir={manifest:un,messages:d,label:`editor.label`,description:`editor.description`,icon:`crosshair`,idPrefix:`hotspot`,template:`<astl-hotspot id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-hotspot-region id="r1" x="5" y="10" width="40" height="80" label="{{t:template.place1}}" correct></astl-hotspot-region><astl-hotspot-region id="r2" x="55" y="10" width="40" height="80" label="{{t:template.place2}}"></astl-hotspot-region></astl-hotspot>`,templates:[{id:`find-it-in-the-picture`,label:`template.find.label`,description:`template.find.description`,template:`<h3>{{t:template.find.heading}}</h3><p>{{t:template.find.instruction}}</p><astl-hotspot id="{{id}}" multiple><astl-prompt>{{t:template.find.prompt}}</astl-prompt><astl-hotspot-region id="r1" x="4" y="6" width="22" height="26" label="{{t:template.find.topLeft}}" correct></astl-hotspot-region><astl-hotspot-region id="r2" shape="circle" x="85" y="18" r="10" label="{{t:template.find.topRight}}"></astl-hotspot-region><astl-hotspot-region id="r3" shape="circle" x="50" y="50" r="12" label="{{t:template.find.centre}}" correct></astl-hotspot-region><astl-hotspot-region id="r4" shape="circle" x="15" y="82" r="10" label="{{t:template.find.bottomLeft}}"></astl-hotspot-region><astl-hotspot-region id="r5" x="74" y="68" width="22" height="26" label="{{t:template.find.bottomRight}}" correct></astl-hotspot-region></astl-hotspot>`}],fields:[{kind:`picture-regions`,tag:`astl-hotspot-region`,src:`src`,label:`editor.regions`,help:`editor.regionsHelp`},{kind:`attribute`,name:`alt`,label:`editor.alt`,help:`editor.altHelp`},{kind:`child-flag`,tag:`astl-hotspot-region`,attribute:`correct`,label:`editor.correct`,help:`editor.correctHelp`},{kind:`attribute`,name:`multiple`,label:`editor.multiple`},{kind:`attribute`,name:`outline`,label:`editor.outline`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},ar={manifest:dn,messages:m,label:`editor.label`,description:`editor.description`,icon:`tag`,idPrefix:`image-drop`,template:`<astl-image-drop id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-image-drop-zone id="z1" x="10" y="35" width="30" height="30" answer="l1"></astl-image-drop-zone><astl-image-drop-zone id="z2" x="60" y="35" width="30" height="30" answer="l2"></astl-image-drop-zone><astl-image-drop-label id="l1">{{t:template.label1}}</astl-image-drop-label><astl-image-drop-label id="l2">{{t:template.label2}}</astl-image-drop-label></astl-image-drop>`,templates:[{id:`drag-labels-onto-the-picture`,label:`template.drag.label`,description:`template.drag.description`,template:`<h3>{{t:template.drag.heading}}</h3><p>{{t:template.drag.instruction}}</p><astl-image-drop id="{{id}}"><astl-prompt>{{t:template.drag.prompt}}</astl-prompt><astl-image-drop-zone id="z1" x="20" y="5" width="60" height="25" answer="l1"></astl-image-drop-zone><astl-image-drop-zone id="z2" x="20" y="37.5" width="60" height="25" answer="l2"></astl-image-drop-zone><astl-image-drop-zone id="z3" x="20" y="70" width="60" height="25" answer="l3"></astl-image-drop-zone><astl-image-drop-label id="l1">{{t:template.drag.label1}}</astl-image-drop-label><astl-image-drop-label id="l2">{{t:template.drag.label2}}</astl-image-drop-label><astl-image-drop-label id="l3">{{t:template.drag.label3}}</astl-image-drop-label><astl-image-drop-label id="l4">{{t:template.drag.label4}}</astl-image-drop-label></astl-image-drop>`}],fields:[{kind:`picture-regions`,tag:`astl-image-drop-zone`,src:`src`,label:`editor.zones`,help:`editor.zonesHelp`},{kind:`attribute`,name:`alt`,label:`editor.alt`,help:`editor.altHelp`},{kind:`child-choice`,tag:`astl-image-drop-zone`,attribute:`answer`,options:`astl-image-drop-label`,label:`editor.answers`,help:`editor.answersHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},or={manifest:fn,messages:o,label:`editor.label`,description:`editor.description`,icon:`map-pin`,idPrefix:`image-label`,template:`<astl-image-label id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-image-label-pin id="p1" x="30" y="50" label="{{t:template.answer1}}"></astl-image-label-pin><astl-image-label-pin id="p2" x="70" y="50" label="{{t:template.answer2}}"></astl-image-label-pin></astl-image-label>`,templates:[{id:`label-the-picture`,label:`template.label.label`,description:`template.label.description`,template:`<h3>{{t:template.label.heading}}</h3><p>{{t:template.label.instruction}}</p><astl-image-label id="{{id}}"><astl-prompt>{{t:template.label.prompt}}</astl-prompt><astl-image-label-pin id="p1" x="50" y="15" label="{{t:template.label.top}}"></astl-image-label-pin><astl-image-label-pin id="p2" x="50" y="50" label="{{t:template.label.centre}}" alternatives="{{t:template.label.centreAlternative}}"></astl-image-label-pin><astl-image-label-pin id="p3" x="50" y="85" label="{{t:template.label.bottom}}"></astl-image-label-pin></astl-image-label>`}],fields:[{kind:`picture-points`,tag:`astl-image-label-pin`,src:`src`,label:`editor.pins`,help:`editor.pinsHelp`},{kind:`attribute`,name:`alt`,label:`editor.alt`,help:`editor.altHelp`},{kind:`child-text`,tag:`astl-image-label-pin`,attribute:`alternatives`,label:`editor.alternatives`,help:`editor.alternativesHelp`},{kind:`attribute`,name:`case`,label:`editor.case`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},sr={manifest:pn,messages:a,label:`editor.label`,description:`editor.description`,icon:`note-pencil`,idPrefix:`answer`,template:`<astl-long-answer id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt></astl-long-answer>`,templates:[{id:`write-your-answer`,label:`editor.template.write`,description:`editor.template.write.description`,template:`<h3>{{t:template.write.title}}</h3><p>{{t:template.write.instruction}}</p><astl-long-answer id="{{id}}" rows="6" minlength="100" maxlength="800" placeholder="{{t:template.write.placeholder}}"><astl-prompt>{{t:template.write.question}}</astl-prompt></astl-long-answer>`}],fields:[{kind:`attribute`,name:`rows`,label:`editor.rows`,help:`editor.rowsHelp`},{kind:`attribute`,name:`minlength`,label:`editor.minlength`,help:`editor.minlengthHelp`},{kind:`attribute`,name:`maxlength`,label:`editor.maxlength`,help:`editor.maxlengthHelp`},{kind:`attribute`,name:`placeholder`,label:`editor.placeholder`}]},F=(e,t,n=!1)=>`<astl-mark-word id="${e}"${n?` correct`:``}>{{t:template.${t}}}</astl-mark-word>`,I=(e,t)=>`<p>${[1,2,3,4].map(n=>F(`${e}${n}`,`odd.${e}${n}`,n===t)).join(` `)}</p>`,cr={manifest:mn,messages:ne,label:`editor.label`,description:`editor.description`,icon:`highlighter`,idPrefix:`mark-words`,template:`<astl-mark-words id="{{id}}"><p>{{t:template.before}} ${F(`w1`,`word`,!0)} {{t:template.after}}</p></astl-mark-words>`,templates:[{id:`select-words`,label:`template.select.label`,description:`template.select.description`,template:`<h3>{{t:template.select.heading}}</h3><p>{{t:template.select.instruction}}</p><astl-mark-words id="{{id}}"><astl-prompt>{{t:template.select.prompt}}</astl-prompt><p>{{t:template.select.before}} ${F(`w1`,`select.word1`,!0)} {{t:template.select.middle}} ${F(`w2`,`select.word2`)} {{t:template.select.and}} ${F(`w3`,`select.word3`,!0)} {{t:template.select.after}}</p></astl-mark-words>`},{id:`odd-word`,label:`template.odd.label`,description:`template.odd.description`,icon:`strikethrough`,template:`<h3>{{t:template.odd.heading}}</h3><p>{{t:template.odd.instruction}}</p><astl-mark-words id="{{id}}" variant="strike"><astl-prompt>{{t:template.odd.prompt}}</astl-prompt>${I(`a`,3)}${I(`b`,4)}${I(`c`,2)}</astl-mark-words>`}],fields:[{kind:`attribute`,name:`variant`,label:`editor.variant`},{kind:`child-flag`,tag:`astl-mark-word`,attribute:`correct`,label:`editor.correct`,help:`editor.correctHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}],wrap:{label:`editor.wrap`,child:`astl-mark-word`,attributes:{correct:``}}},lr=(e,t,n)=>`<astl-match id="{{id}}"${t}>${n}`+[`1`,`2`,`3`].map((t,n)=>`<astl-row id="r${t}" column="${`abc`[n]}">{{t:template.${e}.row${t}}}</astl-row>`).join(``)+[`A`,`B`,`C`].map(t=>`<astl-column id="${t.toLowerCase()}">{{t:template.${e}.column${t}}}</astl-column>`).join(``)+`</astl-match>`,ur=(e,t=``)=>`<h3>{{t:template.${e}.heading}}</h3><p>{{t:template.${e}.prompt}}</p>${lr(e,t,``)}`,dr={manifest:hn,messages:u,label:`editor.label`,description:`editor.description`,icon:`arrows-left-right`,idPrefix:`match`,template:lr(`matching`,``,`<astl-prompt>{{t:template.matching.prompt}}</astl-prompt>`),templates:[{id:`matching`,label:`template.matching`,description:`template.matching.description`,template:ur(`matching`)},{id:`join-the-lines`,label:`template.lines`,description:`template.lines.description`,template:ur(`lines`,` variant="lines"`)}],fields:[{kind:`child-choice`,tag:`astl-row`,attribute:`column`,options:`astl-column`,label:`editor.answers`,help:`editor.answersHelp`},{kind:`attribute`,name:`variant`,label:`editor.layout`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},fr=e=>`<astl-memory id="{{id}}">${e}`+[`1`,`2`,`3`].map(e=>`<astl-card-a id="a${e}">{{t:template.memory.a${e}}}</astl-card-a><astl-card-b id="b${e}" pair="a${e}">{{t:template.memory.b${e}}}</astl-card-b>`).join(``)+`</astl-memory>`,pr={manifest:gn,messages:i,label:`editor.label`,description:`editor.description`,icon:`cards`,idPrefix:`memory`,template:fr(`<astl-prompt>{{t:template.memory.prompt}}</astl-prompt>`),templates:[{id:`memory`,label:`template.memory`,description:`template.memory.description`,template:`<h3>{{t:template.memory.heading}}</h3><p>{{t:template.memory.prompt}}</p>${fr(``)}`}],fields:[{kind:`child-choice`,tag:`astl-card-b`,attribute:`pair`,options:`astl-card-a`,label:`editor.pairs`,help:`editor.pairsHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},mr={manifest:_n,messages:te,label:`editor.label`,description:`editor.description`,icon:`list-numbers`,idPrefix:`order`,template:`<astl-order id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-item id="a">{{t:template.item1}}</astl-item><astl-item id="b">{{t:template.item2}}</astl-item><astl-item id="c">{{t:template.item3}}</astl-item></astl-order>`,templates:[{id:`ordering`,label:`template.cycle.label`,description:`template.cycle.description`,template:`<h3>{{t:template.cycle.heading}}</h3><p>{{t:template.cycle.instruction}}</p><astl-order id="{{id}}"><astl-prompt>{{t:template.cycle.prompt}}</astl-prompt><astl-item id="a">{{t:template.cycle.item1}}</astl-item><astl-item id="b">{{t:template.cycle.item2}}</astl-item><astl-item id="c">{{t:template.cycle.item3}}</astl-item><astl-item id="d">{{t:template.cycle.item4}}</astl-item></astl-order>`}],fields:[{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`variant`,label:`editor.variant`,help:`editor.variantHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},hr={manifest:vn,messages:p,label:`editor.label`,description:`editor.description`,icon:`caret-circle-down`,idPrefix:`select`,template:`<astl-select id="{{id}}"><astl-option id="a" correct>{{t:template.option1}}</astl-option><astl-option id="b">{{t:template.option2}}</astl-option><astl-option id="c">{{t:template.option3}}</astl-option></astl-select>`,templates:[{id:`choose-from-a-list`,label:`template.list.label`,description:`template.list.description`,template:`<h3>{{t:template.list.heading}}</h3><p>{{t:template.list.instruction}}</p><p>{{t:template.list.start}} <astl-select id="{{id}}"><astl-option id="a">{{t:template.list.option1}}</astl-option><astl-option id="b" correct>{{t:template.list.option2}}</astl-option><astl-option id="c">{{t:template.list.option3}}</astl-option></astl-select>{{t:template.list.end}}</p>`},{id:`click-the-right-word`,label:`template.click.label`,description:`template.click.description`,template:`<h3>{{t:template.click.heading}}</h3><p>{{t:template.click.instruction}}</p><p>{{t:template.click.start1}} <astl-select id="{{id}}" variant="buttons"><astl-option id="a">{{t:template.click.option1a}}</astl-option><astl-option id="b" correct>{{t:template.click.option1b}}</astl-option><astl-option id="c">{{t:template.click.option1c}}</astl-option></astl-select>{{t:template.click.end}}</p><p>{{t:template.click.start2}} <astl-select variant="buttons"><astl-option id="a">{{t:template.click.option2a}}</astl-option><astl-option id="b" correct>{{t:template.click.option2b}}</astl-option></astl-select>{{t:template.click.end}}</p>`}],fields:[{kind:`child-flag`,tag:`astl-option`,attribute:`correct`,label:`editor.correctOption`,help:`editor.correctOptionHelp`},{kind:`attribute`,name:`shuffle`,label:`editor.shuffle`},{kind:`attribute`,name:`points`,label:`editor.points`},{kind:`attribute`,name:`variant`,label:`editor.variant`},{kind:`attribute`,name:`native`,label:`editor.native`,help:`editor.nativeHelp`,variants:[`dropdown`]}]},gr={manifest:yn,messages:n,label:`editor.label`,description:`editor.description`,icon:`toggle-left`,idPrefix:`tf`,template:`<astl-true-false id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-statement id="s1" answer="true">{{t:template.statement1}}</astl-statement><astl-statement id="s2" answer="false">{{t:template.statement2}}</astl-statement></astl-true-false>`,templates:[{id:`true-or-false`,label:`template.tf.label`,description:`template.tf.description`,template:`<h3>{{t:template.tf.heading}}</h3><p>{{t:template.tf.instruction}}</p><astl-true-false id="{{id}}"><astl-statement id="s1" answer="true">{{t:template.tf.statement1}}</astl-statement><astl-statement id="s2" answer="false">{{t:template.tf.statement2}}</astl-statement><astl-statement id="s3" answer="true">{{t:template.tf.statement3}}</astl-statement></astl-true-false>`}],fields:[{kind:`child-choice`,tag:`astl-statement`,attribute:`answer`,label:`editor.answers`},{kind:`attribute`,name:`true-label`,label:`editor.trueLabel`,help:`editor.labelsHelp`},{kind:`attribute`,name:`false-label`,label:`editor.falseLabel`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},_r={manifest:bn,messages:l,label:`editor.label`,description:`editor.description`,icon:`film-strip`,idPrefix:`video`,template:`<astl-video id="{{id}}" label="{{t:template.label}}"></astl-video>`,templates:[{id:`watch-then-answer`,label:`editor.template.watch`,description:`editor.template.watch.description`,template:`<h3>{{t:template.watch.title}}</h3><p>{{t:template.watch.instruction}}</p><astl-callout kind="tip"><p>{{t:template.watch.tip}}</p></astl-callout><astl-video id="{{id}}" label="{{t:template.watch.label}}" youtube="https://youtu.be/Bq7mT2kWx4E"></astl-video><p>{{t:template.watch.sentence}} <astl-gap answer="{{t:template.watch.gap}}"></astl-gap>.</p>`}],fields:[{kind:`attribute`,name:`label`,label:`editor.title`,help:`editor.titleHelp`},{kind:`attribute`,name:`youtube`,label:`editor.youtube`,help:`editor.youtubeHelp`},{kind:`attribute`,name:`vimeo`,label:`editor.vimeo`,help:`editor.vimeoHelp`},{kind:`attribute`,name:`src`,label:`editor.src`,help:`editor.srcHelp`,accept:`video/mp4,video/webm`},{kind:`attribute`,name:`poster`,label:`editor.poster`,help:`editor.posterHelp`,accept:`image/*`},{kind:`attribute`,name:`captions`,label:`editor.captions`,help:`editor.captionsHelp`,accept:`.vtt,text/vtt`},{kind:`attribute`,name:`captions-lang`,label:`editor.captionsLang`,help:`editor.captionsLangHelp`}]},vr={manifest:xn,messages:ee,label:`editor.label`,description:`editor.description`,icon:`cards`,idPrefix:`bank`,template:`<astl-word-bank id="{{id}}"><astl-word id="a">{{t:template.word1}}</astl-word><astl-word id="b">{{t:template.word2}}</astl-word><astl-word id="c" distractor>{{t:template.word3}}</astl-word></astl-word-bank>`,templates:[{id:`drag-words`,label:`editor.template.dragWords`,description:`editor.template.dragWords.description`,template:`<h3>{{t:template.dragWords.heading}}</h3><p>{{t:template.dragWords.instruction}}</p><astl-word-bank id="{{id}}"><astl-word id="a">{{t:template.dragWords.answer1}}</astl-word><astl-word id="b">{{t:template.dragWords.answer2}}</astl-word><astl-word id="c" distractor>{{t:template.dragWords.distractor}}</astl-word></astl-word-bank><p>{{t:template.dragWords.start}} <astl-drop answer="a"></astl-drop>{{t:template.dragWords.middle}} <astl-drop answer="b"></astl-drop>{{t:template.dragWords.end}}</p>`}],fields:[{kind:`child-flag`,tag:`astl-word`,attribute:`distractor`,label:`editor.distractors`,help:`editor.distractorsHelp`},{kind:`attribute`,name:`reuse`,label:`editor.reuse`,help:`editor.reuseHelp`}]},yr=[`right`,`down`,`down-right`,`left`,`up`,`up-left`,`down-left`,`up-right`],br=`<astl-word-search id="{{id}}" right down down-right>`,xr=[1,2,3].map(e=>`<astl-search-word id="w${e}">{{t:template.word${e}}}</astl-search-word>`).join(``),Sr=[rr,Xn,hr,gr,mr,Yn,dr,vr,$n,{manifest:Sn,messages:f,label:`editor.label`,description:`editor.description`,icon:`magnifying-glass`,idPrefix:`word-search`,template:`${br}<astl-prompt>{{t:template.instruction}}</astl-prompt>${xr}</astl-word-search>`,templates:[{id:`word-search`,label:`editor.template.wordSearch`,description:`editor.template.wordSearch.description`,template:`<h3>{{t:template.title}}</h3><p>{{t:template.instruction}}</p>${br}${xr}</astl-word-search>`}],fields:[{kind:`child-text`,tag:`astl-search-word`,attribute:`word`,label:`editor.words`,help:`editor.wordsHelp`},{kind:`attribute`,name:`size`,label:`editor.size`,help:`editor.sizeHelp`},...yr.map(e=>({kind:`attribute`,name:e,label:`editor.${e}`,...e===`right`?{help:`editor.rightHelp`}:{}})),{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},pr,Qn,nr,sr,cr,Jn,ir,ar,or,_r,qn],Cr={moveUp:x`<path d="M10 16V4M5 9l5-5 5 5"/>`,moveDown:x`<path d="M10 4v12M5 11l5 5 5-5"/>`,delete:x`<path d="M4 6h12M8 6V4h4v2M6 6l.8 10h6.4L14 6M9 9v4M11 9v4"/>`},wr=e=>e.kind===`attribute`&&e.control!==`checkbox`&&(e.control!==`text`||e.accept===null),L=e=>e.target.value,Tr=e=>e.target.checked,Er=class extends j{static styles=[A,M(`astl-picture-field, astl-style-form, astl-help-form`),_`
|
|
1
|
+
import{S as e,_ as t,a as n,b as r,c as i,d as a,f as o,g as s,h as c,i as l,l as u,m as d,n as f,o as p,p as m,r as ee,s as te,t as h,u as ne,v as re,w as ie,x as ae,y as oe}from"./chunks/definitions-BybSa1mq.js";import{$ as se,$t as ce,A as le,At as ue,B as de,Bt as fe,C as g,Ct as pe,D as me,Dt as he,E as _,Et as ge,F as _e,Ft as ve,G as ye,Gt as be,H as xe,Ht as Se,I as Ce,It as we,J as Te,Jt as Ee,K as v,Kt as De,L as Oe,Lt as ke,M as y,Mt as Ae,N as je,Nt as Me,O as Ne,Ot as Pe,P as Fe,Pt as b,Q as Ie,Qt as Le,R as Re,Rt as ze,Sn as Be,St as Ve,T as x,Tt as He,U as Ue,Ut as We,V as Ge,Vt as Ke,W as qe,Wt as Je,X as Ye,Xt as Xe,Y as Ze,Yt as Qe,Z as $e,Zt as et,_n as tt,_t as nt,a as rt,an as it,at,b as S,bn as ot,bt as st,cn as ct,ct as lt,dn as ut,dt,en as ft,et as pt,fn as mt,ft as ht,gn as gt,gt as _t,hn as vt,ht as yt,in as bt,it as xt,j as St,jt as C,k as Ct,kt as wt,ln as Tt,lt as Et,mn as Dt,mt as Ot,nn as kt,nt as At,on as jt,ot as Mt,pn as Nt,pt as Pt,q as Ft,qt as It,rn as Lt,rt as Rt,sn as zt,st as Bt,tn as Vt,tt as Ht,un as Ut,ut as Wt,v as w,vn as Gt,vt as Kt,wt as qt,xn as Jt,xt as Yt,y as Xt,yn as Zt,yt as Qt,z as $t,zt as en}from"./chunks/runtime-C25QK5B0.js";import{r as tn}from"./chunks/audio-manifest-B9FWQzRy.js";import{r as nn}from"./chunks/callout-manifest-Cb12O4jl.js";import{r as rn}from"./chunks/categorise-manifest-C_hEDVYQ.js";import{r as an}from"./chunks/choice-manifest-C-XahD7m.js";import{r as on}from"./chunks/crossword-manifest-2qlu7AYd.js";import{r as sn}from"./chunks/drop-manifest-bzNOa5ks.js";import{r as cn}from"./chunks/flash-cards-manifest-B8nWXbRy.js";import{r as ln}from"./chunks/gap-manifest-RSydA41N.js";import{r as un}from"./chunks/hotspot-manifest-CNs1oiZ_.js";import{r as dn}from"./chunks/image-drop-manifest-BZ6hCoAd.js";import{r as fn}from"./chunks/image-label-manifest--1CLRJzd.js";import{r as pn}from"./chunks/long-answer-manifest-BYJpZRtB.js";import{r as mn}from"./chunks/mark-words-manifest-Cs2pXCEx.js";import{r as hn}from"./chunks/match-manifest-D0UfoajU.js";import{r as gn}from"./chunks/memory-manifest-D1589iR0.js";import{r as _n}from"./chunks/order-manifest-J5IXN0he.js";import{r as vn}from"./chunks/select-manifest-BBMbvdkH.js";import{r as yn}from"./chunks/true-false-manifest-B4exv60u.js";import{r as bn}from"./chunks/video-manifest-8OwkhhAI.js";import{r as xn}from"./chunks/word-bank-manifest-C1FSo1kH.js";import{o as Sn}from"./chunks/word-search-manifest-Fg1a59Z1.js";import{d as Cn,n as wn,r as Tn,s as En,u as Dn}from"./chunks/scan-BVhxT2Hw.js";import{a as On,c as kn,d as An,f as T,i as E,l as jn,n as D,o as O,r as Mn,s as Nn,t as Pn}from"./chunks/insert-menu-DAQglwtG.js";import{n as Fn,t as k}from"./chunks/messages-Qzse5KMX.js";import{n as In,s as Ln,t as Rn}from"./chunks/style-model-ZXNe_c8R.js";import{n as A,r as j,t as M}from"./chunks/styles-DiY3VA_T.js";import{c as zn,r as Bn,s as Vn}from"./chunks/directive-helpers-US6zRjJ1.js";import{t as N}from"./chunks/live-qnReIRtj.js";import{i as Hn,n as Un,r as Wn,t as Gn}from"./chunks/issue-list-CzSmohtT.js";import{t as Kn}from"./chunks/roving-focus-BxGgi2DD.js";var qn={manifest:tn,messages:e,label:`editor.label`,description:`editor.description`,icon:`speaker-high`,idPrefix:`audio`,template:`<astl-audio id="{{id}}" label="{{t:template.label}}"><astl-transcript>{{t:template.transcript}}</astl-transcript></astl-audio>`,fields:[{kind:`attribute`,name:`label`,label:`editor.title`,help:`editor.titleHelp`},{kind:`attribute`,name:`src`,label:`editor.src`,help:`editor.srcHelp`,accept:`audio/*`},{kind:`text-list`,tag:`astl-transcript`,label:`editor.transcript`,help:`editor.transcriptHelp`,multiline:!0}]},Jn={manifest:nn,messages:ae,label:`editor.label`,description:`editor.description`,icon:`info`,idPrefix:`callout`,template:`<astl-callout id="{{id}}" kind="tip"><p>{{t:template.text}}</p></astl-callout>`,fields:[{kind:`attribute`,name:`kind`,label:`editor.kind`}]},Yn={manifest:rn,messages:r,label:`editor.label`,description:`editor.description`,icon:`kanban`,idPrefix:`cat`,template:`<astl-categorise id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-category id="a">{{t:template.categoryA}}</astl-category><astl-category id="b">{{t:template.categoryB}}</astl-category><astl-card id="a1" category="a">{{t:template.cardA1}}</astl-card><astl-card id="a2" category="a">{{t:template.cardA2}}</astl-card><astl-card id="b1" category="b">{{t:template.cardB1}}</astl-card><astl-card id="b2" category="b">{{t:template.cardB2}}</astl-card></astl-categorise>`,templates:[{id:`sort-into-groups`,label:`template.sort.label`,description:`template.sort.description`,template:`<h3>{{t:template.sort.heading}}</h3><p>{{t:template.sort.instruction}}</p><astl-categorise id="{{id}}"><astl-prompt>{{t:template.sort.prompt}}</astl-prompt><astl-category id="a">{{t:template.sort.groupA}}</astl-category><astl-category id="b">{{t:template.sort.groupB}}</astl-category><astl-card id="a1" category="a">{{t:template.sort.card1}}</astl-card><astl-card id="b1" category="b">{{t:template.sort.card2}}</astl-card><astl-card id="a2" category="a">{{t:template.sort.card3}}</astl-card><astl-card id="b2" category="b">{{t:template.sort.card4}}</astl-card></astl-categorise>`}],fields:[{kind:`child-choice`,tag:`astl-card`,attribute:`category`,options:`astl-category`,label:`editor.cardCategories`,help:`editor.cardCategoriesHelp`},{kind:`child-table`,tag:`astl-category`,columns:[{attribute:`palette`,label:`editor.palette`}],label:`editor.groups`,help:`editor.groupsHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},Xn={manifest:an,messages:oe,label:`editor.label`,description:`editor.description`,icon:`list-checks`,idPrefix:`choice`,template:`<astl-choice id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-option id="a" correct>{{t:template.option1}}</astl-option><astl-option id="b">{{t:template.option2}}</astl-option><astl-option id="c">{{t:template.option3}}</astl-option></astl-choice>`,templates:[{id:`multiple-choice`,label:`template.choice.label`,description:`template.choice.description`,template:`<h3>{{t:template.choice.heading}}</h3><p>{{t:template.choice.instruction}}</p><astl-choice id="{{id}}"><astl-prompt>{{t:template.choice.prompt}}</astl-prompt><astl-option id="a">{{t:template.choice.option1}}</astl-option><astl-option id="b" correct>{{t:template.choice.option2}}</astl-option><astl-option id="c">{{t:template.choice.option3}}</astl-option></astl-choice>`}],fields:[{kind:`child-flag`,tag:`astl-option`,attribute:`correct`,label:`editor.correctOptions`},{kind:`attribute`,name:`multiple`,label:`editor.multiple`},{kind:`attribute`,name:`shuffle`,label:`editor.shuffle`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},Zn=e=>`<astl-crossword id="{{id}}" rows="5" columns="5">${e}<astl-crossword-word id="w1" answer="{{t:template.crossword.across}}" row="0" column="0" direction="across">{{t:template.crossword.acrossClue}}</astl-crossword-word><astl-crossword-word id="w2" answer="{{t:template.crossword.down}}" row="0" column="0" direction="down">{{t:template.crossword.downClue}}</astl-crossword-word></astl-crossword>`,Qn={manifest:on,messages:re,label:`editor.label`,description:`editor.description`,icon:`grid-four`,idPrefix:`crossword`,template:Zn(`<astl-prompt>{{t:template.crossword.prompt}}</astl-prompt>`),templates:[{id:`crossword`,label:`template.crossword`,description:`template.crossword.description`,template:`<h3>{{t:template.crossword.heading}}</h3><p>{{t:template.crossword.prompt}}</p>${Zn(``)}`}],fields:[{kind:`attribute`,name:`rows`,label:`editor.rows`},{kind:`attribute`,name:`columns`,label:`editor.columns`},{kind:`child-table`,tag:`astl-crossword-word`,label:`editor.words`,help:`editor.wordsHelp`,columns:[{attribute:`answer`,label:`editor.answer`},{attribute:`row`,label:`editor.row`},{attribute:`column`,label:`editor.column`},{attribute:`direction`,label:`editor.direction`}]},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},$n={manifest:sn,messages:t,label:`editor.label`,description:`editor.description`,icon:`arrow-square-in`,idPrefix:`drop`,template:`<astl-drop id="{{id}}" answer="a" bank=""></astl-drop>`,companion:{tag:`astl-word-bank`,attribute:`bank`},fields:[{kind:`attribute`,name:`answer`,label:`editor.answer`,help:`editor.answerHelp`,options:{from:`bank`,tag:`astl-word`}},{kind:`attribute`,name:`bank`,label:`editor.bank`,help:`editor.bankHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},er=`https://assets.example.org/flash-cards/`,P=(e,t)=>`<astl-front>${e}</astl-front><astl-back>{{t:template.cards.${t}}}</astl-back>`,tr=e=>`<img src="${er}${e}.svg" alt="{{t:template.cards.${e}}}" width="96" height="96">`,nr={manifest:cn,messages:s,label:`editor.label`,description:`editor.description`,icon:`cards`,idPrefix:`cards`,template:`<astl-flash-cards id="{{id}}"><astl-front>{{t:template.front}}</astl-front><astl-back>{{t:template.back}}</astl-back></astl-flash-cards>`,templates:[{id:`flash-cards`,label:`editor.template.cards`,description:`editor.template.cards.description`,template:`<h3>{{t:template.cards.title}}</h3><p>{{t:template.cards.instruction}}</p><astl-flash-cards id="{{id}}">`+P(tr(`sun`),`sunBack`)+P(tr(`moon`),`moonBack`)+P(`{{t:template.cards.mars}}`,`marsBack`)+P(`{{t:template.cards.saturn}}`,`saturnBack`)+`</astl-flash-cards>`}],fields:[{kind:`text-list`,tag:`astl-back`,label:`editor.backs`,help:`editor.backsHelp`}]},rr={manifest:ln,messages:c,label:`editor.label`,description:`editor.description`,icon:`text-t`,idPrefix:`gap`,template:`<astl-gap id="{{id}}" answer="{{selection}}"></astl-gap>`,templates:[{id:`fill-the-gaps`,label:`template.fill.label`,description:`template.fill.description`,template:`<h3>{{t:template.fill.heading}}</h3><p>{{t:template.fill.instruction}}</p><p>{{t:template.fill.start}} <astl-gap id="{{id}}" answer="{{t:template.fill.answer1}}"></astl-gap> {{t:template.fill.middle}} <astl-gap answer="{{t:template.fill.answer2}}"></astl-gap>{{t:template.fill.end}}</p>`}],fields:[{kind:`attribute`,name:`answer`,label:`editor.answer`},{kind:`text-list`,tag:`astl-alt`,label:`editor.alternatives`,help:`editor.alternativesHelp`},{kind:`attribute`,name:`type`,label:`editor.type`},{kind:`attribute`,name:`case`,label:`editor.case`},{kind:`attribute`,name:`marks`,label:`editor.marks`,help:`editor.marksHelp`},{kind:`attribute`,name:`tolerance`,label:`editor.tolerance`},{kind:`attribute`,name:`width`,label:`editor.width`},{kind:`attribute`,name:`points`,label:`editor.points`}]},ir={manifest:un,messages:d,label:`editor.label`,description:`editor.description`,icon:`crosshair`,idPrefix:`hotspot`,template:`<astl-hotspot id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-hotspot-region id="r1" x="5" y="10" width="40" height="80" label="{{t:template.place1}}" correct></astl-hotspot-region><astl-hotspot-region id="r2" x="55" y="10" width="40" height="80" label="{{t:template.place2}}"></astl-hotspot-region></astl-hotspot>`,templates:[{id:`find-it-in-the-picture`,label:`template.find.label`,description:`template.find.description`,template:`<h3>{{t:template.find.heading}}</h3><p>{{t:template.find.instruction}}</p><astl-hotspot id="{{id}}" multiple><astl-prompt>{{t:template.find.prompt}}</astl-prompt><astl-hotspot-region id="r1" x="4" y="6" width="22" height="26" label="{{t:template.find.topLeft}}" correct></astl-hotspot-region><astl-hotspot-region id="r2" shape="circle" x="85" y="18" r="10" label="{{t:template.find.topRight}}"></astl-hotspot-region><astl-hotspot-region id="r3" shape="circle" x="50" y="50" r="12" label="{{t:template.find.centre}}" correct></astl-hotspot-region><astl-hotspot-region id="r4" shape="circle" x="15" y="82" r="10" label="{{t:template.find.bottomLeft}}"></astl-hotspot-region><astl-hotspot-region id="r5" x="74" y="68" width="22" height="26" label="{{t:template.find.bottomRight}}" correct></astl-hotspot-region></astl-hotspot>`}],fields:[{kind:`picture-regions`,tag:`astl-hotspot-region`,src:`src`,label:`editor.regions`,help:`editor.regionsHelp`},{kind:`attribute`,name:`alt`,label:`editor.alt`,help:`editor.altHelp`},{kind:`child-flag`,tag:`astl-hotspot-region`,attribute:`correct`,label:`editor.correct`,help:`editor.correctHelp`},{kind:`attribute`,name:`multiple`,label:`editor.multiple`},{kind:`attribute`,name:`outline`,label:`editor.outline`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},ar={manifest:dn,messages:m,label:`editor.label`,description:`editor.description`,icon:`tag`,idPrefix:`image-drop`,template:`<astl-image-drop id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-image-drop-zone id="z1" x="10" y="35" width="30" height="30" answer="l1"></astl-image-drop-zone><astl-image-drop-zone id="z2" x="60" y="35" width="30" height="30" answer="l2"></astl-image-drop-zone><astl-image-drop-label id="l1">{{t:template.label1}}</astl-image-drop-label><astl-image-drop-label id="l2">{{t:template.label2}}</astl-image-drop-label></astl-image-drop>`,templates:[{id:`drag-labels-onto-the-picture`,label:`template.drag.label`,description:`template.drag.description`,template:`<h3>{{t:template.drag.heading}}</h3><p>{{t:template.drag.instruction}}</p><astl-image-drop id="{{id}}"><astl-prompt>{{t:template.drag.prompt}}</astl-prompt><astl-image-drop-zone id="z1" x="20" y="5" width="60" height="25" answer="l1"></astl-image-drop-zone><astl-image-drop-zone id="z2" x="20" y="37.5" width="60" height="25" answer="l2"></astl-image-drop-zone><astl-image-drop-zone id="z3" x="20" y="70" width="60" height="25" answer="l3"></astl-image-drop-zone><astl-image-drop-label id="l1">{{t:template.drag.label1}}</astl-image-drop-label><astl-image-drop-label id="l2">{{t:template.drag.label2}}</astl-image-drop-label><astl-image-drop-label id="l3">{{t:template.drag.label3}}</astl-image-drop-label><astl-image-drop-label id="l4">{{t:template.drag.label4}}</astl-image-drop-label></astl-image-drop>`}],fields:[{kind:`picture-regions`,tag:`astl-image-drop-zone`,src:`src`,label:`editor.zones`,help:`editor.zonesHelp`},{kind:`attribute`,name:`alt`,label:`editor.alt`,help:`editor.altHelp`},{kind:`child-choice`,tag:`astl-image-drop-zone`,attribute:`answer`,options:`astl-image-drop-label`,label:`editor.answers`,help:`editor.answersHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},or={manifest:fn,messages:o,label:`editor.label`,description:`editor.description`,icon:`map-pin`,idPrefix:`image-label`,template:`<astl-image-label id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-image-label-pin id="p1" x="30" y="50" label="{{t:template.answer1}}"></astl-image-label-pin><astl-image-label-pin id="p2" x="70" y="50" label="{{t:template.answer2}}"></astl-image-label-pin></astl-image-label>`,templates:[{id:`label-the-picture`,label:`template.label.label`,description:`template.label.description`,template:`<h3>{{t:template.label.heading}}</h3><p>{{t:template.label.instruction}}</p><astl-image-label id="{{id}}"><astl-prompt>{{t:template.label.prompt}}</astl-prompt><astl-image-label-pin id="p1" x="50" y="15" label="{{t:template.label.top}}"></astl-image-label-pin><astl-image-label-pin id="p2" x="50" y="50" label="{{t:template.label.centre}}" alternatives="{{t:template.label.centreAlternative}}"></astl-image-label-pin><astl-image-label-pin id="p3" x="50" y="85" label="{{t:template.label.bottom}}"></astl-image-label-pin></astl-image-label>`}],fields:[{kind:`picture-points`,tag:`astl-image-label-pin`,src:`src`,label:`editor.pins`,help:`editor.pinsHelp`},{kind:`attribute`,name:`alt`,label:`editor.alt`,help:`editor.altHelp`},{kind:`child-text`,tag:`astl-image-label-pin`,attribute:`alternatives`,label:`editor.alternatives`,help:`editor.alternativesHelp`},{kind:`attribute`,name:`case`,label:`editor.case`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},sr={manifest:pn,messages:a,label:`editor.label`,description:`editor.description`,icon:`note-pencil`,idPrefix:`answer`,template:`<astl-long-answer id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt></astl-long-answer>`,templates:[{id:`write-your-answer`,label:`editor.template.write`,description:`editor.template.write.description`,template:`<h3>{{t:template.write.title}}</h3><p>{{t:template.write.instruction}}</p><astl-long-answer id="{{id}}" rows="6" minlength="100" maxlength="800" placeholder="{{t:template.write.placeholder}}"><astl-prompt>{{t:template.write.question}}</astl-prompt></astl-long-answer>`}],fields:[{kind:`attribute`,name:`rows`,label:`editor.rows`,help:`editor.rowsHelp`},{kind:`attribute`,name:`minlength`,label:`editor.minlength`,help:`editor.minlengthHelp`},{kind:`attribute`,name:`maxlength`,label:`editor.maxlength`,help:`editor.maxlengthHelp`},{kind:`attribute`,name:`placeholder`,label:`editor.placeholder`}]},F=(e,t,n=!1)=>`<astl-mark-word id="${e}"${n?` correct`:``}>{{t:template.${t}}}</astl-mark-word>`,I=(e,t)=>`<p>${[1,2,3,4].map(n=>F(`${e}${n}`,`odd.${e}${n}`,n===t)).join(` `)}</p>`,cr={manifest:mn,messages:ne,label:`editor.label`,description:`editor.description`,icon:`highlighter`,idPrefix:`mark-words`,template:`<astl-mark-words id="{{id}}"><p>{{t:template.before}} ${F(`w1`,`word`,!0)} {{t:template.after}}</p></astl-mark-words>`,templates:[{id:`select-words`,label:`template.select.label`,description:`template.select.description`,template:`<h3>{{t:template.select.heading}}</h3><p>{{t:template.select.instruction}}</p><astl-mark-words id="{{id}}"><astl-prompt>{{t:template.select.prompt}}</astl-prompt><p>{{t:template.select.before}} ${F(`w1`,`select.word1`,!0)} {{t:template.select.middle}} ${F(`w2`,`select.word2`)} {{t:template.select.and}} ${F(`w3`,`select.word3`,!0)} {{t:template.select.after}}</p></astl-mark-words>`},{id:`odd-word`,label:`template.odd.label`,description:`template.odd.description`,icon:`strikethrough`,template:`<h3>{{t:template.odd.heading}}</h3><p>{{t:template.odd.instruction}}</p><astl-mark-words id="{{id}}" variant="strike"><astl-prompt>{{t:template.odd.prompt}}</astl-prompt>${I(`a`,3)}${I(`b`,4)}${I(`c`,2)}</astl-mark-words>`}],fields:[{kind:`attribute`,name:`variant`,label:`editor.variant`},{kind:`child-flag`,tag:`astl-mark-word`,attribute:`correct`,label:`editor.correct`,help:`editor.correctHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}],wrap:{label:`editor.wrap`,child:`astl-mark-word`,attributes:{correct:``}}},lr=(e,t,n)=>`<astl-match id="{{id}}"${t}>${n}`+[`1`,`2`,`3`].map((t,n)=>`<astl-row id="r${t}" column="${`abc`[n]}">{{t:template.${e}.row${t}}}</astl-row>`).join(``)+[`A`,`B`,`C`].map(t=>`<astl-column id="${t.toLowerCase()}">{{t:template.${e}.column${t}}}</astl-column>`).join(``)+`</astl-match>`,ur=(e,t=``)=>`<h3>{{t:template.${e}.heading}}</h3><p>{{t:template.${e}.prompt}}</p>${lr(e,t,``)}`,dr={manifest:hn,messages:u,label:`editor.label`,description:`editor.description`,icon:`arrows-left-right`,idPrefix:`match`,template:lr(`matching`,``,`<astl-prompt>{{t:template.matching.prompt}}</astl-prompt>`),templates:[{id:`matching`,label:`template.matching`,description:`template.matching.description`,template:ur(`matching`)},{id:`join-the-lines`,label:`template.lines`,description:`template.lines.description`,template:ur(`lines`,` variant="lines"`)}],fields:[{kind:`child-choice`,tag:`astl-row`,attribute:`column`,options:`astl-column`,label:`editor.answers`,help:`editor.answersHelp`},{kind:`attribute`,name:`variant`,label:`editor.layout`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},fr=e=>`<astl-memory id="{{id}}">${e}`+[`1`,`2`,`3`].map(e=>`<astl-card-a id="a${e}">{{t:template.memory.a${e}}}</astl-card-a><astl-card-b id="b${e}" pair="a${e}">{{t:template.memory.b${e}}}</astl-card-b>`).join(``)+`</astl-memory>`,pr={manifest:gn,messages:i,label:`editor.label`,description:`editor.description`,icon:`cards`,idPrefix:`memory`,template:fr(`<astl-prompt>{{t:template.memory.prompt}}</astl-prompt>`),templates:[{id:`memory`,label:`template.memory`,description:`template.memory.description`,template:`<h3>{{t:template.memory.heading}}</h3><p>{{t:template.memory.prompt}}</p>${fr(``)}`}],fields:[{kind:`child-choice`,tag:`astl-card-b`,attribute:`pair`,options:`astl-card-a`,label:`editor.pairs`,help:`editor.pairsHelp`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},mr={manifest:_n,messages:te,label:`editor.label`,description:`editor.description`,icon:`list-numbers`,idPrefix:`order`,template:`<astl-order id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-item id="a">{{t:template.item1}}</astl-item><astl-item id="b">{{t:template.item2}}</astl-item><astl-item id="c">{{t:template.item3}}</astl-item></astl-order>`,templates:[{id:`ordering`,label:`template.cycle.label`,description:`template.cycle.description`,template:`<h3>{{t:template.cycle.heading}}</h3><p>{{t:template.cycle.instruction}}</p><astl-order id="{{id}}"><astl-prompt>{{t:template.cycle.prompt}}</astl-prompt><astl-item id="a">{{t:template.cycle.item1}}</astl-item><astl-item id="b">{{t:template.cycle.item2}}</astl-item><astl-item id="c">{{t:template.cycle.item3}}</astl-item><astl-item id="d">{{t:template.cycle.item4}}</astl-item></astl-order>`}],fields:[{kind:`attribute`,name:`scoring`,label:`editor.scoring`,help:`editor.scoringHelp`},{kind:`attribute`,name:`variant`,label:`editor.variant`,help:`editor.variantHelp`},{kind:`attribute`,name:`points`,label:`editor.points`}]},hr={manifest:vn,messages:p,label:`editor.label`,description:`editor.description`,icon:`caret-circle-down`,idPrefix:`select`,template:`<astl-select id="{{id}}"><astl-option id="a" correct>{{t:template.option1}}</astl-option><astl-option id="b">{{t:template.option2}}</astl-option><astl-option id="c">{{t:template.option3}}</astl-option></astl-select>`,templates:[{id:`choose-from-a-list`,label:`template.list.label`,description:`template.list.description`,template:`<h3>{{t:template.list.heading}}</h3><p>{{t:template.list.instruction}}</p><p>{{t:template.list.start}} <astl-select id="{{id}}"><astl-option id="a">{{t:template.list.option1}}</astl-option><astl-option id="b" correct>{{t:template.list.option2}}</astl-option><astl-option id="c">{{t:template.list.option3}}</astl-option></astl-select>{{t:template.list.end}}</p>`},{id:`click-the-right-word`,label:`template.click.label`,description:`template.click.description`,template:`<h3>{{t:template.click.heading}}</h3><p>{{t:template.click.instruction}}</p><p>{{t:template.click.start1}} <astl-select id="{{id}}" variant="buttons"><astl-option id="a">{{t:template.click.option1a}}</astl-option><astl-option id="b" correct>{{t:template.click.option1b}}</astl-option><astl-option id="c">{{t:template.click.option1c}}</astl-option></astl-select>{{t:template.click.end}}</p><p>{{t:template.click.start2}} <astl-select variant="buttons"><astl-option id="a">{{t:template.click.option2a}}</astl-option><astl-option id="b" correct>{{t:template.click.option2b}}</astl-option></astl-select>{{t:template.click.end}}</p>`}],fields:[{kind:`child-flag`,tag:`astl-option`,attribute:`correct`,label:`editor.correctOption`,help:`editor.correctOptionHelp`},{kind:`attribute`,name:`shuffle`,label:`editor.shuffle`},{kind:`attribute`,name:`points`,label:`editor.points`},{kind:`attribute`,name:`variant`,label:`editor.variant`},{kind:`attribute`,name:`native`,label:`editor.native`,help:`editor.nativeHelp`,variants:[`dropdown`]}]},gr={manifest:yn,messages:n,label:`editor.label`,description:`editor.description`,icon:`toggle-left`,idPrefix:`tf`,template:`<astl-true-false id="{{id}}"><astl-prompt>{{t:template.prompt}}</astl-prompt><astl-statement id="s1" answer="true">{{t:template.statement1}}</astl-statement><astl-statement id="s2" answer="false">{{t:template.statement2}}</astl-statement></astl-true-false>`,templates:[{id:`true-or-false`,label:`template.tf.label`,description:`template.tf.description`,template:`<h3>{{t:template.tf.heading}}</h3><p>{{t:template.tf.instruction}}</p><astl-true-false id="{{id}}"><astl-statement id="s1" answer="true">{{t:template.tf.statement1}}</astl-statement><astl-statement id="s2" answer="false">{{t:template.tf.statement2}}</astl-statement><astl-statement id="s3" answer="true">{{t:template.tf.statement3}}</astl-statement></astl-true-false>`}],fields:[{kind:`child-choice`,tag:`astl-statement`,attribute:`answer`,label:`editor.answers`},{kind:`attribute`,name:`true-label`,label:`editor.trueLabel`,help:`editor.labelsHelp`},{kind:`attribute`,name:`false-label`,label:`editor.falseLabel`},{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},_r={manifest:bn,messages:l,label:`editor.label`,description:`editor.description`,icon:`film-strip`,idPrefix:`video`,template:`<astl-video id="{{id}}" label="{{t:template.label}}"></astl-video>`,templates:[{id:`watch-then-answer`,label:`editor.template.watch`,description:`editor.template.watch.description`,template:`<h3>{{t:template.watch.title}}</h3><p>{{t:template.watch.instruction}}</p><astl-callout kind="tip"><p>{{t:template.watch.tip}}</p></astl-callout><astl-video id="{{id}}" label="{{t:template.watch.label}}" youtube="https://youtu.be/Bq7mT2kWx4E"></astl-video><p>{{t:template.watch.sentence}} <astl-gap answer="{{t:template.watch.gap}}"></astl-gap>.</p>`}],fields:[{kind:`attribute`,name:`label`,label:`editor.title`,help:`editor.titleHelp`},{kind:`attribute`,name:`youtube`,label:`editor.youtube`,help:`editor.youtubeHelp`},{kind:`attribute`,name:`vimeo`,label:`editor.vimeo`,help:`editor.vimeoHelp`},{kind:`attribute`,name:`src`,label:`editor.src`,help:`editor.srcHelp`,accept:`video/mp4,video/webm`},{kind:`attribute`,name:`poster`,label:`editor.poster`,help:`editor.posterHelp`,accept:`image/*`},{kind:`attribute`,name:`captions`,label:`editor.captions`,help:`editor.captionsHelp`,accept:`.vtt,text/vtt`},{kind:`attribute`,name:`captions-lang`,label:`editor.captionsLang`,help:`editor.captionsLangHelp`}]},vr={manifest:xn,messages:ee,label:`editor.label`,description:`editor.description`,icon:`cards`,idPrefix:`bank`,template:`<astl-word-bank id="{{id}}"><astl-word id="a">{{t:template.word1}}</astl-word><astl-word id="b">{{t:template.word2}}</astl-word><astl-word id="c" distractor>{{t:template.word3}}</astl-word></astl-word-bank>`,templates:[{id:`drag-words`,label:`editor.template.dragWords`,description:`editor.template.dragWords.description`,template:`<h3>{{t:template.dragWords.heading}}</h3><p>{{t:template.dragWords.instruction}}</p><astl-word-bank id="{{id}}"><astl-word id="a">{{t:template.dragWords.answer1}}</astl-word><astl-word id="b">{{t:template.dragWords.answer2}}</astl-word><astl-word id="c" distractor>{{t:template.dragWords.distractor}}</astl-word></astl-word-bank><p>{{t:template.dragWords.start}} <astl-drop answer="a"></astl-drop>{{t:template.dragWords.middle}} <astl-drop answer="b"></astl-drop>{{t:template.dragWords.end}}</p>`}],fields:[{kind:`child-flag`,tag:`astl-word`,attribute:`distractor`,label:`editor.distractors`,help:`editor.distractorsHelp`},{kind:`attribute`,name:`reuse`,label:`editor.reuse`,help:`editor.reuseHelp`}]},yr=[`right`,`down`,`down-right`,`left`,`up`,`up-left`,`down-left`,`up-right`],br=`<astl-word-search id="{{id}}" right down down-right>`,xr=[1,2,3].map(e=>`<astl-search-word id="w${e}">{{t:template.word${e}}}</astl-search-word>`).join(``),Sr=[rr,Xn,hr,gr,mr,Yn,dr,vr,$n,{manifest:Sn,messages:f,label:`editor.label`,description:`editor.description`,icon:`magnifying-glass`,idPrefix:`word-search`,template:`${br}<astl-prompt>{{t:template.instruction}}</astl-prompt>${xr}</astl-word-search>`,templates:[{id:`word-search`,label:`editor.template.wordSearch`,description:`editor.template.wordSearch.description`,template:`<h3>{{t:template.title}}</h3><p>{{t:template.instruction}}</p>${br}${xr}</astl-word-search>`}],fields:[{kind:`child-text`,tag:`astl-search-word`,attribute:`word`,label:`editor.words`,help:`editor.wordsHelp`},{kind:`attribute`,name:`size`,label:`editor.size`,help:`editor.sizeHelp`},...yr.map(e=>({kind:`attribute`,name:e,label:`editor.${e}`,...e===`right`?{help:`editor.rightHelp`}:{}})),{kind:`attribute`,name:`scoring`,label:`editor.scoring`},{kind:`attribute`,name:`points`,label:`editor.points`}]},pr,Qn,nr,sr,cr,Jn,ir,ar,or,_r,qn],Cr={moveUp:x`<path d="M10 16V4M5 9l5-5 5 5"/>`,moveDown:x`<path d="M10 4v12M5 11l5 5 5-5"/>`,delete:x`<path d="M4 6h12M8 6V4h4v2M6 6l.8 10h6.4L14 6M9 9v4M11 9v4"/>`},wr=e=>e.kind===`attribute`&&e.control!==`checkbox`&&(e.control!==`text`||e.accept===null),L=e=>e.target.value,Tr=e=>e.target.checked,Er=class extends j{static styles=[A,M(`astl-picture-field, astl-style-form, astl-help-form`),_`
|
|
2
2
|
.style {
|
|
3
3
|
display: flex;
|
|
4
4
|
flex-direction: column;
|
|
@@ -1158,7 +1158,7 @@ border-color: Highlight;
|
|
|
1158
1158
|
color: GrayText;
|
|
1159
1159
|
}
|
|
1160
1160
|
}
|
|
1161
|
-
`,Kr=class extends j{static properties={...j.properties,featured:{attribute:!1},views:{attribute:!1},view:{}};static styles=[A,M(`astl-insert-menu, astl-picture-dialog, astl-style-form, astl-style-rules`),Ur,Wr,Gr];#e=Hr;#t=null;#n=null;#r=null;#i=`block`;#a=!1;#o=`elements`;#s=``;#c=!1;#l=null;#u=[];#d=new Kn(this,{count:()=>this.#u.length,item:e=>this.renderRoot.querySelector(`.bar [data-item="${e}"]`),axis:`inline`});constructor(){super(),this.featured=[],this.views=[],this.view=``}get menu(){return this.renderRoot.querySelector(`astl-insert-menu`)}async openMenu(e){await this.#g(e)}async openStyle(e){let t={target:e};this.#_(!1);let n=new CustomEvent(E,{detail:t,bubbles:!0,composed:!0,cancelable:!0});this.dispatchEvent(n)&&(await O(),this.#i=e,await this.#g(`panel`))}async#f(){if(this.#r!==null)return!0;try{let e=await import(`./chunks/style-popups-
|
|
1161
|
+
`,Kr=class extends j{static properties={...j.properties,featured:{attribute:!1},views:{attribute:!1},view:{}};static styles=[A,M(`astl-insert-menu, astl-picture-dialog, astl-style-form, astl-style-rules`),Ur,Wr,Gr];#e=Hr;#t=null;#n=null;#r=null;#i=`block`;#a=!1;#o=`elements`;#s=``;#c=!1;#l=null;#u=[];#d=new Kn(this,{count:()=>this.#u.length,item:e=>this.renderRoot.querySelector(`.bar [data-item="${e}"]`),axis:`inline`});constructor(){super(),this.featured=[],this.views=[],this.view=``}get menu(){return this.renderRoot.querySelector(`astl-insert-menu`)}async openMenu(e){await this.#g(e)}async openStyle(e){let t={target:e};this.#_(!1);let n=new CustomEvent(E,{detail:t,bubbles:!0,composed:!0,cancelable:!0});this.dispatchEvent(n)&&(await O(),this.#i=e,await this.#g(`panel`))}async#f(){if(this.#r!==null)return!0;try{let e=await import(`./chunks/style-popups-Bcl5imdP.js`),t=this.renderRoot,n=e.stylePopupStyles.styleSheet;return this.#r===null&&n!==void 0&&(t.adoptedStyleSheets=[...t.adoptedStyleSheets,n]),this.#r=e,!0}catch(e){return console.error(e),!1}}connectedCallback(){super.connectedCallback(),this.#p(),document.addEventListener(`pointerdown`,this.#m,!0),document.addEventListener(`keydown`,this.#h)}disconnectedCallback(){super.disconnectedCallback(),this.#p(),document.removeEventListener(`pointerdown`,this.#m,!0),document.removeEventListener(`keydown`,this.#h)}willUpdate(e){super.willUpdate(e),e.has(`adapter`)&&this.#p(),this.#e=this.adapter?.formatState?.()??Hr,this.#t=this.adapter?.style?.state()??null}#p(){let e=this.isConnected?this.adapter:null;if((this.#l?.adapter??null)===e)return;this.#l?.off(),this.#l=null;let t=e?.onCursorChange;e!==null&&t!==void 0&&(this.#l={adapter:e,off:t.call(e,()=>this.requestUpdate())})}#m=e=>{if(this.#n===null)return;let t=e.composedPath(),n=this.renderRoot.querySelector(`#${G(this.#n)}`),r=this.renderRoot.querySelector(`[data-popup="${K(this.#n)}"]`);n!==null&&t.includes(n)||r!==null&&t.includes(r)||t.some(e=>e instanceof Element&&e.localName===`astl-picture-dialog`)||this.#_(!1)};#h=e=>{if(this.#n!==`panel`||e.key!==`Escape`)return;let t=this.renderRoot.querySelector(`#panel`),n=t!==null&&e.composedPath().includes(t);n&&e.defaultPrevented||(e.preventDefault(),this.#_(n))};async#g(e){if((e===`panel`||W.has(e))&&!await this.#f())return;this.#n!==null&&this.#n!==e&&this.#_(!1),this.#n=e,this.#c=!1,this.#a=!1,Br(e)&&(this.#s=``,this.#o=e),this.requestUpdate(),await this.updateComplete;let t=this.renderRoot.querySelector(`#${G(e)}`),n=this.renderRoot.querySelector(`[data-popup="${K(e)}"]`);t!==null&&n!==null&&(t.matches(`:popover-open`)||t.showPopover(),this.menu?.requestUpdate(),this.#v(t,n),(e===`style`||W.has(e)?t.querySelector(`[aria-checked="true"], [aria-pressed="true"]`)??t.querySelector(`button`):e===`panel`?t:t.querySelector(`input`))?.focus())}#_(e){let t=this.#n;if(t===null)return;this.#n=null;let n=this.renderRoot.querySelector(`#${G(t)}`);n?.matches(`:popover-open`)===!0&&n.hidePopover(),e&&this.renderRoot.querySelector(`[data-popup="${K(t)}"]`)?.focus(),this.requestUpdate()}#v(e,t){let n=t.getBoundingClientRect(),r=getComputedStyle(t).direction===`rtl`,i=e.offsetWidth,a=document.documentElement.clientWidth,o=r?a-n.right:n.left,s=Math.max(8,Math.min(o,a-i-8));e.style.setProperty(`inset-inline-start`,`${s}px`);let c=document.documentElement.clientHeight-e.offsetHeight-8;e.style.setProperty(`inset-block-start`,`${Math.max(8,Math.min(n.bottom+4,c))}px`)}#y(){this.adapter?.focus?.()}#b(e,t){this.#e.enabled.includes(e)&&(this.adapter?.format?.(e,t),this.#y(),this.requestUpdate())}#x(e){this.adapter?.style?.setText(e),this.#_(!1),this.#y(),this.requestUpdate()}#S(e){this.adapter?.style?.setTarget(`block`,e),this.#_(!1),this.#y(),this.requestUpdate()}#C(e=!1){let t=this.#t;return t===null?null:t.hasSelection&&!e?`text`:t.targets[0]?.kind??null}#w(e=!1){let t=this.#C(e);return t===`text`?this.#t?.textClass??null:this.#t?.targets.find(e=>e.kind===t)?.className??null}#T(e){return this.authoring?.styles.some(t=>t.name===e&&t.text!==!0)??!1}#E(e,t){let n=this.#T(e),r=this.#C(n);r!==null&&(t===void 0?this.adapter?.style?.setClass(r,this.#w(n)===e?null:e):this.adapter?.style?.setClass(r,e,t)),this.#_(!1),this.#y(),this.requestUpdate()}#D(){let e=this.#t?.text[`font-family`];return e===void 0?``:this.authoring?.fonts.find(t=>t.stack===e)?.name??(e.split(`,`)[0]??``).replace(/"/g,``).trim()}#O(){let e=this.#t;if(e===null)return{fonts:[],colors:[],blocks:[],clear:[]};let{text:t,textEnabled:n,targets:r}=e,i=r.some(e=>e.kind===`block`),a=(e,t,n,r,i)=>({id:e,label:t,text:null,icon:r,iconName:i,disabled:!n,popup:e,press:()=>{this.#n===e?this.#_(!0):this.#g(e)}}),o=this.#D(),s=/^(\d+(?:\.\d+)?)px$/.exec(t[`font-size`]??``)?.[1]??t[`font-size`]??``,c=(e,t,r)=>({...a(e,this.t(t,{value:r===``?this.t(`toolbar.default`):r}),n,H.chevron,`chevron`),text:r===``?this.t(`toolbar.${e}.name`):r,menu:!0}),l=r.find(e=>e.kind===`block`)?.style??``,u=Ln(l).get(`text-align`),d=u===`right`||u===`end`?`align-end`:u===`center`?`align-center`:u===`justify`?`align-justify`:`align-start`;return{fonts:[c(`font`,`toolbar.font`,o),c(`size`,`toolbar.size`,s)],colors:[{...a(`color`,this.t(`toolbar.color`),n,H.color,`color`),bar:t.color??null},{...a(`highlight`,this.t(`toolbar.highlight`),n,H.highlight,`highlight`),bar:t[`background-color`]??null}],blocks:[a(`align`,this.t(`toolbar.align`),i,H[d],d),a(`spacing`,this.t(`toolbar.spacing`),i,H.spacing,`spacing`)],clear:[{id:`clear`,label:this.t(`toolbar.clear`),text:null,icon:H.clear,iconName:`clear`,disabled:!n&&!i,press:()=>{this.adapter?.style?.clear(),this.#y(),this.requestUpdate()}}]}}async#k(e){let t=this.menu,n=this.adapter;if(t!==null&&n!==null){if(e===`text`)n.insert(`<p></p>`),this.#y();else{if(e===`picture`)await t.insertPicture();else if(e===`page-break`)t.insertPageBreak();else{let[n=``,r]=e.split(`:`);await t.add(n,r)}this.#y()}}}#A(){let e=this.authoring;if(e===null)return[];let t=this.adapter===null,n=[];for(let r of this.featured){if(r===`text`||r===`picture`){let e=this.t(r===`text`?`insert.text`:`insert.picture`);n.push({id:`insert-${r}`,label:e,text:e,icon:r===`text`?H.text:D.picture,iconName:r===`text`?`text`:`image`,disabled:t,data:{content:r},press:()=>void this.#k(r)});continue}if(r===`page-break`){if(this.adapter?.splitPage===void 0)continue;let e=this.t(`insert.pageBreak`);n.push({id:`insert-page-break`,label:e,text:e,icon:D.page,iconName:`files`,data:{content:r},press:()=>void this.#k(r)});continue}let[i=``,a]=r.split(`:`),o=e.descriptor(i);if(o===null)continue;let s=a===void 0?null:e.templates(i).find(e=>e.id===a);if(s===void 0)continue;let c=e.t(o.manifest.messages,s?.label??o.label),l=s?.icon??o.icon;n.push({id:`insert-${r}`,label:c,text:c,icon:Mn.get(l)??D[o.manifest.display],iconName:l,disabled:t,data:a===void 0?{tag:i}:{tag:i,template:a},press:()=>void this.#k(r)})}return n}#j(){let e=this.adapter,t=this.authoring,n=this.#e,r=[],i=(e,t)=>({id:e,label:this.t(`toolbar.${e}`),text:null,icon:H[e],iconName:e,pressed:n.active.includes(e),disabled:!n.enabled.includes(e),...t===void 0?{}:{popup:t},press:()=>{t===void 0?this.#b(e):this.#g(t)}});if(e?.format!==void 0&&e.formatState!==void 0){let t=U.find(e=>n.active.includes(e)),a=this.#w(),o=a===null?void 0:e.style?.rules().find(e=>e.name===a),s=o?.label??o?.name??this.t(`toolbar.${t??`paragraph`}`),c=this.#O();r.push([`group`,[{id:`style`,label:this.t(`toolbar.style`,{style:s}),text:s,icon:H.chevron,iconName:`chevron`,menu:!0,disabled:!U.some(e=>n.enabled.includes(e))&&(this.#t?.targets.length??0)===0,popup:`style`,press:()=>void this.#g(`style`)}]]),c.fonts.length>0&&r.push([`group`,c.fonts]),r.push([`group`,[...Rr.map(e=>i(e)),i(`link`,`link`)]]),c.colors.length>0&&r.push([`group`,c.colors]),c.blocks.length>0&&r.push([`group`,c.blocks]),r.push([`group`,[...zr.map(e=>i(e)),...c.clear]])}let a=(t,n)=>({id:t,label:this.t(`toolbar.${t}`),text:this.t(`toolbar.${t}`),icon:H[n],iconName:n,disabled:e===null,popup:t,press:()=>{this.#n===t?this.#_(!0):this.#g(t)}}),o=t?.descriptors.some(e=>(e.templates??[]).length>0)===!0;if(r.push([`group inserts`,[...this.#A(),a(`elements`,`add`),...o?[a(`templates`,`templates`)]:[],...e?.style===void 0?[]:[a(`layouts`,`layouts`)]]]),e?.wrap!==void 0&&t!==null){let e=t.descriptors.filter(e=>e.wrap!==void 0);e.length>0&&r.push([`group`,e.map(e=>{let n=t.t(e.manifest.messages,e.wrap?.label??``);return{id:`wrap-${e.manifest.tag}`,label:n,text:n,icon:H.wrap,iconName:`wrap`,data:{wrap:e.manifest.tag},press:()=>{this.adapter?.wrap?.(e.manifest.tag),this.#y()}}})])}if(this.views.length>1&&r.push([`group views`,this.views.map(e=>({id:`view-${e.name}`,label:e.label,text:e.label,icon:null,iconName:``,checked:e.name===this.view,...e.description===void 0?{}:{description:e.description},press:()=>{if(e.name===this.view)return;let t={view:e.name};this.dispatchEvent(new CustomEvent(Vr,{detail:t,bubbles:!0,composed:!0}))}}))]),e?.undo!==void 0&&e.redo!==void 0){let t=t=>({id:t,label:this.t(`toolbar.${t}`),text:null,icon:H[t],iconName:t,disabled:!n[t],press:()=>{n[t]&&(e[t]?.(),this.#y())}});r.push([`group history`,[t(`undo`),t(`redo`)]])}return r}#M(e){let t=e.target.closest(`[data-item]`);if(t===null)return;let n=Number(t.dataset.item),r=this.#u[n];(r?.popup===`style`||W.has(r?.popup??``))&&(e.key===`ArrowDown`||e.key===`ArrowUp`)?(e.preventDefault(),r?.disabled!==!0&&r?.popup!==void 0&&this.#g(r.popup)):this.#d.keydown(e,n)}#N(e,t){let n=e.disabled===!0,r=e.checked===void 0?e.text===null?`button icon-button`:`button`:`button view`;return g`<button
|
|
1162
1162
|
type="button"
|
|
1163
1163
|
part=${r}
|
|
1164
1164
|
class=${e.text===null?`icon-only`:`labelled`}
|
|
@@ -1447,7 +1447,7 @@ padding: var(--astl-focus-width);
|
|
|
1447
1447
|
margin: calc(-1 * var(--astl-focus-width));
|
|
1448
1448
|
}
|
|
1449
1449
|
}
|
|
1450
|
-
`],di=e=>`load`in e?e.tag:e.manifest.tag,fi=null;function pi(){return fi??=Array.from(crypto.getRandomValues(new Uint8Array(16)),e=>e.toString(16).padStart(2,`0`)).join(``),fi}function mi(e,t){return ie({components:t,secret:pi(),slotKinds:[...e.slotKinds.values()],profile:e.profile,catalogs:e.catalogs,styleTemplates:[...e.styleTemplates.values()],...e.urlPolicy===null?{}:{urlPolicy:e.urlPolicy},...e.groundColors===null?{}:{groundColors:e.groundColors}})}var hi={components:new Map,editors:new Map,elements:new Map,styleTemplates:new Map,slotKinds:new Map,catalogs:[],profile:{},urlPolicy:null,groundColors:null,uploadAsset:null,pickPicture:null,fonts:Rn,styles:In,featured:[],views:[],menuMessages:null},Y=null;function X(){return Y??={...hi,engine:mi(hi,[]),version:0},Y}var gi=new Set;function Z(e,t,n,r){let i=new Map(e);for(let e of t??[]){let t=n(e),a=i.get(t);if(a!==void 0&&a!==e)throw Error(`${r} ${t} is already registered`);i.set(t,e)}return i}function _i(e){let t=Y??{...hi,version:0},n=e=>e.manifest.tag,r={components:Z(t.components,e.components,n,`Component`),editors:Z(t.editors,e.editors,n,`Editor descriptor`),elements:Z(t.elements,e.elements,di,`Preview element`),styleTemplates:Z(t.styleTemplates,e.styleTemplates,e=>e.name,`Style template`),slotKinds:Z(t.slotKinds,e.slotKinds,e=>e.kind,`Slot kind`),catalogs:[...new Set([...t.catalogs,...e.catalogs??[]])],profile:{...t.profile,...e.profile},urlPolicy:e.urlPolicy??t.urlPolicy,groundColors:e.groundColors??t.groundColors,uploadAsset:e.uploadAsset??t.uploadAsset,pickPicture:e.pickPicture??t.pickPicture,fonts:e.fonts??t.fonts,styles:e.styles??t.styles,featured:e.featured??t.featured,views:e.views??t.views,menuMessages:e.menuMessages??t.menuMessages},i=[`components`,`editors`,`elements`,`styleTemplates`,`slotKinds`],a=e=>JSON.stringify(Object.entries(e).sort());if(Y!==null&&i.every(e=>r[e].size===t[e].size)&&r.catalogs.length===t.catalogs.length&&r.urlPolicy===t.urlPolicy&&JSON.stringify(r.groundColors)===JSON.stringify(t.groundColors)&&r.uploadAsset===t.uploadAsset&&r.pickPicture===t.pickPicture&&r.menuMessages===t.menuMessages&&JSON.stringify(r.fonts)===JSON.stringify(t.fonts)&&JSON.stringify(r.styles)===JSON.stringify(t.styles)&&r.featured.join(` `)===t.featured.join(` `)&&JSON.stringify(r.views)===JSON.stringify(t.views)&&a(r.profile)===a(t.profile))return;let o=mi(r,[...r.components.values()]);jn({engine:o,descriptors:[...r.editors.values()],locale:`en`,fonts:r.fonts,styles:r.styles}),Y={...r,engine:o,version:t.version+1};for(let e of gi)e.requestUpdate()}function vi(e,t,n){let r=e=>[...e.entries()].filter(([e])=>n===null||n.includes(e)).map(([,e])=>e);return jn({engine:n===null?e.engine:mi(e,r(e.components)),descriptors:r(e.editors),elements:r(e.elements),locale:t,catalogs:e.catalogs,styleTemplates:[...e.styleTemplates.values()],fonts:e.fonts,styles:e.styles,...e.urlPolicy===null?{}:{urlPolicy:e.urlPolicy},...e.uploadAsset===null?{}:{uploadAsset:e.uploadAsset},...e.pickPicture===null?{}:{pickPicture:e.pickPicture},...e.menuMessages===null?{}:{menuMessages:e.menuMessages}})}var yi=[`light`,`dark`,`hc`,`auto`],bi=`astl-editor-change`,xi=`astl-editor-ready`,Si=`astl-editor-view`,Ci=[`visual`,`source`],wi=300,Ti=[`issues`,`inspector`],Ei={fromAttribute:e=>e===null?null:e.split(/\s+/).filter(e=>e!==``)},Di={fromAttribute:e=>{try{return e===null?null:JSON.parse(e)}catch{return null}}},Oi=[`chevron`,`bold`,`italic`,`underline`,`link`,`bulleted`,`numbered`,`undo`,`redo`,`wrap`,`text`,`image`,`files`,`add`,`templates`],ki=`header: inspector-header, id: inspector-id, actions: inspector-actions, issue: inspector-issue, field: inspector-field, label: inspector-label, style: inspector-style`,Q=null,$=null,Ai=class extends Xt{static properties={locale:{},components:{converter:Ei},featured:{converter:Ei},panels:{converter:Ei},view:{},views:{converter:Di},theme:{},previewPolicy:{attribute:!1},adapter:{attribute:!1}};static styles=ui;#e=null;#t=null;#n=null;#r=!1;#i=!1;#a=null;#o=null;#s=0;#c=null;#l=()=>{};#u=new Promise(e=>{this.#l=e});#d={ask:e=>this.renderRoot.querySelector(`astl-picture-dialog`)?.ask(e)??Promise.resolve(null),refuse:()=>{this.#a={key:`picture.pasteRefused`},this.requestUpdate()},style:e=>{this.renderRoot.querySelector(`astl-toolbar`)?.openStyle(e)}};#f=e=>{this.#o=e};#p={start:!1,end:!1};#m=e=>{let t=e.target,n=t.name===`end`?`end`:`start`,r=t.assignedElements().length>0;this.#p[n]!==r&&(this.#p[n]=r,this.requestUpdate())};#h=null;#g=null;#_=[];#v=null;#y;#b=null;#x=null;constructor(){if(super(),this.locale=null,this.components=null,this.featured=null,this.panels=null,this.view=`visual`,this.views=null,this.theme=`auto`,this.previewPolicy=null,this.adapter=null,Object.hasOwn(this,`value`)){let e=this.value;delete this.value,typeof e==`string`&&(this.value=e)}}get value(){return this.adapter?.getSource()??this.#e??`<astl-doc lang="${this.authoring.locale}"></astl-doc>`}set value(e){this.adapter===null?this.#e=e:this.adapter.setSource(e)}get ready(){return this.#u}async preview(){await this.updateComplete,await this.renderRoot.querySelector(`astl-preview`)?.refresh()}get authoring(){let e=X(),t=this.#A(e),n=this.components,r=typeof n==`string`?n.split(/\s+/).filter(e=>e!==``):n,i=`${e.version}\n${t}\n${r===null?`*`:r.join(` `)}`;return this.#b?.key!==i&&(this.#b={key:i,authoring:vi(e,t,r)}),this.#b.authoring}connectedCallback(){super.connectedCallback(),gi.add(this),this.#t===!0&&this.#O(),this.#k()}disconnectedCallback(){super.disconnectedCallback(),gi.delete(this),clearTimeout(this.#y),this.#c=null,this.#k();let e=this.#n;e!==null&&(this.#e=e.adapter.getSource(),e.destroy(),this.#n=null,this.adapter=null)}#S(){let e=this.views??X().views;return Array.isArray(e)?e:[]}#C(){return this.adapter?.editsSource===!0?[`visual`]:Ci}#w(){return[...this.#C(),...this.#S().map(e=>e.name)].includes(this.view)?this.view:`visual`}#T(){let e=this.#g??this.#h??this.value,t=this.authoring.validate(e).issues.filter(e=>e.severity===`error`);return this.#_=t,t.length>0?(this.#a={key:`view.sourceErrors`,params:{n:t.length}},this.#s++,!1):(this.#g!==null&&$?.formatHtml(this.#g)!==this.#h&&(this.value=this.#g),this.#g=null,!0)}#E(e){clearTimeout(this.#y),this.#y=setTimeout(()=>{let e=this.adapter;this.#v=e===null?null:this.authoring.outline(e.getSource()),this.requestUpdate()},e)}willUpdate(e){if(e.has(`theme`)&&(this.dataset.theme=this.#j()),e.has(`view`)&&this.adapter?.editsSource!==!0){let t=e.get(`view`);t===`source`&&this.view!==`source`&&!this.#T()?this.view=`source`:this.view===`source`&&t!==`source`&&(this.#h=this.#g=null,this.#_=[],$===null&&import(`./chunks/source-view-BlJ2mRns.js`).then(e=>{$=e,this.requestUpdate()},e=>console.error(e)))}let t=this.#n;if(t!==null&&this.adapter!==t.adapter&&(this.adapter===null&&(this.#e=t.adapter.getSource()),t.destroy(),this.#n=null),this.adapter!==null&&this.#n===null)this.#t=!1,this.#e!==null&&this.adapter.setSource(this.#e),this.#e=null;else if(this.adapter===null&&this.#n===null)this.isConnected&&(this.#t===null||e.has(`adapter`))&&this.#D();else if(this.#n!==null&&Q!==null&&this.#n.authoring!==this.authoring){let e=this.#n.adapter.getSource();this.#n.destroy(),this.#n=Q.createSurface(this,this.authoring,X().engine.manifests,e,this.#d,this.#f),this.adapter=this.#n.adapter}this.#k()}updated(e){e.has(`theme`)&&this.renderRoot.querySelector(`astl-preview`)?.requestUpdate();let t=this.adapter;t!==null&&t!==this.#c&&this.isConnected&&(this.#c=t,this.#E(0),this.#l(),this.dispatchEvent(new Event(xi,{bubbles:!0,composed:!0})));let n=e.get(`view`);e.has(`view`)&&n!==void 0&&n!==this.view&&this.dispatchEvent(new CustomEvent(Si,{detail:{view:this.view},bubbles:!0,composed:!0}))}#D(){document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,()=>this.requestUpdate(`adapter`),{once:!0}):(this.#t=this.querySelector(`:scope > [slot="surface"]`)===null,this.#t&&this.#O())}async#O(){if(!(this.#r||this.#n!==null)){this.#r=!0,this.#i=!1;try{if(Q??=await import(`./chunks/surface-BhmSAte0.js`),!this.isConnected||!this.#t||this.adapter!==null||this.#n!==null)return;this.#n=Q.createSurface(this,this.authoring,X().engine.manifests,this.value,this.#d,this.#f),this.#e=null,this.adapter=this.#n.adapter}catch(e){this.#i=!0,console.error(e)}finally{this.#r=!1,this.requestUpdate()}}}#k(){let e=this.isConnected?this.adapter:null;(this.#x?.adapter??null)!==e&&(this.#x?.off(),this.#x=e===null?null:{adapter:e,off:e.onChange(()=>{let e=this.#o;this.#o=null,(this.#a!==null||e!==null)&&(this.#a=e,e!==null&&this.#s++,this.requestUpdate()),this.#E(wi),this.dispatchEvent(new Event(bi,{bubbles:!0,composed:!0}))})})}#A(e){let t=this.locale?[this.locale]:this.lang?[this.lang]:[...navigator.languages??[],navigator.language].filter(e=>!!e),n=[...Fn,...e.catalogs].filter(e=>e.namespace===k).map(e=>e.locale);return Wt(t,[...new Set(n)],`en`)}#j(){let e=this.theme;return e!==null&&yi.includes(e)?e:`auto`}render(){let{authoring:e,adapter:t}=this,n=this.#j(),r=this.#i?{key:`surface.failed`}:this.#t&&t===null?{key:`surface.loading`}:this.#a,i=e.locale,a=e=>typeof e==`string`?e.split(/\s+/).filter(e=>e!==``):e,o=a(this.featured)??X().featured,s=(a(this.panels)??Ti).filter(e=>Ti.includes(e)),c=new Set([...Oi,...e.descriptors.flatMap(e=>[e.icon,...(e.templates??[]).map(t=>t.icon??e.icon)])]),l=[`toolbar: toolbar-bar`,`button: toolbar-button`,`icon-button: toolbar-icon-button`,`views: toolbar-views`,`view: toolbar-view`,`separator: toolbar-separator`,`icon: toolbar-icon`,`insert`,`menu: insert-menu`,`style-menu`,`style-colors`,`style-panel`].concat([...c].map(e=>`icon-${e}`)).join(`, `),u=r=>r===`issues`?g`<astl-issues part="issues" data-theme=${n} .authoring=${e} .adapter=${t}></astl-issues>`:g`<astl-inspector part="inspector" exportparts=${ki} data-theme=${n} .authoring=${e} .adapter=${t}></astl-inspector>`,d=(t,n)=>e.t(k,t,n),f=this.#w(),p=[...this.#C().map(e=>{let n=t?.editsSource===!0?`source`:e;return{name:e,label:d(`view.${n}`),description:d(`view.${n}Hint`)}}),...this.#S()],m=f!==`visual`;return g`<div class=${s.length===0||m?`layout solo`:`layout`}>
|
|
1450
|
+
`],di=e=>`load`in e?e.tag:e.manifest.tag,fi=null;function pi(){return fi??=Array.from(crypto.getRandomValues(new Uint8Array(16)),e=>e.toString(16).padStart(2,`0`)).join(``),fi}function mi(e,t){return ie({components:t,secret:pi(),slotKinds:[...e.slotKinds.values()],profile:e.profile,catalogs:e.catalogs,styleTemplates:[...e.styleTemplates.values()],...e.urlPolicy===null?{}:{urlPolicy:e.urlPolicy},...e.groundColors===null?{}:{groundColors:e.groundColors}})}var hi={components:new Map,editors:new Map,elements:new Map,styleTemplates:new Map,slotKinds:new Map,catalogs:[],profile:{},urlPolicy:null,groundColors:null,uploadAsset:null,pickPicture:null,fonts:Rn,styles:In,featured:[],views:[],menuMessages:null},Y=null;function X(){return Y??={...hi,engine:mi(hi,[]),version:0},Y}var gi=new Set;function Z(e,t,n,r){let i=new Map(e);for(let e of t??[]){let t=n(e),a=i.get(t);if(a!==void 0&&a!==e)throw Error(`${r} ${t} is already registered`);i.set(t,e)}return i}function _i(e){let t=Y??{...hi,version:0},n=e=>e.manifest.tag,r={components:Z(t.components,e.components,n,`Component`),editors:Z(t.editors,e.editors,n,`Editor descriptor`),elements:Z(t.elements,e.elements,di,`Preview element`),styleTemplates:Z(t.styleTemplates,e.styleTemplates,e=>e.name,`Style template`),slotKinds:Z(t.slotKinds,e.slotKinds,e=>e.kind,`Slot kind`),catalogs:[...new Set([...t.catalogs,...e.catalogs??[]])],profile:{...t.profile,...e.profile},urlPolicy:e.urlPolicy??t.urlPolicy,groundColors:e.groundColors??t.groundColors,uploadAsset:e.uploadAsset??t.uploadAsset,pickPicture:e.pickPicture??t.pickPicture,fonts:e.fonts??t.fonts,styles:e.styles??t.styles,featured:e.featured??t.featured,views:e.views??t.views,menuMessages:e.menuMessages??t.menuMessages},i=[`components`,`editors`,`elements`,`styleTemplates`,`slotKinds`],a=e=>JSON.stringify(Object.entries(e).sort());if(Y!==null&&i.every(e=>r[e].size===t[e].size)&&r.catalogs.length===t.catalogs.length&&r.urlPolicy===t.urlPolicy&&JSON.stringify(r.groundColors)===JSON.stringify(t.groundColors)&&r.uploadAsset===t.uploadAsset&&r.pickPicture===t.pickPicture&&r.menuMessages===t.menuMessages&&JSON.stringify(r.fonts)===JSON.stringify(t.fonts)&&JSON.stringify(r.styles)===JSON.stringify(t.styles)&&r.featured.join(` `)===t.featured.join(` `)&&JSON.stringify(r.views)===JSON.stringify(t.views)&&a(r.profile)===a(t.profile))return;let o=mi(r,[...r.components.values()]);jn({engine:o,descriptors:[...r.editors.values()],locale:`en`,fonts:r.fonts,styles:r.styles}),Y={...r,engine:o,version:t.version+1};for(let e of gi)e.requestUpdate()}function vi(e,t,n){let r=e=>[...e.entries()].filter(([e])=>n===null||n.includes(e)).map(([,e])=>e);return jn({engine:n===null?e.engine:mi(e,r(e.components)),descriptors:r(e.editors),elements:r(e.elements),locale:t,catalogs:e.catalogs,styleTemplates:[...e.styleTemplates.values()],fonts:e.fonts,styles:e.styles,...e.urlPolicy===null?{}:{urlPolicy:e.urlPolicy},...e.uploadAsset===null?{}:{uploadAsset:e.uploadAsset},...e.pickPicture===null?{}:{pickPicture:e.pickPicture},...e.menuMessages===null?{}:{menuMessages:e.menuMessages}})}var yi=[`light`,`dark`,`hc`,`auto`],bi=`astl-editor-change`,xi=`astl-editor-ready`,Si=`astl-editor-view`,Ci=[`visual`,`source`],wi=300,Ti=[`issues`,`inspector`],Ei={fromAttribute:e=>e===null?null:e.split(/\s+/).filter(e=>e!==``)},Di={fromAttribute:e=>{try{return e===null?null:JSON.parse(e)}catch{return null}}},Oi=[`chevron`,`bold`,`italic`,`underline`,`link`,`bulleted`,`numbered`,`undo`,`redo`,`wrap`,`text`,`image`,`files`,`add`,`templates`],ki=`header: inspector-header, id: inspector-id, actions: inspector-actions, issue: inspector-issue, field: inspector-field, label: inspector-label, style: inspector-style`,Q=null,$=null,Ai=class extends Xt{static properties={locale:{},components:{converter:Ei},featured:{converter:Ei},panels:{converter:Ei},view:{},views:{converter:Di},theme:{},previewPolicy:{attribute:!1},adapter:{attribute:!1}};static styles=ui;#e=null;#t=null;#n=null;#r=!1;#i=!1;#a=null;#o=null;#s=0;#c=null;#l=()=>{};#u=new Promise(e=>{this.#l=e});#d={ask:e=>this.renderRoot.querySelector(`astl-picture-dialog`)?.ask(e)??Promise.resolve(null),refuse:()=>{this.#a={key:`picture.pasteRefused`},this.requestUpdate()},style:e=>{this.renderRoot.querySelector(`astl-toolbar`)?.openStyle(e)}};#f=e=>{this.#o=e};#p={start:!1,end:!1};#m=e=>{let t=e.target,n=t.name===`end`?`end`:`start`,r=t.assignedElements().length>0;this.#p[n]!==r&&(this.#p[n]=r,this.requestUpdate())};#h=null;#g=null;#_=[];#v=null;#y;#b=null;#x=null;constructor(){if(super(),this.locale=null,this.components=null,this.featured=null,this.panels=null,this.view=`visual`,this.views=null,this.theme=`auto`,this.previewPolicy=null,this.adapter=null,Object.hasOwn(this,`value`)){let e=this.value;delete this.value,typeof e==`string`&&(this.value=e)}}get value(){return this.adapter?.getSource()??this.#e??`<astl-doc lang="${this.authoring.locale}"></astl-doc>`}set value(e){this.adapter===null?this.#e=e:this.adapter.setSource(e)}get ready(){return this.#u}async preview(){await this.updateComplete,await this.renderRoot.querySelector(`astl-preview`)?.refresh()}get authoring(){let e=X(),t=this.#A(e),n=this.components,r=typeof n==`string`?n.split(/\s+/).filter(e=>e!==``):n,i=`${e.version}\n${t}\n${r===null?`*`:r.join(` `)}`;return this.#b?.key!==i&&(this.#b={key:i,authoring:vi(e,t,r)}),this.#b.authoring}connectedCallback(){super.connectedCallback(),gi.add(this),this.#t===!0&&this.#O(),this.#k()}disconnectedCallback(){super.disconnectedCallback(),gi.delete(this),clearTimeout(this.#y),this.#c=null,this.#k();let e=this.#n;e!==null&&(this.#e=e.adapter.getSource(),e.destroy(),this.#n=null,this.adapter=null)}#S(){let e=this.views??X().views;return Array.isArray(e)?e:[]}#C(){return this.adapter?.editsSource===!0?[`visual`]:Ci}#w(){return[...this.#C(),...this.#S().map(e=>e.name)].includes(this.view)?this.view:`visual`}#T(){let e=this.#g??this.#h??this.value,t=this.authoring.validate(e).issues.filter(e=>e.severity===`error`);return this.#_=t,t.length>0?(this.#a={key:`view.sourceErrors`,params:{n:t.length}},this.#s++,!1):(this.#g!==null&&$?.formatHtml(this.#g)!==this.#h&&(this.value=this.#g),this.#g=null,!0)}#E(e){clearTimeout(this.#y),this.#y=setTimeout(()=>{let e=this.adapter;this.#v=e===null?null:this.authoring.outline(e.getSource()),this.requestUpdate()},e)}willUpdate(e){if(e.has(`theme`)&&(this.dataset.theme=this.#j()),e.has(`view`)&&this.adapter?.editsSource!==!0){let t=e.get(`view`);t===`source`&&this.view!==`source`&&!this.#T()?this.view=`source`:this.view===`source`&&t!==`source`&&(this.#h=this.#g=null,this.#_=[],$===null&&import(`./chunks/source-view-gqFlZzwR.js`).then(e=>{$=e,this.requestUpdate()},e=>console.error(e)))}let t=this.#n;if(t!==null&&this.adapter!==t.adapter&&(this.adapter===null&&(this.#e=t.adapter.getSource()),t.destroy(),this.#n=null),this.adapter!==null&&this.#n===null)this.#t=!1,this.#e!==null&&this.adapter.setSource(this.#e),this.#e=null;else if(this.adapter===null&&this.#n===null)this.isConnected&&(this.#t===null||e.has(`adapter`))&&this.#D();else if(this.#n!==null&&Q!==null&&this.#n.authoring!==this.authoring){let e=this.#n.adapter.getSource();this.#n.destroy(),this.#n=Q.createSurface(this,this.authoring,X().engine.manifests,e,this.#d,this.#f),this.adapter=this.#n.adapter}this.#k()}updated(e){e.has(`theme`)&&this.renderRoot.querySelector(`astl-preview`)?.requestUpdate();let t=this.adapter;t!==null&&t!==this.#c&&this.isConnected&&(this.#c=t,this.#E(0),this.#l(),this.dispatchEvent(new Event(xi,{bubbles:!0,composed:!0})));let n=e.get(`view`);e.has(`view`)&&n!==void 0&&n!==this.view&&this.dispatchEvent(new CustomEvent(Si,{detail:{view:this.view},bubbles:!0,composed:!0}))}#D(){document.readyState===`loading`?document.addEventListener(`DOMContentLoaded`,()=>this.requestUpdate(`adapter`),{once:!0}):(this.#t=this.querySelector(`:scope > [slot="surface"]`)===null,this.#t&&this.#O())}async#O(){if(!(this.#r||this.#n!==null)){this.#r=!0,this.#i=!1;try{if(Q??=await import(`./chunks/surface-CIz1z2oY.js`),!this.isConnected||!this.#t||this.adapter!==null||this.#n!==null)return;this.#n=Q.createSurface(this,this.authoring,X().engine.manifests,this.value,this.#d,this.#f),this.#e=null,this.adapter=this.#n.adapter}catch(e){this.#i=!0,console.error(e)}finally{this.#r=!1,this.requestUpdate()}}}#k(){let e=this.isConnected?this.adapter:null;(this.#x?.adapter??null)!==e&&(this.#x?.off(),this.#x=e===null?null:{adapter:e,off:e.onChange(()=>{let e=this.#o;this.#o=null,(this.#a!==null||e!==null)&&(this.#a=e,e!==null&&this.#s++,this.requestUpdate()),this.#E(wi),this.dispatchEvent(new Event(bi,{bubbles:!0,composed:!0}))})})}#A(e){let t=this.locale?[this.locale]:this.lang?[this.lang]:[...navigator.languages??[],navigator.language].filter(e=>!!e),n=[...Fn,...e.catalogs].filter(e=>e.namespace===k).map(e=>e.locale);return Wt(t,[...new Set(n)],`en`)}#j(){let e=this.theme;return e!==null&&yi.includes(e)?e:`auto`}render(){let{authoring:e,adapter:t}=this,n=this.#j(),r=this.#i?{key:`surface.failed`}:this.#t&&t===null?{key:`surface.loading`}:this.#a,i=e.locale,a=e=>typeof e==`string`?e.split(/\s+/).filter(e=>e!==``):e,o=a(this.featured)??X().featured,s=(a(this.panels)??Ti).filter(e=>Ti.includes(e)),c=new Set([...Oi,...e.descriptors.flatMap(e=>[e.icon,...(e.templates??[]).map(t=>t.icon??e.icon)])]),l=[`toolbar: toolbar-bar`,`button: toolbar-button`,`icon-button: toolbar-icon-button`,`views: toolbar-views`,`view: toolbar-view`,`separator: toolbar-separator`,`icon: toolbar-icon`,`insert`,`menu: insert-menu`,`style-menu`,`style-colors`,`style-panel`].concat([...c].map(e=>`icon-${e}`)).join(`, `),u=r=>r===`issues`?g`<astl-issues part="issues" data-theme=${n} .authoring=${e} .adapter=${t}></astl-issues>`:g`<astl-inspector part="inspector" exportparts=${ki} data-theme=${n} .authoring=${e} .adapter=${t}></astl-inspector>`,d=(t,n)=>e.t(k,t,n),f=this.#w(),p=[...this.#C().map(e=>{let n=t?.editsSource===!0?`source`:e;return{name:e,label:d(`view.${n}`),description:d(`view.${n}Hint`)}}),...this.#S()],m=f!==`visual`;return g`<div class=${s.length===0||m?`layout solo`:`layout`}>
|
|
1451
1451
|
<astl-toolbar part="toolbar" exportparts=${l} data-theme=${n} .authoring=${e}
|
|
1452
1452
|
.adapter=${t} .featured=${o} .views=${p} .view=${f}
|
|
1453
1453
|
@astl-toolbar-view=${e=>{this.view=e.detail.view}}></astl-toolbar>
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{$ as ee,$t as te,A as ne,At as e,B as t,Bt as n,Ct as r,Dt as i,Et as a,F as o,Ft as s,G as c,Gt as l,H as u,Ht as d,I as f,It as p,J as m,Jt as h,K as g,Kt as _,L as v,Lt as y,Mt as b,N as x,Nt as S,O as C,Ot as w,P as T,Pt as E,Q as D,Qt as O,R as k,Rt as A,Sn as j,St as M,Tt as N,U as P,Ut as F,V as I,Vt as L,W as R,Wt as z,X as B,Xt as V,Y as H,Yt as U,Z as W,Zt as G,_ as K,_n as q,_t as J,an as Y,at as X,bn as Z,bt as re,cn as ie,ct as ae,d as oe,dn as se,dt as Q,en as ce,et as le,f as ue,fn as de,ft as fe,g as pe,gn as me,gt as he,h as ge,hn as _e,ht as ve,i as ye,in as be,it as xe,jt as Se,k as Ce,kt as we,l as Te,ln as Ee,lt as De,m as Oe,mn as ke,mt as Ae,n as je,nn as Me,nt as Ne,o as Pe,on as Fe,ot as Ie,p as Le,pn as Re,pt as ze,q as Be,qt as Ve,r as He,rn as Ue,rt as We,sn as Ge,st as Ke,t as $,tn as qe,tt as Je,u as Ye,un as Xe,ut as Ze,vn as Qe,vt as $e,wt as et,xn as tt,xt as nt,yn as rt,yt as it,z as at,zt as ot}from"./chunks/runtime-
|
|
1
|
+
import{$ as ee,$t as te,A as ne,At as e,B as t,Bt as n,Ct as r,Dt as i,Et as a,F as o,Ft as s,G as c,Gt as l,H as u,Ht as d,I as f,It as p,J as m,Jt as h,K as g,Kt as _,L as v,Lt as y,Mt as b,N as x,Nt as S,O as C,Ot as w,P as T,Pt as E,Q as D,Qt as O,R as k,Rt as A,Sn as j,St as M,Tt as N,U as P,Ut as F,V as I,Vt as L,W as R,Wt as z,X as B,Xt as V,Y as H,Yt as U,Z as W,Zt as G,_ as K,_n as q,_t as J,an as Y,at as X,bn as Z,bt as re,cn as ie,ct as ae,d as oe,dn as se,dt as Q,en as ce,et as le,f as ue,fn as de,ft as fe,g as pe,gn as me,gt as he,h as ge,hn as _e,ht as ve,i as ye,in as be,it as xe,jt as Se,k as Ce,kt as we,l as Te,ln as Ee,lt as De,m as Oe,mn as ke,mt as Ae,n as je,nn as Me,nt as Ne,o as Pe,on as Fe,ot as Ie,p as Le,pn as Re,pt as ze,q as Be,qt as Ve,r as He,rn as Ue,rt as We,sn as Ge,st as Ke,t as $,tn as qe,tt as Je,u as Ye,un as Xe,ut as Ze,vn as Qe,vt as $e,wt as et,xn as tt,xt as nt,yn as rt,yt as it,z as at,zt as ot}from"./chunks/runtime-C25QK5B0.js";$();export{je as AstlElement,Pe as AstlPlayer,ue as AttemptController,y as BLOCK_TAGS,et as BUILT_IN_PREFIX,A as CAPTION_TAG,ot as CLASS_ATTRIBUTE,n as COLUMNS_TAG,L as COLUMN_TAG,W as COMMON_ATTRIBUTES,d as CONTENT_ATTRIBUTES,Ee as CheckerError,F as DEFAULT_DOC_KIND,o as DEFAULT_PROFILE,z as DOC_ATTRIBUTES,l as DOC_KINDS,N as DOC_TAG,a as ELEMENT_TAG_PATTERN,Ie as ENGINE_NAMESPACE,$e as EXPLANATION_TAG,Ke as EngineIssue,it as FEEDBACK_TAG,re as FEEDBACK_VARIANTS,_ as FIGURE_TAG,_e as FLAG_SELECTED,i as FORMAT_VERSION,nt as HELP_ATTRIBUTES,M as HELP_TAGS,r as HINT_TAG,Ve as INERT_STYLE,h as INLINE_TAGS,at as JSON_MEDIA_TYPE,Ge as KEY_FORMAT_VERSION,w as LANGUAGE_TAG_PATTERN,me as MAX_ANSWER_COUNT,q as MAX_ANSWER_LENGTH,U as MAX_ATTRIBUTES_PER_ELEMENT,V as MAX_COLUMNS,G as MAX_NESTING_DEPTH,Qe as MAX_OPEN_ANSWER_LENGTH,t as MAX_REQUEST_BYTES,we as MAX_SOURCE_LENGTH,O as MIN_COLUMNS,ze as MessageSyntaxError,e as OPAQUE_ID_PATTERN,rt as OPEN_SLOT_KIND,te as PAGE_ATTRIBUTES,Se as PAGE_TAG,Te as PLAYER_NAMESPACE,g as PRACTICE_POLICY,I as PROBLEM_MEDIA_TYPE,u as PROTOCOL_VERSION,B as PlayerEvent,P as ProblemCode,R as ProtocolPath,ce as REMOVED_WITH_CONTENT,D as SCORING_ATTRIBUTES,f as SCORING_RULES,x as SNAPSHOT_FORMAT,b as SOURCE_ID_PATTERN,qe as STYLE_TAG,We as STYLE_TEMPLATE_ATTRIBUTE,xe as STYLE_TEMPLATE_NAME,S as SUPPORTED_FORMATS,He as SingleSlotElement,Me as TAG_ATTRIBUTES,Be as TEST_POLICY,Ue as URL_ATTRIBUTES,ee as allAttributes,Le as announce,C as builtInElements,ne as builtInStyleTemplates,Q as checkCatalog,Xe as childElements,le as childTagConflict,fe as compareCatalogs,De as createI18n,$ as definePlayer,E as directionOf,se as element,Z as fitsAnswer,v as groupMax,ae as hasErrors,m as helpPolicy,oe as httpChecker,Ae as icuFormatter,be as inertStyles,ie as isAnswerKey,tt as isAnswers,H as isAttemptPolicy,de as isElement,s as isOpaqueId,c as isProblemDetails,Y as isSafeUrl,T as isSnapshot,p as isSourceId,X as isStyleTemplate,j as maxAnswerLength,ve as messageParams,Ze as negotiateLocale,he as parseMessage,Ye as playerMessages,J as pluralCategories,Oe as renderVerdict,k as roundScore,Je as sameChildSpec,ye as seededShuffle,Fe as strictUrlPolicy,Re as text,ke as textContent,Ce as tokensCss,Ne as variantAttribute,ge as verdictIcon,pe as verdictStyles,K as visuallyHidden};
|
|
2
2
|
//# sourceMappingURL=astrolabe-player.js.map
|
package/dist/cdn/astrolabe.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{A as e,B as t,C as n,D as r,E as i,F as a,G as o,H as s,I as c,J as l,K as u,L as d,M as ee,N as te,O as ne,P as f,R as p,T as m,U as re,V as h,W as g,Y as ie,j as ae,k as oe,q as se,t as _,w as ce,z as v}from"./chunks/definitions-
|
|
1
|
+
import{A as e,B as t,C as n,D as r,E as i,F as a,G as o,H as s,I as c,J as l,K as u,L as d,M as ee,N as te,O as ne,P as f,R as p,T as m,U as re,V as h,W as g,Y as ie,j as ae,k as oe,q as se,t as _,w as ce,z as v}from"./chunks/definitions-BybSa1mq.js";import{$ as y,$t as b,A as x,At as S,B as C,Bt as w,Ct as T,Dt as E,Et as D,F as O,Ft as k,G as A,Gt as j,H as M,Ht as N,I as P,It as F,J as I,Jt as L,K as R,Kt as z,L as B,Lt as V,M as H,Mt as U,N as W,Nt as G,O as le,Ot as ue,P as de,Pt as fe,Q as pe,Qt as me,R as he,Rt as ge,Sn as _e,St as K,Tt as ve,U as ye,Ut as be,V as xe,Vt as Se,W as Ce,Wt as we,X as Te,Xt as Ee,Y as De,Yt as Oe,Z as ke,Zt as Ae,_ as je,_n as Me,_t as Ne,an as Pe,at as Fe,bn as Ie,bt as Le,cn as Re,ct as ze,d as Be,dn as Ve,dt as He,en as Ue,et as We,f as Ge,fn as Ke,ft as qe,g as Je,gn as Ye,gt as Xe,h as Ze,hn as Qe,ht as $e,i as et,in as tt,it as nt,jt as rt,k as it,kt as at,l as ot,ln as st,lt as ct,m as lt,mn as ut,mt as dt,n as ft,nn as pt,nt as mt,o as ht,on as gt,ot as _t,p as vt,pn as yt,pt as bt,q as xt,qt as St,r as Ct,rn as wt,rt as Tt,sn as Et,st as Dt,t as q,tn as Ot,tt as kt,u as At,un as jt,ut as Mt,vn as Nt,vt as Pt,wt as Ft,xn as It,xt as Lt,yn as Rt,yt as zt,z as Bt,zt as Vt}from"./chunks/runtime-C25QK5B0.js";import{a as Ht,c as Ut,d as Wt,f as Gt,i as Kt,l as qt,n as Jt,o as Yt,p as Xt,r as Zt,s as Qt,t as $t,u as en}from"./chunks/declarations-BhqOz1ap.js";import{r as tn}from"./chunks/audio-manifest-B9FWQzRy.js";import{r as nn}from"./chunks/callout-manifest-Cb12O4jl.js";import{r as rn}from"./chunks/categorise-manifest-C_hEDVYQ.js";import{r as an}from"./chunks/choice-manifest-C-XahD7m.js";import{r as on}from"./chunks/crossword-manifest-2qlu7AYd.js";import{r as sn}from"./chunks/drop-manifest-bzNOa5ks.js";import{r as cn}from"./chunks/flash-cards-manifest-B8nWXbRy.js";import{r as ln}from"./chunks/gap-manifest-RSydA41N.js";import{r as un}from"./chunks/hotspot-manifest-CNs1oiZ_.js";import{r as dn}from"./chunks/image-drop-manifest-BZ6hCoAd.js";import{r as fn}from"./chunks/image-label-manifest--1CLRJzd.js";import{r as pn}from"./chunks/long-answer-manifest-BYJpZRtB.js";import{r as J}from"./chunks/mark-words-manifest-Cs2pXCEx.js";import{r as mn}from"./chunks/match-manifest-D0UfoajU.js";import{r as hn}from"./chunks/memory-manifest-D1589iR0.js";import{r as gn}from"./chunks/order-manifest-J5IXN0he.js";import{r as _n}from"./chunks/select-manifest-BBMbvdkH.js";import{r as vn}from"./chunks/true-false-manifest-B4exv60u.js";import{r as yn}from"./chunks/video-manifest-8OwkhhAI.js";import{r as bn}from"./chunks/word-bank-manifest-C1FSo1kH.js";import{o as xn}from"./chunks/word-search-manifest-Fg1a59Z1.js";function Y(e,t){let n=[],r=[...e].reverse();for(let e=r.pop();e!==void 0;e=r.pop())if(e.type===`element`){if(t.has(e.tag))n.push(e);else for(let t=e.children.length-1;t>=0;t--)r.push(e.children[t])}return n}function X(e){return e.flatMap(e=>e.type===`text`?[e]:K.has(e.tag)?[]:[{...e,children:X(e.children)}])}function Sn(e,t){let n=[],r=e=>e.flatMap(e=>e.type===`element`?[e,...v(e)]:[]);for(let e of r(t))K.has(e.tag)&&n.push({tag:e.tag,element:null,kind:`child`,detail:e.tag});let i=h(t),a=h(X(e));for(let t of r(e)){if(!K.has(t.tag))continue;let e=h(t.children).trim();e!==``&&p(i,e)&&!p(a,e)&&n.push({tag:t.tag,element:null,kind:`value`,detail:`${t.tag} "${e}"`})}return n}function Cn(e,n,r){let i=new Map(r.map(e=>[e.tag,e])),a=new Set(i.keys()),o=s(e),c=s(n),l=Y(X(o),a),u=Y(c,a),d=Sn(o,c);if(l.length!==u.length){let e=`${l.length} components in the source, ${u.length} in the view`;d.push({tag:``,element:null,kind:`structure`,detail:e})}for(let e=0;e<Math.min(l.length,u.length);e++){let n=l[e],r=u[e],a=Object.hasOwn(n.attrs,`id`)?n.attrs.id??null:null;if(r.tag!==n.tag)d.push({tag:n.tag,element:a,kind:`structure`,detail:`view has <${r.tag}> here`});else for(let e of t(n,r,i.get(n.tag))){let t=e.value===void 0?e.what:`${e.what} "${e.value}"`;d.push({tag:n.tag,element:a,kind:e.kind,detail:t})}}return d}function wn(e,t=``){let n=te(d(e));return async e=>{let r=e.indexOf(`/`),i=e.startsWith(`page:`)?e:r<0?f(e):f(e.slice(0,r),e.slice(r+1));return c(await n(a(t,i)))}}var Tn=[ln,an,_n,vn,gn,rn,mn,bn,sn,xn,hn,on,cn,pn,J,nn,un,dn,fn,yn,tn],Z=`astrolabe-in-browser-key`;function Q(e={}){let{surface:t,ink:n}=H.themes.light;return ce({components:_,styleTemplates:x,groundColors:{surface:t,ink:n},...e})}function $(e=Q({secret:Z})){return async(t,n)=>{let r=await e.compile(t,{salt:location.pathname});if(!r.ok){let t=r.issues.filter(e=>e.severity===`error`).map(t=>e.describe(t,n.locale)).join(`
|
|
2
2
|
`);throw console.error(t),Error(t)}return{view:r.view,checker:g(e,r.key)}}}q({compileSource:$()});export{ft as AstlElement,ht as AstlPlayer,Ge as AttemptController,V as BLOCK_TAGS,Ft as BUILT_IN_PREFIX,ge as CAPTION_TAG,Vt as CLASS_ATTRIBUTE,w as COLUMNS_TAG,Se as COLUMN_TAG,ke as COMMON_ATTRIBUTES,N as CONTENT_ATTRIBUTES,st as CheckerError,be as DEFAULT_DOC_KIND,O as DEFAULT_PROFILE,we as DOC_ATTRIBUTES,j as DOC_KINDS,ve as DOC_TAG,D as ELEMENT_TAG_PATTERN,_t as ENGINE_NAMESPACE,Pt as EXPLANATION_TAG,Dt as EngineIssue,zt as FEEDBACK_TAG,Le as FEEDBACK_VARIANTS,z as FIGURE_TAG,Qe as FLAG_SELECTED,E as FORMAT_VERSION,Lt as HELP_ATTRIBUTES,K as HELP_TAGS,T as HINT_TAG,St as INERT_STYLE,L as INLINE_TAGS,Z as IN_BROWSER_SECRET,Bt as JSON_MEDIA_TYPE,Et as KEY_FORMAT_VERSION,ue as LANGUAGE_TAG_PATTERN,Ye as MAX_ANSWER_COUNT,Me as MAX_ANSWER_LENGTH,Oe as MAX_ATTRIBUTES_PER_ELEMENT,Ee as MAX_COLUMNS,$t as MAX_INLINED_STYLES,Ae as MAX_NESTING_DEPTH,Nt as MAX_OPEN_ANSWER_LENGTH,C as MAX_REQUEST_BYTES,at as MAX_SOURCE_LENGTH,Jt as MAX_STYLE_LENGTH,Zt as MAX_STYLE_RULES,me as MIN_COLUMNS,bt as MessageSyntaxError,S as OPAQUE_ID_PATTERN,Rt as OPEN_SLOT_KIND,b as PAGE_ATTRIBUTES,rt as PAGE_TAG,ot as PLAYER_NAMESPACE,R as PRACTICE_POLICY,xe as PROBLEM_MEDIA_TYPE,M as PROTOCOL_VERSION,Te as PlayerEvent,ye as ProblemCode,Ce as ProtocolPath,Ue as REMOVED_WITH_CONTENT,pe as SCORING_ATTRIBUTES,P as SCORING_RULES,W as SNAPSHOT_FORMAT,U as SOURCE_ID_PATTERN,Kt as STYLE_PROPERTIES,Ot as STYLE_TAG,Tt as STYLE_TEMPLATE_ATTRIBUTE,nt as STYLE_TEMPLATE_NAME,G as SUPPORTED_FORMATS,Ct as SingleSlotElement,pt as TAG_ATTRIBUTES,xt as TEST_POLICY,wt as URL_ATTRIBUTES,y as allAttributes,vt as announce,_ as builtInDefinitions,le as builtInElements,Tn as builtInManifests,x as builtInStyleTemplates,He as checkCatalog,jt as childElements,We as childTagConflict,m as choiceSlot,Ht as cleanClass,Yt as cleanStyle,qe as compareCatalogs,Q as createEngine,ct as createI18n,$ as createSourceCompiler,q as definePlayer,fe as directionOf,Ve as element,ee as engineMessages,Ie as fitsAnswer,i as flagSlot,B as groupMax,ze as hasErrors,I as helpPolicy,o as helpShown,u as hintCount,Be as httpChecker,dt as icuFormatter,tt as inertStyles,Re as isAnswerKey,It as isAnswers,De as isAttemptPolicy,Ke as isElement,se as isGradedElement,k as isOpaqueId,A as isProblemDetails,Pe as isSafeUrl,de as isSnapshot,F as isSourceId,Qt as isStyleName,Fe as isStyleTemplate,n as kit,Cn as leakProbe,r as letterSlot,g as localChecker,_e as maxAnswerLength,Ut as mergeStyles,$e as messageParams,Mt as negotiateLocale,l as nextHint,e as normalise,ne as numberSlot,qt as overStyleColor,s as parseHtml,Xe as parseMessage,ae as parseNumber,en as parseStyleColor,At as playerMessages,Ne as pluralCategories,wn as refResolver,lt as renderVerdict,ie as resultHelp,he as roundScore,kt as sameChildSpec,et as seededShuffle,re as serializeHtml,gt as strictUrlPolicy,Wt as styleContrast,Gt as styleLuminance,Xt as styleText,yt as text,ut as textContent,oe as textSlot,it as tokensCss,mt as variantAttribute,Ze as verdictIcon,Je as verdictStyles,je as visuallyHidden};
|
|
3
3
|
//# sourceMappingURL=astrolabe.js.map
|