@nixweb/nixloc-ui 0.0.120 → 0.0.121
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/docs/src/component/template/ModeloRelatorioView.drawio +160 -0
- package/docs/src/store/modulos/relatorio.drawio +37 -0
- package/package.json +12 -10
- package/public/index.html +2 -4
- package/public/styles/app.css +0 -1
- package/src/store/modulos/generic.js +1 -1
- package/public/js/menu.js +0 -11
- package/public/styles/menu.css +0 -1399
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
<mxfile host="65bd71144e">
|
|
2
|
+
<diagram id="E48Z9MQLlxmhIpPkPNIA" name="Store">
|
|
3
|
+
<mxGraphModel dx="1123" dy="612" grid="0" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="1200" pageHeight="1920" background="#ffffff" math="0" shadow="0">
|
|
4
|
+
<root>
|
|
5
|
+
<mxCell id="0"/>
|
|
6
|
+
<mxCell id="1" parent="0"/>
|
|
7
|
+
<mxCell id="4" value="" style="shape=curlyBracket;whiteSpace=wrap;html=1;rounded=1;fontFamily=Helvetica;fontSize=13;fontColor=#ffffff;fillColor=none;strokeColor=#E81313;strokeWidth=2;" vertex="1" parent="1">
|
|
8
|
+
<mxGeometry x="138" y="25" width="20" height="202" as="geometry"/>
|
|
9
|
+
</mxCell>
|
|
10
|
+
<mxCell id="5" value="<font style="font-size: 19px">state</font>" style="text;strokeColor=none;fillColor=none;html=1;fontSize=24;fontStyle=1;verticalAlign=middle;align=center;fontFamily=Helvetica;fontColor=#000000;" vertex="1" parent="1">
|
|
11
|
+
<mxGeometry x="25" y="103" width="100" height="40" as="geometry"/>
|
|
12
|
+
</mxCell>
|
|
13
|
+
<mxCell id="6" value="<span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">relatorio:campo[ ]:&nbsp;</span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><font color="#000000">Campos que poderão conter no relatório, os campos são os mesmos da tabela, os parâmetros aceitos estão no component &lt;tabela&gt;.</font><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">relatorio:filtro[ ]:<span>&nbsp;</span></span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><font color="#000000">Campos que poderão conter no relatório, os campos são os mesmos da tabela.</font><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">campoSelecionado[ ]:<span>&nbsp;</span></span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><font color="#000000">Campos que foram selecionados no componente &lt;Filtro&gt; do &lt;QueryBuilder&gt;.</font><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">filtroSelecionado{ children [ } }:<span>&nbsp;</span></span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><font color="#000000">Filtros selecionados no componente &lt;Filtro&gt; do &lt;QueryBuilder&gt;, o próprio &lt;QueryBuilder&gt; retorna um v-model.</font><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">campoOrdenado{}:<span>&nbsp;</span></span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><font color="#000000">Campo que for ordenado no componente &lt;Filtro&gt; do &lt;QueryBuilder&gt;.</font><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">opcoes:valorInicial [ ]:</span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">opcoes:opcoes[ ]:</span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; color: rgb(232 , 19 , 19) ; font-weight: bold">opcoesValorInicial [ ]:</span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; font-weight: bold"><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; font-weight: bold ; color: rgb(232 , 19 , 19)">consulta [ ]:<span>&nbsp;</span></span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><font color="#000000">Array com a consulta no padrão oData para ser filtrado.</font></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; font-weight: bold ; color: rgb(232 , 19 , 19)"><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; font-weight: bold ; color: rgb(232 , 19 , 19)">resumo [ ]:<span>&nbsp;</span></span><span style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px"><font color="#000000">Array com a resumo no padrão oData.</font><br></span><span style="font-family: &#34;helvetica&#34; ; font-size: 13px ; font-style: normal ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; font-weight: bold ; color: rgb(232 , 19 , 19)">tags [ ]:<span>&nbsp;</span></span><span style="font-family: &#34;helvetica&#34;">Array com as tags que são carregadas no componente &lt;Tags/&gt;</span>" style="text;whiteSpace=wrap;html=1;fontSize=13;fontFamily=Helvetica;fontColor=#000000;" vertex="1" parent="1">
|
|
14
|
+
<mxGeometry x="167" y="31" width="896" height="190" as="geometry"/>
|
|
15
|
+
</mxCell>
|
|
16
|
+
<mxCell id="7" value="" style="shape=curlyBracket;whiteSpace=wrap;html=1;rounded=1;fontFamily=Helvetica;fontSize=13;fontColor=#ffffff;fillColor=none;strokeColor=#006600;strokeWidth=2;" vertex="1" parent="1">
|
|
17
|
+
<mxGeometry x="138" y="266" width="20" height="156" as="geometry"/>
|
|
18
|
+
</mxCell>
|
|
19
|
+
<mxCell id="8" value="<font style="font-size: 19px">mutations</font>" style="text;strokeColor=none;fillColor=none;html=1;fontSize=24;fontStyle=1;verticalAlign=middle;align=center;fontFamily=Helvetica;fontColor=#000000;" vertex="1" parent="1">
|
|
20
|
+
<mxGeometry x="27" y="321" width="100" height="40" as="geometry"/>
|
|
21
|
+
</mxCell>
|
|
22
|
+
<mxCell id="9" value="<p style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; margin: 0px 0px 0px 8px ; font-size: 13px"><span data-lucid-type="application/vnd.lucid.text" data-lucid-content="{&#34;t&#34;:&#34;insereRelatorio(): Insere o objeto contendo as informações dos campos e filtros.\natualizaCampoSelecionado(): Insere os campos selecionados que vem do componente &lt;Campo&gt; do &lt;QueryBuilder&gt;.\natualizaFiltroSelecionado(): Insere as informações dos filtros iniciais para carregar no componente &lt;Filtro&gt;, utilizado quando tem um relatório salvo.\natualizaCampoOrdenado(): Insere qual campo está ordenado para efetuar a busca.\natualizaOpcoesValorInicial(): Insere as informações dos campos iniciais para carregar no componente &lt;Campo&gt;, utilizado quando tem um relatório salvo.\nremoveFiltroSelecionado(): Remove o filtro selecionado, utilizado quando uma tag é removida, então precisa atualizar o array de filtro.\natualizaConsultaFiltro(): Monta o array convertendo os filtros no padrão &lt;QueryBuilder&gt; para o formato oData através da classe converteParaOData(), bem como adiciona no array resumo[ ] caso possua configurado nos parâmetros iniciais. Faz tambem as validações de os dados estão corretos. \n&#34;,&#34;m&#34;:[{&#34;s&#34;:0,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:0,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:19},{&#34;s&#34;:0,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:17},{&#34;s&#34;:0,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:17},{&#34;s&#34;:0,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:17},{&#34;s&#34;:81,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:107},{&#34;s&#34;:81,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:107},{&#34;s&#34;:81,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:107},{&#34;s&#34;:81,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:109},{&#34;s&#34;:188,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:217},{&#34;s&#34;:188,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:215},{&#34;s&#34;:188,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:215},{&#34;s&#34;:188,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:215},{&#34;s&#34;:339,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:362},{&#34;s&#34;:339,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:362},{&#34;s&#34;:339,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:362},{&#34;s&#34;:339,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:364},{&#34;s&#34;:0,&#34;n&#34;:&#34;s&#34;,&#34;v&#34;:19.999999999999996,&#34;e&#34;:992},{&#34;s&#34;:81,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:188,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:418,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:339,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:418,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:446},{&#34;s&#34;:418,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:446},{&#34;s&#34;:418,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:446},{&#34;s&#34;:418,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:448},{&#34;s&#34;:567,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:568},{&#34;s&#34;:567,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:568},{&#34;s&#34;:567,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:568},{&#34;s&#34;:567,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:568},{&#34;s&#34;:568,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:593},{&#34;s&#34;:568,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:593},{&#34;s&#34;:568,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:593},{&#34;s&#34;:568,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:595},{&#34;s&#34;:704,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:730},{&#34;s&#34;:704,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:730},{&#34;s&#34;:704,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:730},{&#34;s&#34;:704,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:730},{&#34;s&#34;:568,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:704,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157}]}"><span style="font-weight: bold ; color: rgb(0 , 138 , 14)">insereRelatorio()</span><span style="color: rgb(0 , 138 , 14)">:</span><font color="#000000"><span>&nbsp;</span></font><font color="#000000">Insere o objeto contendo as informações dos campos e filtros.</font><br><span style="font-weight: bold ; color: rgb(0 , 138 , 14)">atualizaCampoSelecionado()</span><span style="color: rgb(0 , 138 , 14)">:</span><font color="#000000"><span>&nbsp;</span>Insere os campos selecionados que vem do componente &lt;Campo&gt; do &lt;QueryBuilder&gt;.</font><br><span style="font-weight: bold ; color: rgb(0 , 138 , 14)">atualizaFiltroSelecionado()</span><span style="color: rgb(0 , 138 , 14)">:<span>&nbsp;</span></span><font color="#000000">Insere as informações dos filtros iniciais para carregar no componente &lt;Filtro&gt;, utilizado quando tem um relatório salvo.</font><br><span style="font-weight: bold ; color: rgb(0 , 138 , 14)">atualizaCampoOrdenado()</span><span style="color: rgb(0 , 138 , 14)">:<span>&nbsp;</span></span><font color="#000000">Insere qual campo está ordenado para efetuar a busca.</font><br><span style="font-weight: bold ; color: rgb(0 , 138 , 14)">atualizaOpcoesValorInicial()</span><span style="color: rgb(0 , 138 , 14)">:<span>&nbsp;</span></span><font color="#000000">Insere as informações dos campos iniciais para carregar no componente &lt;Campo&gt;, utilizado quando tem um relatório salvo.</font><span style="font-weight: bold ; color: rgb(0 , 138 , 14)"><br></span><span style="font-weight: bold ; color: rgb(0 , 138 , 14)">removeFiltroSelecionado()</span><span style="color: rgb(0 , 138 , 14)">:<span>&nbsp;</span></span><font color="#000000">Remove o filtro selecionado, utilizado quando uma tag é removida, então precisa atualizar o array de filtro.</font><br><span style="color: rgb(0 , 138 , 14) ; font-weight: bold">atualizaConsultaFiltro():<span>&nbsp;</span></span><font color="#000000">Monta o array convertendo os filtros no padrão &lt;QueryBuilder&gt; para o formato oData através da classe converteParaOData(),&nbsp;</font></span></p><p style="color: rgb(240 , 240 , 240) ; font-family: &#34;helvetica&#34; ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; margin: 0px 0px 0px 8px ; font-size: 13px"><span data-lucid-type="application/vnd.lucid.text" data-lucid-content="{&#34;t&#34;:&#34;insereRelatorio(): Insere o objeto contendo as informações dos campos e filtros.\natualizaCampoSelecionado(): Insere os campos selecionados que vem do componente &lt;Campo&gt; do &lt;QueryBuilder&gt;.\natualizaFiltroSelecionado(): Insere as informações dos filtros iniciais para carregar no componente &lt;Filtro&gt;, utilizado quando tem um relatório salvo.\natualizaCampoOrdenado(): Insere qual campo está ordenado para efetuar a busca.\natualizaOpcoesValorInicial(): Insere as informações dos campos iniciais para carregar no componente &lt;Campo&gt;, utilizado quando tem um relatório salvo.\nremoveFiltroSelecionado(): Remove o filtro selecionado, utilizado quando uma tag é removida, então precisa atualizar o array de filtro.\natualizaConsultaFiltro(): Monta o array convertendo os filtros no padrão &lt;QueryBuilder&gt; para o formato oData através da classe converteParaOData(), bem como adiciona no array resumo[ ] caso possua configurado nos parâmetros iniciais. Faz tambem as validações de os dados estão corretos. \n&#34;,&#34;m&#34;:[{&#34;s&#34;:0,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:0,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:19},{&#34;s&#34;:0,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:17},{&#34;s&#34;:0,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:17},{&#34;s&#34;:0,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:17},{&#34;s&#34;:81,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:107},{&#34;s&#34;:81,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:107},{&#34;s&#34;:81,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:107},{&#34;s&#34;:81,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:109},{&#34;s&#34;:188,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:217},{&#34;s&#34;:188,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:215},{&#34;s&#34;:188,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:215},{&#34;s&#34;:188,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:215},{&#34;s&#34;:339,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:362},{&#34;s&#34;:339,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:362},{&#34;s&#34;:339,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:362},{&#34;s&#34;:339,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:364},{&#34;s&#34;:0,&#34;n&#34;:&#34;s&#34;,&#34;v&#34;:19.999999999999996,&#34;e&#34;:992},{&#34;s&#34;:81,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:188,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:418,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:339,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:418,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:446},{&#34;s&#34;:418,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:446},{&#34;s&#34;:418,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:446},{&#34;s&#34;:418,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:448},{&#34;s&#34;:567,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:568},{&#34;s&#34;:567,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:568},{&#34;s&#34;:567,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:568},{&#34;s&#34;:567,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:568},{&#34;s&#34;:568,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:593},{&#34;s&#34;:568,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:593},{&#34;s&#34;:568,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:593},{&#34;s&#34;:568,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:595},{&#34;s&#34;:704,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#008a0eff&#34;,&#34;e&#34;:730},{&#34;s&#34;:704,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:730},{&#34;s&#34;:704,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:730},{&#34;s&#34;:704,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:730},{&#34;s&#34;:568,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:704,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157}]}"><font color="#000000">bem como adiciona no array resumo[ ] caso possua configurado nos parâmetros iniciais. Faz tambem as validações de os dados estão corretos.&nbsp;&nbsp;</font></span></p>" style="text;whiteSpace=wrap;html=1;fontSize=19;fontFamily=Helvetica;fontColor=#E81313;" vertex="1" parent="1">
|
|
23
|
+
<mxGeometry x="162" y="273" width="917" height="142" as="geometry"/>
|
|
24
|
+
</mxCell>
|
|
25
|
+
<mxCell id="10" value="" style="shape=curlyBracket;whiteSpace=wrap;html=1;rounded=1;fontFamily=Helvetica;fontSize=13;fontColor=#ffffff;fillColor=none;strokeColor=#000099;strokeWidth=2;" vertex="1" parent="1">
|
|
26
|
+
<mxGeometry x="142" y="465" width="20" height="168" as="geometry"/>
|
|
27
|
+
</mxCell>
|
|
28
|
+
<mxCell id="11" value="<font style="font-size: 19px">getters</font>" style="text;strokeColor=none;fillColor=none;html=1;fontSize=24;fontStyle=1;verticalAlign=middle;align=center;fontFamily=Helvetica;fontColor=#000000;" vertex="1" parent="1">
|
|
29
|
+
<mxGeometry x="31" y="520" width="100" height="40" as="geometry"/>
|
|
30
|
+
</mxCell>
|
|
31
|
+
<mxCell id="13" value="<p style="font-family: &#34;helvetica&#34; ; font-style: normal ; font-weight: 400 ; letter-spacing: normal ; text-align: left ; text-indent: 0px ; text-transform: none ; word-spacing: 0px ; margin: 0px 0px 0px 8px ; font-size: 13px"><span data-lucid-type="application/vnd.lucid.text" data-lucid-content="{&#34;t&#34;:&#34;cabecalhoTabela: Verifica os campos da tabela que está marcado como mostrar=true e retorna para ser adicionado no componente &lt;Tabela&gt;.\nopcoes: Verifica os campos da tabela para montar as opções no componente &lt;Filtro&gt;, bem como tambem verifica quais estão marcados como mostrar=true e deixar como check e carregar no valorInicial. \nfiltroObrigatorio: Verifica se foi passado que o relatório tenha algum filtro que seja obrigatório e retorno um true ou false.\nfiltroSelecionado: Verifica se tem algum filtro selecionado que seja válido e adiciona, ou seja se tive algum filtro sem conteúdo não será adicionado. \noDataOrderBy: Pega o objeto que foi carregado no campoOrdenado que vem do &lt;Campo&gt; e monta um pedaço da url oData. \noDataSelect: Verifica os campos que estão selecionados e monta uma string para compor a url do oData..\noDataFilter: Verifica os filtros e monta uma string para compor a url do oData. \ntags: Verifica nos filtros selecionados os tipos de pesquisa para montar o array com as tags formatadas.&#34;,&#34;m&#34;:[{&#34;s&#34;:0,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:0,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:17},{&#34;s&#34;:0,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:18},{&#34;s&#34;:0,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:17},{&#34;s&#34;:0,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:17},{&#34;s&#34;:0,&#34;n&#34;:&#34;s&#34;,&#34;v&#34;:19.999999999999996,&#34;e&#34;:1017},{&#34;s&#34;:136,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:144},{&#34;s&#34;:136,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:144},{&#34;s&#34;:136,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:144},{&#34;s&#34;:136,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:144},{&#34;s&#34;:136,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:330,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:351},{&#34;s&#34;:330,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:351},{&#34;s&#34;:330,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:351},{&#34;s&#34;:330,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:352},{&#34;s&#34;:332,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:460,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:479},{&#34;s&#34;:460,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:479},{&#34;s&#34;:460,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:479},{&#34;s&#34;:460,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:480},{&#34;s&#34;:460,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:613,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:627},{&#34;s&#34;:613,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:627},{&#34;s&#34;:613,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:627},{&#34;s&#34;:613,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:627},{&#34;s&#34;:613,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:727,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:728},{&#34;s&#34;:729,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:742},{&#34;s&#34;:729,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:742},{&#34;s&#34;:729,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:742},{&#34;s&#34;:729,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:742},{&#34;s&#34;:729,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:832,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:844},{&#34;s&#34;:832,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:844},{&#34;s&#34;:832,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:844},{&#34;s&#34;:832,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:845},{&#34;s&#34;:832,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157},{&#34;s&#34;:913,&#34;n&#34;:&#34;fc&#34;,&#34;v&#34;:&#34;Bold&#34;,&#34;e&#34;:919},{&#34;s&#34;:913,&#34;n&#34;:&#34;fid&#34;,&#34;v&#34;:5,&#34;e&#34;:919},{&#34;s&#34;:913,&#34;n&#34;:&#34;b&#34;,&#34;v&#34;:true,&#34;e&#34;:919},{&#34;s&#34;:913,&#34;n&#34;:&#34;c&#34;,&#34;v&#34;:&#34;#1071e5ff&#34;,&#34;e&#34;:919},{&#34;s&#34;:913,&#34;n&#34;:&#34;p&#34;,&#34;v&#34;:1.127450980392157}]}"><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">cabecalhoTabela: </span> <font color="#000000">Verifica os campos da tabela que está marcado como mostrar=true e retorna para ser adicionado no componente &lt;Tabela&gt;.</font><br><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">opcoes: </span><font color="#000000">Verifica os campos da tabela para montar as opções no componente &lt;Filtro&gt;, bem como tambem verifica quais estão marcados como mostrar=true e deixar como check e carregar no valorInicial.</font><span style="color: rgb(16 , 113 , 229) ; font-weight: bold"> <br></span><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">filtroObrigatorio: </span> <font color="#000000">Verifica se foi passado que o relatório tenha algum filtro que seja obrigatório e retorno um true ou false.</font><br><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">filtroSelecionado:</span><font color="#000000"><span style="font-weight: bold"> </span> Verifica se tem algum filtro selecionado que seja válido e adiciona, ou seja se tive algum filtro sem conteúdo não será adicionado. </font><br><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">oDataOrderBy: </span><font color="#000000">Pega o objeto que foi carregado no campoOrdenado que vem do &lt;Campo&gt; e monta um pedaço da url oData. </font><span style="color: rgb(16 , 113 , 229)"> </span><span style="color: rgb(240 , 240 , 240)"><br></span><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">oDataSelect: </span><font color="#000000">Verifica os campos que estão selecionados e monta uma string para compor a url do oData.</font><br><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">oDataFilter:</span><font color="#000000"> Verifica os filtros e monta uma string para compor a url do oData. </font><br><span style="color: rgb(16 , 113 , 229) ; font-weight: bold">tags: </span><font color="#000000">Verifica nos filtros selecionados os tipos de pesquisa para montar o array com as tags formatadas.</font></span><br></p>" style="text;whiteSpace=wrap;html=1;fontSize=19;fontFamily=Helvetica;fontColor=#E81313;" vertex="1" parent="1">
|
|
32
|
+
<mxGeometry x="166" y="472" width="998" height="152" as="geometry"/>
|
|
33
|
+
</mxCell>
|
|
34
|
+
</root>
|
|
35
|
+
</mxGraphModel>
|
|
36
|
+
</diagram>
|
|
37
|
+
</mxfile>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nixweb/nixloc-ui",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.121",
|
|
4
4
|
"description": "Componentes UI",
|
|
5
5
|
"author": "Fábio Ávila <fabio@nixweb.com.br>",
|
|
6
6
|
"private": false,
|
|
@@ -10,12 +10,15 @@
|
|
|
10
10
|
"lint": "vue-cli-service lint"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@babel/polyfill": "^7.
|
|
13
|
+
"@babel/polyfill": "^7.12.1",
|
|
14
14
|
"@ckeditor/ckeditor5-vue2": "^2.0.0",
|
|
15
|
+
"axios": "^0.24.0",
|
|
15
16
|
"bootstrap-vue": "^2.0.0-rc.11",
|
|
16
|
-
"
|
|
17
|
+
"core-js": "^3.6.5",
|
|
18
|
+
"sass-loader": "^10.1.1",
|
|
17
19
|
"v-runtime-template": "^1.10.0",
|
|
18
20
|
"vodal": "^2.4.0",
|
|
21
|
+
"vue": "^2.6.11",
|
|
19
22
|
"vue-color": "^2.7.0",
|
|
20
23
|
"vue-currency-filter": "^3.3.0",
|
|
21
24
|
"vue-html2pdf": "^1.8.0",
|
|
@@ -26,6 +29,7 @@
|
|
|
26
29
|
"vue-multiselect": "^2.1.0",
|
|
27
30
|
"vue-numeric": "^2.4.1",
|
|
28
31
|
"vue-print-nb": "^1.7.5",
|
|
32
|
+
"vue-router": "^3.0.1",
|
|
29
33
|
"vue-simple-progress": "^1.1.1",
|
|
30
34
|
"vue-the-mask": "^0.11.1",
|
|
31
35
|
"vue-toasted": "^1.1.28",
|
|
@@ -33,7 +37,9 @@
|
|
|
33
37
|
"vue-upload-file": "^1.1.0",
|
|
34
38
|
"vue2-datepicker": "^2.13.0",
|
|
35
39
|
"vue2-editor": "^2.6.6",
|
|
36
|
-
"vuejs-ace-editor": "^1.0.1"
|
|
40
|
+
"vuejs-ace-editor": "^1.0.1",
|
|
41
|
+
"vuex": "^3.6.2",
|
|
42
|
+
"vuex-persistedstate": "^4.0.0"
|
|
37
43
|
},
|
|
38
44
|
"devDependencies": {
|
|
39
45
|
"@vue/cli-plugin-babel": "~4.5.0",
|
|
@@ -59,7 +65,7 @@
|
|
|
59
65
|
"rules": {}
|
|
60
66
|
},
|
|
61
67
|
"engines": {
|
|
62
|
-
"node": "
|
|
68
|
+
"node": "16.14.2",
|
|
63
69
|
"npm": ">= 3.0.0"
|
|
64
70
|
},
|
|
65
71
|
"browserslist": [
|
|
@@ -67,9 +73,5 @@
|
|
|
67
73
|
"last 2 versions",
|
|
68
74
|
"not dead"
|
|
69
75
|
],
|
|
70
|
-
"main": "babel.config.js"
|
|
71
|
-
"repository": {
|
|
72
|
-
"type": "git",
|
|
73
|
-
"url": "git+https://github.com/nixweb-sistemas/nixloc-ui.git"
|
|
74
|
-
}
|
|
76
|
+
"main": "babel.config.js"
|
|
75
77
|
}
|
package/public/index.html
CHANGED
|
@@ -6,13 +6,11 @@
|
|
|
6
6
|
<meta name="viewport" content="width=device-width,initial-scale=1.0">
|
|
7
7
|
<link rel="shortcut icon" type="image/png" href="/favicon.ico" />
|
|
8
8
|
<title>
|
|
9
|
-
Nixloc
|
|
9
|
+
Nixloc Componentes UI
|
|
10
10
|
</title>
|
|
11
11
|
|
|
12
12
|
<link rel="stylesheet" type="text/css" href="/styles/app.css">
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
<script src="/js/menu.js"></script>
|
|
13
|
+
|
|
16
14
|
</head>
|
|
17
15
|
|
|
18
16
|
<body>
|
package/public/styles/app.css
CHANGED
package/public/js/menu.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
!function (e) { var t = {}; function n(s) { if (t[s]) return t[s].exports; var i = t[s] = { i: s, l: !1, exports: {} }; return e[s].call(i.exports, i, i.exports, n), i.l = !0, i.exports } n.m = e, n.c = t, n.d = function (e, t, s) { n.o(e, t) || Object.defineProperty(e, t, { enumerable: !0, get: s }) }, n.r = function (e) { "undefined" != typeof Symbol && Symbol.toStringTag && Object.defineProperty(e, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(e, "__esModule", { value: !0 }) }, n.t = function (e, t) { if (1 & t && (e = n(e)), 8 & t) return e; if (4 & t && "object" == typeof e && e && e.__esModule) return e; var s = Object.create(null); if (n.r(s), Object.defineProperty(s, "default", { enumerable: !0, value: e }), 2 & t && "string" != typeof e) for (var i in e) n.d(s, i, function (t) { return e[t] }.bind(null, i)); return s }, n.n = function (e) { var t = e && e.__esModule ? function () { return e.default } : function () { return e }; return n.d(t, "a", t), t }, n.o = function (e, t) { return Object.prototype.hasOwnProperty.call(e, t) }, n.p = "", n(n.s = 0) }([function (e, t, n) {
|
|
2
|
-
"use strict"; n.r(t); var s = { hooks: {}, extensions: [], navbar: { add: !0, title: "Menu", titleLink: "parent" }, slidingSubmenus: !0 }; var i = { classNames: { divider: "Divider", nolistview: "NoListview", nopanel: "NoPanel", panel: "Panel", selected: "Selected", vertical: "Vertical" }, language: null, panelNodetype: ["ul", "ol", "div"], screenReader: { closeSubmenu: "Close submenu", openSubmenu: "Open submenu", toggleSubmenu: "Toggle submenu" } }; const a = (e, t) => { "object" != o(e) && (e = {}), "object" != o(t) && (t = {}); for (let n in t) t.hasOwnProperty(n) && (void 0 === e[n] ? e[n] = t[n] : "object" == o(e[n]) && a(e[n], t[n])); return e }, o = e => ({}.toString.call(e).match(/\s([a-zA-Z]+)/)[1].toLowerCase()), r = () => "mm-" + l++; let l = 0; const m = e => "mm-" == e.slice(0, 3) ? e.slice(3) : e, c = {}, d = (e, t) => { void 0 === c[t] && (c[t] = {}), a(c[t], e) }; var h = { "Close submenu": "بستن زیرمنو", Menu: "منو", "Open submenu": "بازکردن زیرمنو", "Toggle submenu": "سوییچ زیرمنو" }, p = { "Close submenu": "Submenu sluiten", Menu: "Menu", "Open submenu": "Submenu openen", "Toggle submenu": "Submenu wisselen" }, u = { "Close submenu": "Fechar submenu", Menu: "Menu", "Open submenu": "Abrir submenu", "Toggle submenu": "Alternar submenu" }, f = { "Close submenu": "Закрыть подменю", Menu: "Меню", "Open submenu": "Открыть подменю", "Toggle submenu": "Переключить подменю" }, b = { "Close submenu": "Zatvoriť submenu", Menu: "Menu", "Open submenu": "Otvoriť submenu", "Toggle submenu": "Prepnúť submenu" }; const v = e => { const t = e.split("."), n = document.createElement(t.shift()); return n.classList.add(...t), n }, g = (e, t) => t.length ? [].slice.call(e.querySelectorAll(t)) : [], L = (e, t) => { const n = Array.prototype.slice.call(e.children); return t ? n.filter(e => e.matches(t)) : n }, _ = e => e.filter(e => !e.matches(".mm-hidden")), E = e => { let t = []; return _(e).forEach(e => { t.push(...L(e, "a.mm-listitem__text")) }), t.filter(e => !e.matches(".mm-btn--next")) }, y = (e, t, n) => { e.matches("." + t) && e.classList.add(n) }; let w = {}; const P = (e, t, n) => { "number" == typeof e && (e = "(min-width: " + e + "px)"), w[e] = w[e] || [], w[e].push({ yes: t, no: n }) }, S = (e, t) => { var n = t.matches ? "yes" : "no"; for (let t = 0; t < w[e].length; t++)w[e][t][n]() }; d({ "Close submenu": "Untermenü schließen", Menu: "Menü", "Open submenu": "Untermenü öffnen", "Toggle submenu": "Untermenü wechseln" }, "de"), d(h, "fa"), d(p, "nl"), d(u, "pt_br"), d(f, "ru"), d(b, "sk"); class x { constructor(e, t, n) { return this.opts = a(t, s), this.conf = a(n, i), this._api = ["i18n", "bind", "openPanel", "closePanel", "setSelected"], this.node = {}, this.hook = {}, this.node.menu = "string" == typeof e ? document.querySelector(e) : e, "function" == typeof this._deprecatedWarnings && this._deprecatedWarnings(), this.trigger("init:before"), this._initObservers(), this._initAddons(), this._initExtensions(), this._initHooks(), this._initAPI(), this._initMenu(), this._initPanels(), this._initOpened(), (() => { for (let e in w) { let t = window.matchMedia(e); S(e, t), t.onchange = n => { S(e, t) } } })(), this.trigger("init:after"), this } openPanel(e, t = !0, n = !0) { if (e) { if (e.matches(".mm-panel") || (e = e.closest(".mm-panel")), this.trigger("openPanel:before", [e, { animation: t, setfocus: n }]), e.parentElement.matches(".mm-listitem--vertical")) e.parentElement.classList.add("mm-listitem--opened"); else { const s = L(this.node.pnls, ".mm-panel--opened")[0]; e.matches(".mm-panel--parent") && s && s.classList.add("mm-panel--highest"); const i = ["mm-panel--opened", "mm-panel--parent"], a = []; t ? i.push("mm-panel--noanimation") : a.push("mm-panel--noanimation"), L(this.node.pnls, ".mm-panel").forEach(e => { e.classList.add(...a), e.classList.remove(...i), e !== s && e.classList.remove("mm-panel--highest") }), e.classList.add("mm-panel--opened"); let o = g(this.node.pnls, "#" + e.dataset.mmParent)[0]; for (; o;)o = o.closest(".mm-panel"), o.classList.add("mm-panel--parent"), o = g(this.node.pnls, "#" + o.dataset.mmParent)[0]; n && this.node.pnls.focus() } this.trigger("openPanel:after", [e, { animation: t, setfocus: n }]) } } closePanel(e, t = !0) { if (e) { if (this.trigger("closePanel:before", [e]), e.parentElement.matches(".mm-listitem--vertical")) e.parentElement.classList.remove("mm-listitem--opened"); else if (e.dataset.mmParent) { const n = g(this.node.pnls, "#" + e.dataset.mmParent)[0]; this.openPanel(n, t) } else { const n = L(this.node.pnls, ".mm-panel")[0]; e !== n && this.openPanel(n, t) } this.trigger("closePanel:after", [e]) } } togglePanel(e) { let t = "openPanel"; (e.parentElement.matches(".mm-listitem--opened") || e.matches(".mm-panel--opened")) && (t = "closePanel"), this[t](e) } setSelected(e) { this.trigger("setSelected:before", [e]), g(this.node.menu, ".mm-listitem--selected").forEach(e => { e.classList.remove("mm-listitem--selected") }), e.classList.add("mm-listitem--selected"), this.trigger("setSelected:after", [e]) } bind(e, t) { this.hook[e] = this.hook[e] || [], this.hook[e].push(t) } trigger(e, t) { if (this.hook[e]) for (var n = 0, s = this.hook[e].length; n < s; n++)this.hook[e][n].apply(this, t) } _initObservers() { this.panelObserver = new MutationObserver(e => { e.forEach(e => { e.addedNodes.forEach(e => { e.matches(this.conf.panelNodetype.join(", ")) && this._initListview(e) }) }) }), this.listviewObserver = new MutationObserver(e => { e.forEach(e => { e.addedNodes.forEach(e => { this._initListitem(e) }) }) }), this.listitemObserver = new MutationObserver(e => { e.forEach(e => { e.addedNodes.forEach(e => { console.log(e), (null == e ? void 0 : e.matches(this.conf.panelNodetype.join(", "))) && this._initSubPanel(e) }) }) }) } _initAPI() { const e = this; this.API = {}, this._api.forEach(t => { this.API[t] = function () { return e[t].apply(e, arguments) } }), this.node.menu.mmApi = this.API } _initHooks() { for (let e in this.opts.hooks) this.bind(e, this.opts.hooks[e]) } _initAddons() { this.trigger("initAddons:before"); for (let e in x.addons) x.addons[e].call(this); this.trigger("initAddons:after") } _initExtensions() { this.trigger("initExtensions:before"), "array" == o(this.opts.extensions) && (this.opts.extensions = { all: this.opts.extensions }), Object.keys(this.opts.extensions).forEach(e => { let t = this.opts.extensions[e].map(e => "mm-menu--" + e); t.length && P(e, () => { this.node.menu.classList.add(...t) }, () => { this.node.menu.classList.remove(...t) }) }), this.trigger("initExtensions:after") } _initMenu() { this.trigger("initMenu:before"), this.node.wrpr = this.node.wrpr || this.node.menu.parentElement, this.node.wrpr.classList.add("mm-wrapper"), this.node.menu.classList.add("mm-menu"), this.node.menu.id = this.node.menu.id || r(), this.node.menu.setAttribute("tabindex", "-1"); const e = L(this.node.menu).filter(e => e.matches(this.conf.panelNodetype.join(", "))); this.node.pnls = v("div.mm-panels"), this.node.menu.append(this.node.pnls), this.node.pnls.setAttribute("tabindex", "-1"), e.forEach(e => { this._initPanel(e) }), this.trigger("initMenu:after") } _initPanels() { this.trigger("initPanels:before"), this.node.menu.addEventListener("click", e => { var t, n; const s = (null === (n = null === (t = e.target) || void 0 === t ? void 0 : t.closest("a[href]")) || void 0 === n ? void 0 : n.getAttribute("href")) || ""; if ("#" === s.slice(0, 1)) try { const t = g(this.node.menu, s)[0]; t && (e.preventDefault(), this.togglePanel(t)) } catch (e) { } }, { capture: !0 }), this.trigger("initPanels:after") } _initPanel(e) { var t; if (!e.matches(".mm-panel") && (y(e, this.conf.classNames.panel, "mm-panel"), y(e, this.conf.classNames.nopanel, "mm-nopanel"), !e.matches(".mm-nopanel"))) { if (this.trigger("initPanel:before", [e]), e.id = e.id || r(), e.matches("ul, ol")) { const t = v("div"); t.id = e.id, e.removeAttribute("id"), [].slice.call(e.classList).filter(e => "mm-" === e.slice(0, 3)).forEach(n => { t.classList.add(n), e.classList.remove(n) }), Object.keys(e.dataset).filter(e => "mm" === e.slice(0, 2)).forEach(n => { t.dataset[n] = e.dataset[n], delete e.dataset[n] }), e.before(t), t.append(e), e = t } return e.classList.add("mm-panel"), (null === (t = e.parentElement) || void 0 === t ? void 0 : t.matches(".mm-listitem--vertical")) || this.node.pnls.append(e), this._initNavbar(e), L(e, "ul, ol").forEach(e => { this._initListview(e) }), this.panelObserver.observe(e, { childList: !0 }), this.trigger("initPanel:after", [e]), e } } _initNavbar(e) { if (L(e, ".mm-navbar").length) return; let t = null, n = null; if (e.dataset.mmParent) for (t = g(this.node.pnls, "#" + e.dataset.mmParent)[0], n = t.closest(".mm-panel"); n.closest(".mm-listitem--vertical");)n = n.parentElement.closest(".mm-panel"); if (null == t ? void 0 : t.matches(".mm-listitem--vertical")) return; this.trigger("initNavbar:before", [e]); const s = v("div.mm-navbar"); if (this.opts.navbar.add || s.classList.add("mm-hidden"), n) { const e = v("a.mm-btn.mm-btn--prev.mm-navbar__btn"); e.href = "#" + n.id, e.title = this.i18n(this.conf.screenReader.closeSubmenu), s.append(e) } let i = null; t ? i = L(t, ".mm-listitem__text")[0] : n && (i = g(n, 'a[href="#' + e.id + '"]')[0]); const a = v("a.mm-navbar__title"); switch (a.tabIndex = -1, a.ariaHidden = "true", this.opts.navbar.titleLink) { case "anchor": i && (a.href = i.getAttribute("href")); break; case "parent": n && (a.href = "#" + n.id) }const o = v("span"); var r; o.innerHTML = e.dataset.mmTitle || ((r = i) ? [].slice.call(r.childNodes).filter(e => e.nodeType === Node.TEXT_NODE).map(e => e.nodeValue.trim()).join(" ") : "") || this.i18n(this.opts.navbar.title) || this.i18n("Menu"), e.prepend(s), s.append(a), a.append(o), this.trigger("initNavbar:after", [e]) } _initListview(e) { ["htmlulistelement", "htmlolistelement"].includes(o(e)) && (e.matches(".mm-listview") || (y(e, this.conf.classNames.nolistview, "mm-nolistview"), e.matches(".mm-nolistview") || (this.trigger("initListview:before", [e]), e.classList.add("mm-listview"), L(e).forEach(e => { this._initListitem(e) }), this.listviewObserver.observe(e, { childList: !0 }), this.trigger("initListview:after", [e])))) } _initListitem(e) { ["htmllielement"].includes(o(e)) && (e.matches(".mm-listitem") || (y(e, this.conf.classNames.divider, "mm-divider"), e.matches(".mm-divider") || (this.trigger("initListitem:before", [e]), e.classList.add("mm-listitem"), y(e, this.conf.classNames.selected, "mm-listitem--selected"), L(e, "a, span").forEach(e => { e.classList.add("mm-listitem__text") }), L(e, this.conf.panelNodetype.join(", ")).forEach(e => { this._initSubPanel(e) }), this.listitemObserver.observe(e, { childList: !0 }), this.trigger("initListitem:after", [e])))) } _initSubPanel(e) { if (e.matches(".mm-panel")) return; const t = e.parentElement; (e.matches("." + this.conf.classNames.vertical) || !this.opts.slidingSubmenus) && t.classList.add("mm-listitem--vertical"), t.id = t.id || r(), e.id = e.id || r(), t.dataset.mmChild = e.id, e.dataset.mmParent = t.id; let n = L(t, ".mm-btn")[0]; n || (n = v("a.mm-btn.mm-btn--next.mm-listitem__btn"), L(t, "a, span").forEach(e => { e.matches("span") ? (n.classList.add("mm-listitem__text"), n.innerHTML = e.innerHTML, t.insertBefore(n, e.nextElementSibling), e.remove()) : t.insertBefore(n, e.nextElementSibling) }), n.title = this.i18n(this.conf.screenReader[t.matches(".mm-listitem--vertical") ? "toggleSubmenu" : "openSubmenu"])), n.href = "#" + e.id, this._initPanel(e) } _initOpened() { this.trigger("initOpened:before"); const e = g(this.node.pnls, ".mm-listitem--selected").pop(); let t = L(this.node.pnls, ".mm-panel")[0]; e && (this.setSelected(e), t = e.closest(".mm-panel")), this.openPanel(t, !1, !1), this.trigger("initOpened:after") } i18n(e) { return ((e, t) => "string" == typeof t && void 0 !== c[t] && c[t][e] || e)(e, this.conf.language) } static i18n(e = {}, t = "") { if (!e || !t) return c; d(e, t) } } x.addons = {}, x.node = {}, x.vars = {}; var M = { use: !0 }; var k = { clone: !1, menu: { insertMethod: "prepend", insertSelector: "body" }, page: { nodetype: "div", selector: null, noSelector: [] }, screenReader: { closeMenu: "Close menu", openMenu: "Open menu" } }; x.prototype.open = function () { if (!this.node.menu.matches(".mm-menu--opened")) { this.trigger("open:before"); this.node.wrpr.classList.add("mm-wrapper--opened"), this.node.menu.classList.add("mm-menu--opened"), this.node.wrpr.classList.add("mm-wrapper--opened"), this.node.menu.focus(), this.trigger("open:after") } }, x.prototype.close = function () { var e; if (!this.node.menu.matches(".mm-menu--opened")) return; this.trigger("close:before"), this.node.menu.classList.remove("mm-menu--opened"), this.node.wrpr.classList.remove("mm-wrapper--opened"); null === (e = document.querySelector(`[href="#${this.node.menu.id}"]`) || this.node.page || null) || void 0 === e || e.focus(), this.trigger("close:after") }, x.prototype.setPage = function (e) { var t = this.conf.offCanvas; if (!e) { let n = "string" == typeof t.page.selector ? g(document.body, t.page.selector) : L(document.body, t.page.nodetype); if (n = n.filter(e => !e.matches(".mm-menu, .mm-wrapper__blocker")), t.page.noSelector.length && (n = n.filter(e => !e.matches(t.page.noSelector.join(", ")))), n.length > 1) { let e = v("div"); n[0].before(e), n.forEach(t => { e.append(t) }), n = [e] } e = n[0] } this.trigger("setPage:before", [e]), e.setAttribute("tabindex", "-1"), e.classList.add("mm-page", "mm-slideout"), e.id = e.id || r(), x.node.blck.setAttribute("href", "#" + e.id), x.node.page = e, this.trigger("setPage:after", [e]) }; var T = { fix: !0 }; const C = "ontouchstart" in window || !!navigator.msMaxTouchPoints || !1; var O = { close: !1, open: !1 }; var N = { add: !1 }; var A = { use: !1, top: [], bottom: [], position: "left", type: "default" }; var j = { add: !1, blockPanel: !0, visible: 3 }; var H = { breadcrumbs: { separator: "/", removeFirst: !1 } }; function q() { this.opts.navbars = this.opts.navbars || [], this.conf.navbars = this.conf.navbars || {}, a(this.conf.navbars, H); let e = this.opts.navbars; if (void 0 !== e && (e instanceof Array || (e = [e]), e.length)) { var t = {}; e.forEach(e => { if (!(e = function (e) { return "boolean" == typeof e && e && (e = {}), "object" != typeof e && (e = {}), void 0 === e.content && (e.content = ["prev", "title"]), e.content instanceof Array || (e.content = [e.content]), void 0 === e.use && (e.use = !0), e }(e)).use) return; const n = v("div.mm-navbar"); let { position: s } = e; "bottom" !== s && (s = "top"), t[s] || (t[s] = v("div.mm-navbars.mm-navbars--" + s)), t[s].append(n); for (let t = 0, s = e.content.length; t < s; t++) { const s = e.content[t]; if ("string" == typeof s) { const e = q.navbarContents[s]; if ("function" == typeof e) e.call(this, n); else { let e = v("span"); e.innerHTML = s; const t = L(e); 1 == t.length && (e = t[0]), n.append(e) } } else n.append(s) } if ("string" == typeof e.type) { const t = q.navbarTypes[e.type]; "function" == typeof t && t.call(this, n) } let i = () => { n.classList.remove("mm-hidden") }, a = () => { n.classList.add("mm-hidden") }; "boolean" == typeof e.use ? this.bind("initMenu:after", i) : P(e.use, i, a) }), this.bind("initMenu:after", () => { for (let e in t) this.node.pnls["bottom" == e ? "after" : "before"](t[e]) }) } } q.navbarContents = { breadcrumbs: function (e) { var t = v("div.mm-navbar__breadcrumbs"); e.append(t), this.bind("initNavbar:after", e => { if (!e.querySelector(".mm-navbar__breadcrumbs")) { L(e, ".mm-navbar")[0].classList.add("mm-hidden"); for (var t = [], n = v("span.mm-navbar__breadcrumbs"), s = e, i = !0; s;) { if (!(s = s.closest(".mm-panel")).parentElement.matches(".mm-listitem--vertical")) { let e = g(s, ".mm-navbar__title span")[0]; if (e) { let n = e.textContent; n.length && t.unshift(i ? `<span>${n}</span>` : `<a \n href="#${s.id}" \n title="${this.i18n(this.conf.screenReader.openSubmenu)}"\n >${n}</a>`) } i = !1 } s = g(this.node.pnls, "#" + s.dataset.mmParent)[0] } this.conf.navbars.breadcrumbs.removeFirst && t.shift(), n.innerHTML = t.join('<span class="mm-separator">' + this.conf.navbars.breadcrumbs.separator + "</span>"), L(e, ".mm-navbar")[0].append(n) } }), this.bind("openPanel:before", e => { var n = e.querySelector(".mm-navbar__breadcrumbs"); t.innerHTML = n ? n.innerHTML : "" }) }, close: function (e) { const t = v("a.mm-btn.mm-btn--close.mm-navbar__btn"); t.title = this.i18n(this.conf.offCanvas.screenReader.closeMenu), e.append(t), this.bind("setPage:after", e => { t.href = "#" + e.id }) }, prev: function (e) { let t = v("a.mm-btn.mm-hidden"); e.append(t), this.bind("initNavbar:after", e => { L(e, ".mm-navbar")[0].classList.add("mm-hidden") }), this.bind("openPanel:before", e => { if (e.parentElement.matches(".mm-listitem--vertical")) return; t.classList.add("mm-hidden"); const n = e.querySelector(".mm-navbar__btn.mm-btn--prev"); if (n) { const e = n.cloneNode(!0); t.after(e), t.remove(), t = e } }) }, searchfield: function (e) { let t = v("div.mm-navbar__searchfield"); t.id = r(), e.append(t), this.opts.searchfield = this.opts.searchfield || {}, this.opts.searchfield.add = !0, this.opts.searchfield.addTo = "#" + t.id }, title: function (e) { let t = v("a.mm-navbar__title"); e.append(t), this.bind("openPanel:before", e => { if (e.parentElement.matches(".mm-listitem--vertical")) return; const n = e.querySelector(".mm-navbar__title"); if (n) { const e = n.cloneNode(!0); t.after(e), t.remove(), t = e } }) } }, q.navbarTypes = { tabs: function (e) { function t(n) { const s = L(e, `.mm-navbar__tab[href="#${n.id}"]`)[0]; if (s) s.classList.add("mm-navbar__tab--selected"), s.ariaExpanded = "true"; else { const e = g(this.node.pnls, "#" + n.dataset.mmParent)[0]; e && t.call(this, e.closest(".mm-panel")) } } e.classList.add("mm-navbar--tabs"), e.closest(".mm-navbars").classList.add("mm-navbars--has-tabs"), L(e, "a").forEach(e => { e.classList.add("mm-navbar__tab") }), this.bind("openPanel:before", n => { L(e, "a").forEach(e => { e.classList.remove("mm-navbar__tab--selected"), e.ariaExpanded = "false" }), t.call(this, n) }), this.bind("initPanels:after", () => { e.addEventListener("click", e => { var t, n, s; const i = null === (n = null === (t = e.target) || void 0 === t ? void 0 : t.closest(".mm-navbar__tab")) || void 0 === n ? void 0 : n.getAttribute("href"); try { null === (s = g(this.node.pnls, i + ".mm-panel")[0]) || void 0 === s || s.classList.add("mm-panel--noanimation") } catch (e) { } }, { capture: !0 }) }) } }; var I = { scroll: !1, update: !1 }; var R = { scrollOffset: 0, updateOffset: 50 }; var B = { add: !1, addTo: "panels", noResults: "No results found.", placeholder: "Search", searchIn: "panels", splash: "", title: "Search" }; var D = { cancel: !0, clear: !0, form: {}, input: {}, panel: {}, submit: !1 }, F = { cancel: "انصراف", "Cancel searching": "لغو جستجو", "Clear searchfield": "پاک کردن فیلد جستجو", "No results found.": "نتیجهای یافت نشد.", Search: "جستجو" }, $ = { cancel: "annuleren", "Cancel searching": "Zoeken annuleren", "Clear searchfield": "Zoekveld leeg maken", "No results found.": "Geen resultaten gevonden.", Search: "Zoeken" }, Z = { cancel: "cancelar", "Cancel searching": "Cancelar pesquisa", "Clear searchfield": "Limpar campo de pesquisa", "No results found.": "Nenhum resultado encontrado.", Search: "Buscar" }, z = { cancel: "отменить", "Cancel searching": "Отменить поиск", "Clear searchfield": "Очистить поле поиска", "No results found.": "Ничего не найдено.", Search: "Найти" }, V = { cancel: "zrušiť", "Cancel searching": "Zrušiť vyhľadávanie", "Clear searchfield": "Vymazať pole vyhľadávania", "No results found.": "Neboli nájdené žiadne výsledky.", Search: "Vyhľadávanie" }; d({ cancel: "abbrechen", "Cancel searching": "Suche abbrechen", "Clear searchfield": "Suchfeld löschen", "No results found.": "Keine Ergebnisse gefunden.", Search: "Suche" }, "de"), d(F, "fa"), d($, "nl"), d(Z, "pt_br"), d(z, "ru"), d(V, "sk"); const U = function () { const e = this.opts.searchfield, t = this.conf.searchfield; let n = L(this.node.pnls, ".mm-panel--search")[0]; return n || (n = v("div.mm-panel--search"), ee(n, t.panel), e.title.length && (n.dataset.mmTitle = this.i18n(e.title)), n.append(v("ul")), this._initPanel(n), n) }, Y = function (e) { const t = this.opts.searchfield; if (e.matches(t.addTo)) { const t = e.matches(".mm-panel--search"); if (!g(e, ".mm-searchfield").length) { const n = K.call(this, t); t && n.classList.add("mm-searchfield--cancelable"), e.prepend(n), W.call(this, n) } } if (t.splash.length && e.matches(".mm-panel--search") && !g(e, ".mm-panel__splash").length) { const n = v("div.mm-panel__splash"); n.innerHTML = t.splash, e.append(n) } if (t.noResults.length && !g(e, ".mm-panel__noresults").length) { const n = v("div.mm-panel__noresults"); n.innerHTML = this.i18n(t.noResults), e.append(n) } }, K = function (e = !1) { const t = this.opts.searchfield, n = this.conf.searchfield, s = v("form.mm-searchfield"); ee(s, n.form); const i = v("div.mm-searchfield__input"); s.append(i); const a = v("input"); if (i.append(a), a.type = "text", a.autocomplete = "off", a.placeholder = this.i18n(t.placeholder), a.setAttribute("aria-label", this.i18n(t.placeholder)), ee(a, n.input), n.submit) { const e = v("button.mm-btnreset.mm-btn.mm-btn--next.mm-searchfield__btn"); e.type = "submit", i.append(e) } else if (n.clear) { const e = v("button.mm-btnreset.mm-btn.mm-btn--close.mm-searchfield__btn"); e.type = "reset", e.title = this.i18n("Clear searchfield"), i.append(e), s.addEventListener("reset", () => { window.requestAnimationFrame(() => { a.dispatchEvent(new Event("input")) }) }) } if (n.cancel && e) { const e = v("a.mm-searchfield__cancel"); e.href = "#", e.title = this.i18n("Cancel searching"), e.textContent = this.i18n("cancel"), s.append(e), e.addEventListener("click", () => { this.closePanel(L(this.node.pnls, ".mm-panel--search")[0], !1) }) } return s }, W = function (e) { const t = this.opts.searchfield, n = e.closest(".mm-panel") || g(this.node.pnls, ".mm-panel--search")[0], s = g(e, "input")[0]; let i = n.matches(".mm-panel--search") ? g(this.node.pnls, t.searchIn) : [n]; i = i.filter(e => !e.matches(".mm-panel--search")); const a = () => { const t = s.value.toLowerCase().trim(), a = []; if (i.forEach(e => { e.scrollTop = 0, a.push(...g(e, ".mm-listitem")) }), t.length) { this.trigger("search:before"), e.classList.add("mm-searchfield--searching"), n.classList.add("mm-panel--searching"), a.forEach(e => { const n = L(e, ".mm-listitem__text")[0]; var s; (!n || (s = n, Array.prototype.slice.call(s.childNodes).filter(e => 3 == e.nodeType).map(e => e.textContent).join(" ")).toLowerCase().indexOf(t) > -1) && (e.dataset.mmSearchresult = t) }); let s = 0; s = n.matches(".mm-panel--search") ? G(n, t, i) : J(t, i), n.classList[0 == s ? "add" : "remove"]("mm-panel--noresults"), this.trigger("search:after") } else this.trigger("clear:before"), e.classList.remove("mm-searchfield--searching"), n.classList.remove("mm-panel--searching", "mm-panel--noresults"), n.matches(".mm-panel--search") ? X(n) : Q(i), this.trigger("clear:after") }; s.addEventListener("input", a), a() }, G = (e, t, n) => { const s = g(e, ".mm-listview")[0]; s.innerHTML = ""; let i = 0; return n.forEach(e => { const n = g(e, `[data-mm-searchresult="${t}"]`); if (i += n.length, n.length) { const t = g(e, ".mm-navbar__title")[0]; if (t) { const e = v("li.mm-divider"); e.innerHTML = t.innerHTML, s.append(e) } n.forEach(e => { s.append(e.cloneNode(!0)) }) } }), i }, X = e => { g(e, ".mm-listview")[0].innerHTML = "" }, J = (e, t) => { let n = 0; return t.forEach(t => { const s = g(t, `[data-mm-searchresult="${e}"]`); n += s.length, s.length && s.forEach(t => { const n = ((e, t) => { let n = [], s = e.previousElementSibling; for (; s;)t && !s.matches(t) || n.push(s), s = s.previousElementSibling; return n })(t, ".mm-divider")[0]; n && (n.dataset.mmSearchresult = e) }), g(t, ".mm-listitem, .mm-divider").forEach(t => { t.classList[t.dataset.mmSearchresult === e ? "remove" : "add"]("mm-hidden") }) }), n }, Q = e => { e.forEach(e => { g(e, ".mm-listitem, .mm-divider").forEach(e => { e.classList.remove("mm-hidden") }) }) }, ee = (e, t) => { t && Object.keys(t).forEach(n => { e[n] = t[n] }) }; var te = { add: !1, addTo: "panels" }; var ne = { current: !0, hover: !1, parent: !1 }; var se = { collapsed: { use: !1, blockMenu: !0 }, expanded: { use: !1, initial: "open" } };
|
|
3
|
-
/*!
|
|
4
|
-
* mmenu.js
|
|
5
|
-
* mmenujs.com
|
|
6
|
-
*
|
|
7
|
-
* Copyright (c) Fred Heusschen
|
|
8
|
-
* frebsite.nl
|
|
9
|
-
*/
|
|
10
|
-
x.addons = { offcanvas: function () { this.opts.offCanvas = this.opts.offCanvas || {}, this.conf.offCanvas = this.conf.offCanvas || {}; const e = a(this.opts.offCanvas, M), t = a(this.conf.offCanvas, k); e.use && (this._api.push("open", "close", "setPage"), x.node.blck || this.bind("initMenu:before", () => { const e = v("a.mm-wrapper__blocker.mm-slideout"); e.id = r(), e.title = this.i18n(t.screenReader.closeMenu), e.setAttribute("tabindex", "-1"), document.querySelector(t.menu.insertSelector).append(e), x.node.blck = e }), this.bind("initMenu:before", () => { t.clone && (this.node.menu = this.node.menu.cloneNode(!0), this.node.menu.id && (this.node.menu.id = "mm-" + this.node.menu.id), g(this.node.menu, "[id]").forEach(e => { e.id = "mm-" + e.id })), this.node.wrpr = document.querySelector(t.menu.insertSelector), document.querySelector(t.menu.insertSelector)[t.menu.insertMethod](this.node.menu) }), this.bind("initMenu:after", () => { this.setPage(x.node.page), this.node.menu.classList.add("mm-menu--offcanvas"); let e = window.location.hash; if (e) { let t = m(this.node.menu.id); t && t == e.slice(1) && setTimeout(() => { this.open() }, 1e3) } }), document.addEventListener("click", e => { var t; switch (null === (t = e.target.closest("a")) || void 0 === t ? void 0 : t.getAttribute("href")) { case "#" + m(this.node.menu.id): e.preventDefault(), this.open(); break; case "#" + m(x.node.page.id): e.preventDefault(), this.close() } }), document.addEventListener("keyup", e => { "Escape" == e.key && this.close() }), document.addEventListener("keyup", e => { var t; "Tab" == e.key && this.node.menu.matches(".mm-menu--opened") && !(null === (t = document.activeElement) || void 0 === t ? void 0 : t.closest("#" + this.node.menu.id)) && (console.log(document.activeElement), this.close()) })) }, scrollBugFix: function () { if (!C || !this.opts.offCanvas.use) return; this.opts.scrollBugFix = this.opts.scrollBugFix || {}; if (!a(this.opts.scrollBugFix, T).fix) return; const e = (e => { let t = "", n = null; return e.addEventListener("touchstart", e => { 1 === e.touches.length && (t = "", n = e.touches[0].pageY) }), e.addEventListener("touchend", e => { 0 === e.touches.length && (t = "", n = null) }), e.addEventListener("touchmove", e => { if (t = "", n && 1 === e.touches.length) { const s = e.changedTouches[0].pageY; s > n ? t = "down" : s < n && (t = "up"), n = s } }), { get: () => t } })(this.node.menu); this.node.menu.addEventListener("scroll", e => { e.preventDefault(), e.stopPropagation() }, { passive: !1 }), this.node.menu.addEventListener("touchmove", t => { let n = t.target.closest(".mm-panel, .mm-iconbar__top, .mm-iconbar__bottom"); n && n.closest(".mm-listitem--vertical") && (n = ((e, t) => { let n = [], s = e.parentElement; for (; s;)n.push(s), s = s.parentElement; return t ? n.filter(e => e.matches(t)) : n })(n, ".mm-panel").pop()), n ? (n.scrollHeight === n.offsetHeight || 0 == n.scrollTop && "down" == e.get() || n.scrollHeight == n.scrollTop + n.offsetHeight && "up" == e.get()) && t.stopPropagation() : t.stopPropagation() }, { passive: !1 }), this.bind("open:after", () => { var e = L(this.node.pnls, ".mm-panel--opened")[0]; e && (e.scrollTop = 0) }), window.addEventListener("orientationchange", e => { var t = L(this.node.pnls, ".mm-panel--opened")[0]; t && (t.scrollTop = 0, t.style["-webkit-overflow-scrolling"] = "auto", t.style["-webkit-overflow-scrolling"] = "touch") }) }, backButton: function () { if (this.opts.backButton = this.opts.backButton || {}, !this.opts.offCanvas.use) return; const e = a(this.opts.backButton, O), t = "#" + this.node.menu.id; if (e.close) { var n = []; const e = () => { n = [t], L(this.node.pnls, ".mm-panel--opened, .mm-panel--parent").forEach(e => { n.push("#" + e.id) }) }; this.bind("open:after", () => { history.pushState(null, document.title, t) }), this.bind("open:after", e), this.bind("openPanel:after", e), this.bind("close:after", () => { n = [], history.back(), history.pushState(null, document.title, location.pathname + location.search) }), window.addEventListener("popstate", e => { if (this.node.menu.matches(".mm-menu--opened") && n.length) { var s = (n = n.slice(0, -1))[n.length - 1]; s == t ? this.close() : (this.openPanel(this.node.menu.querySelector(s)), history.pushState(null, document.title, t)) } }) } e.open && window.addEventListener("popstate", e => { this.node.menu.matches(".mm-menu--opened") || location.hash != t || this.open() }) }, counters: function () { this.opts.counters = this.opts.counters || {}; if (!a(this.opts.counters, N).add) return; const e = e => { const t = this.node.pnls.querySelector("#" + e.dataset.mmParent); if (!t) return; const n = t.querySelector(".mm-counter"); if (!n) return; const s = []; L(e, ".mm-listview").forEach(e => { s.push(...L(e)) }), n.innerHTML = _(s).length.toString() }, t = new MutationObserver(t => { t.forEach(t => { "class" == t.attributeName && e(t.target.closest(".mm-panel")) }) }); this.bind("initListview:after", t => { const n = t.closest(".mm-panel"), s = this.node.pnls.querySelector("#" + n.dataset.mmParent); if (s) { if (!g(s, ".mm-counter").length) { const e = L(s, ".mm-btn")[0]; null == e || e.prepend(v("span.mm-counter")) } e(n) } }), this.bind("initListitem:after", e => { const n = e.closest(".mm-panel"); if (!n) return; this.node.pnls.querySelector("#" + n.dataset.mmParent) && t.observe(e, { attributes: !0 }) }) }, iconbar: function () { this.opts.iconbar = this.opts.iconbar || {}; const e = a(this.opts.iconbar, A); if (!e.use) return; let t; if (["top", "bottom"].forEach((n, s) => { let i = e[n]; "array" != o(i) && (i = [i]); const a = v("div.mm-iconbar__" + n); for (let e = 0, t = i.length; e < t; e++)"string" == typeof i[e] ? a.innerHTML += i[e] : a.append(i[e]); a.children.length && (t || (t = v("div.mm-iconbar")), t.append(a)) }), t) { this.bind("initMenu:after", () => { this.node.menu.prepend(t) }); let n = "mm-menu--iconbar-" + e.position, s = () => { this.node.menu.classList.add(n) }, i = () => { this.node.menu.classList.remove(n) }; if ("boolean" == typeof e.use ? this.bind("initMenu:after", s) : P(e.use, s, i), "tabs" == e.type) { t.classList.add("mm-iconbar--tabs"), t.addEventListener("click", e => { const t = e.target.closest(".mm-iconbar__tab"); if (t) if (t.matches(".mm-iconbar__tab--selected")) e.stopImmediatePropagation(); else try { const n = g(this.node.menu, t.getAttribute("href") + ".mm-panel")[0]; n && (e.preventDefault(), e.stopImmediatePropagation(), this.openPanel(n, !1)) } catch (e) { } }); const e = n => { g(t, "a").forEach(e => { e.classList.remove("mm-iconbar__tab--selected") }); const s = g(t, '[href="#' + n.id + '"]')[0]; if (s) s.classList.add("mm-iconbar__tab--selected"); else { const t = g(this.node.pnls, "#" + n.dataset.mmParent)[0]; t && e(t.closest(".mm-panel")) } }; this.bind("openPanel:before", e) } } }, iconPanels: function () { this.opts.iconPanels = this.opts.iconPanels || {}; const e = a(this.opts.iconPanels, j); let t = !1; if ("first" == e.visible && (t = !0, e.visible = 1), e.visible = Math.min(3, Math.max(1, e.visible)), e.visible++, e.add) { if (this.bind("initMenu:after", () => { this.node.menu.classList.add("mm-menu--iconpanel") }), this.bind("initPanel:after", e => { e.tabIndex = -1 }), this.bind("initPanels:after", () => { document.addEventListener("keyup", e => { var t; if ("Tab" === e.key && (null === (t = document.activeElement) || void 0 === t ? void 0 : t.closest(".mm-menu")) === this.node.menu) { const t = document.activeElement.closest(".mm-panel"); !document.activeElement.matches(".mm-panel__blocker") && (null == t ? void 0 : t.matches(".mm-panel--parent")) && (e.shiftKey ? L(t, ".mm-panel__blocker")[0].focus() : L(this.node.pnls, ".mm-panel--opened")[0].focus()) } }) }), t) this.bind("initMenu:after", () => { var e; null === (e = L(this.node.pnls, ".mm-panel")[0]) || void 0 === e || e.classList.add("mm-panel--iconpanel-first") }); else { const t = ["mm-panel--iconpanel-0", "mm-panel--iconpanel-1", "mm-panel--iconpanel-2", "mm-panel--iconpanel-3"]; this.bind("openPanel:after", n => { if (n.parentElement.matches(".mm-listitem--vertical")) return; let s = L(this.node.pnls, ".mm-panel"); s = s.filter(e => e.matches(".mm-panel--parent")), s.push(n), s = s.slice(-e.visible), s.forEach((e, n) => { e.classList.remove(...t), e.classList.add("mm-panel--iconpanel-" + n) }) }) } this.bind("initPanel:after", t => { if (e.blockPanel && !t.parentElement.matches(".mm-listitem--vertical") && !L(t, ".mm-panel__blocker")[0]) { const e = v("a.mm-panel__blocker"); e.href = "#" + t.closest(".mm-panel").id, e.title = this.i18n(this.conf.screenReader.closeSubmenu), t.prepend(e) } }) } }, navbars: q, pageScroll: function () { this.opts.pageScroll = this.opts.pageScroll || {}, this.conf.pageScroll = this.conf.pageScroll || {}; const e = a(this.opts.pageScroll, I), t = a(this.conf.pageScroll, R); var n; function s() { n && window.scrollTo({ top: n.getBoundingClientRect().top + document.scrollingElement.scrollTop - t.scrollOffset, behavior: "smooth" }), n = null } function i(e) { try { if ("#" == e.slice(0, 1)) return g(x.node.page, e)[0] } catch (e) { } return null } if (this.opts.offCanvas.use && e.scroll && (this.bind("close:after", () => { s() }), this.node.menu.addEventListener("click", e => { var t, a; const o = (null === (a = null === (t = e.target) || void 0 === t ? void 0 : t.closest("a[href]")) || void 0 === a ? void 0 : a.getAttribute("href")) || ""; (n = i(o)) && (e.preventDefault(), this.node.menu.matches(".mm-menu--sidebar-expanded") && this.node.wrpr.matches(".mm-wrapper--sidebar-expanded") ? s() : this.close()) })), e.update) { let e = []; this.bind("initListview:after", t => { const n = L(t, ".mm-listitem"); E(n).forEach(t => { const n = i(t.getAttribute("href")); n && e.unshift(n) }) }); let n = -1; window.addEventListener("scroll", s => { const i = window.scrollY; for (var a = 0; a < e.length; a++)if (e[a].offsetTop < i + t.updateOffset) { if (n !== a) { n = a; let t = L(this.node.pnls, ".mm-panel--opened")[0], s = g(t, ".mm-listitem"), i = E(s); i = i.filter(t => t.matches('[href="#' + e[a].id + '"]')), i.length && this.setSelected(i[0].parentElement) } break } }, { passive: !0 }) } }, searchfield: function () { this.opts.searchfield = this.opts.searchfield || {}, this.conf.searchfield = this.conf.searchfield || {}; const e = a(this.opts.searchfield, B); a(this.opts.searchfield, D); if (e.add) { switch (e.addTo) { case "panels": e.addTo = ".mm-panel"; break; case "searchpanel": e.addTo = ".mm-panel--search" }switch (e.searchIn) { case "panels": e.searchIn = ".mm-panel" }this.bind("initPanel:after", t => { t.matches(e.addTo) && !t.closest(".mm-listitem--vertical") && Y.call(this, t) }), this.bind("initMenu:after", () => { const t = U.call(this); Y.call(this, t), g(this.node.menu, e.addTo).forEach(n => { if (!n.matches(".mm-panel")) { const s = K.call(this, !0); n.append(s); const i = g(s, "input")[0]; e.splash.length ? (i.addEventListener("focusin", () => { this.openPanel(t, !1, !1) }), this.bind("openPanel:after", e => { e.matches(".mm-panel--search") ? s.classList.add("mm-searchfield--cancelable") : s.classList.remove("mm-searchfield--cancelable") })) : (this.bind("search:after", () => { this.openPanel(t, !1, !1) }), i.addEventListener("focusout", () => { i.value.length || this.closePanel(t, !1) })), W.call(this, s) } }) }), this.bind("close:before", () => { g(this.node.menu, ".mm-searchfield input").forEach(e => { e.blur() }) }) } }, sectionIndexer: function () { this.opts.sectionIndexer = this.opts.sectionIndexer || {}; a(this.opts.sectionIndexer, te).add && this.bind("initPanels:after", () => { if (!this.node.indx) { let e = ""; "abcdefghijklmnopqrstuvwxyz".split("").forEach(t => { e += '<a href="#">' + t + "</a>" }); let t = v("div.mm-sectionindexer"); t.innerHTML = e, this.node.pnls.prepend(t), this.node.indx = t, this.node.indx.addEventListener("click", e => { e.target.matches("a") && e.preventDefault() }); let n = e => { if (!e.target.matches("a")) return; const t = e.target.textContent, n = L(this.node.pnls, ".mm-panel--opened")[0]; let s = -1, i = n.scrollTop; n.scrollTop = 0, g(n, ".mm-divider").filter(e => !e.matches(".mm-hidden")).forEach(e => { s < 0 && t == e.textContent.trim().slice(0, 1).toLowerCase() && (s = e.offsetTop) }), n.scrollTop = s > -1 ? s : i }; C ? (this.node.indx.addEventListener("touchstart", n), this.node.indx.addEventListener("touchmove", n)) : this.node.indx.addEventListener("mouseover", n) } this.bind("openPanel:before", e => { const t = g(e, ".mm-divider").filter(e => !e.matches(".mm-hidden")).length; this.node.indx.classList[t ? "add" : "remove"]("mm-sectionindexer--active") }) }) }, setSelected: function () { this.opts.setSelected = this.opts.setSelected || {}; const e = a(this.opts.setSelected, ne); if ("detect" == e.current) { const e = t => { t = t.split("?")[0].split("#")[0]; const n = this.node.menu.querySelector('a[href="' + t + '"], a[href="' + t + '/"]'); if (n) this.setSelected(n.parentElement); else { const n = t.split("/").slice(0, -1); n.length && e(n.join("/")) } }; this.bind("initMenu:after", () => { e.call(this, window.location.href) }) } else e.current || this.bind("initListview:after", e => { L(e, ".mm-listitem--selected").forEach(e => { e.classList.remove("mm-listitem--selected") }) }); e.hover && this.bind("initMenu:after", () => { this.node.menu.classList.add("mm-menu--selected-hover") }), e.parent && (this.bind("openPanel:after", e => { g(this.node.pnls, ".mm-listitem--selected-parent").forEach(e => { e.classList.remove("mm-listitem--selected-parent") }); let t = e; for (; t;) { let e = g(this.node.pnls, "#" + t.dataset.mmParent)[0]; t = null == e ? void 0 : e.closest(".mm-panel"), e && !e.matches(".mm-listitem--vertical") && e.classList.add("mm-listitem--selected-parent") } }), this.bind("initMenu:after", () => { this.node.menu.classList.add("mm-menu--selected-parent") })) }, sidebar: function () { if (!this.opts.offCanvas.use) return; this.opts.sidebar = this.opts.sidebar || {}; const e = a(this.opts.sidebar, se); if (e.collapsed.use) { this.bind("initMenu:after", () => { if (this.node.menu.classList.add("mm-menu--sidebar-collapsed"), e.collapsed.blockMenu && !L(this.node.menu, ".mm-menu__blocker")[0]) { const e = v("a.mm-menu__blocker"); e.setAttribute("href", "#" + this.node.menu.id), this.node.menu.prepend(e), e.title = this.i18n(this.conf.screenReader.openMenu) } }); let t = () => { this.node.wrpr.classList.add("mm-wrapper--sidebar-collapsed") }, n = () => { this.node.wrpr.classList.remove("mm-wrapper--sidebar-collapsed") }; "boolean" == typeof e.collapsed.use ? this.bind("initMenu:after", t) : P(e.collapsed.use, t, n) } if (e.expanded.use) { this.bind("initMenu:after", () => { this.node.menu.classList.add("mm-menu--sidebar-expanded") }); let t = !1, n = () => { t = !0, this.node.wrpr.classList.add("mm-wrapper--sidebar-expanded"), this.open() }, s = () => { t = !1, this.node.wrpr.classList.remove("mm-wrapper--sidebar-expanded"), this.close() }; "boolean" == typeof e.expanded.use ? this.bind("initMenu:after", n) : P(e.expanded.use, n, s), this.bind("close:after", () => { t && window.sessionStorage.setItem("mmenuExpandedState", "closed") }), this.bind("open:after", () => { t && window.sessionStorage.setItem("mmenuExpandedState", "open") }); let i = e.expanded.initial; const a = window.sessionStorage.getItem("mmenuExpandedState"); switch (a) { case "open": case "closed": i = a }"closed" == i && this.bind("init:after", () => { this.close() }) } } }; t.default = x; window && (window.Mmenu = x)
|
|
11
|
-
}]);
|