@@ -5,15 +5,15 @@ <h1>{{ summary }}</h1>
55 {% if encryption_info_message %}< p > {{ encryption_info_message }}</ p > {% endif %}
66 < div class ="w3-row-padding " style ="padding-left: 0px; ">
77 {%- if obfuscate %}
8- < input type ="hidden " id ="mkdocs-content-password " value ="{{ obfuscate_password }} " / >
8+ < input type ="hidden " id ="mkdocs-content-password " value ="{{ obfuscate_password }} ">
99 {%- else %}
1010 {%- if uname %}
1111 < div class ="w3-third ">
12- < input {% if input_class %} class ="{{ input_class }} "{% endif %} type ="text " id ="mkdocs-content-user " placeholder ="{{ placeholder_user }} " / >
12+ < input {% if input_class %} class ="{{ input_class }} "{% endif %} type ="text " id ="mkdocs-content-user " placeholder ="{{ placeholder_user }} ">
1313 </ div >
1414 {%- endif %}
1515 < div class ="w3-third ">
16- < input {% if input_class %} class ="{{ input_class }} "{% endif %} type ="password " id ="mkdocs-content-password " placeholder ="{{ placeholder }} " / >
16+ < input {% if input_class %} class ="{{ input_class }} "{% endif %} type ="password " id ="mkdocs-content-password " placeholder ="{{ placeholder }} ">
1717 </ div >
1818 {%- endif %}
1919 {%- if password_button %}
@@ -35,10 +35,27 @@ <h1>{{ summary }}</h1>
3535{ % if inject_something % } var inject_something = { { inject_something } } ; { % endif - % }
3636{ % if delete_something % } var delete_something = "{{ delete_something }}" ; { % - endif % }
3737</ script >
38- {% for library in js_libraries %}
38+ {%- if esm %}
39+ < script type ="module ">
40+ if ( ! window . hasOwnProperty ( "init_decryptor" ) ) {
41+ { % - if not webcrypto % }
42+ import ( "{{ js_libraries[0] }}" ) . then ( ( module ) => {
43+ window [ "CryptoJS" ] = module . default ;
44+ { % - endif % }
45+ import ( "{{ base_path }}assets/javascripts/decrypt-contents.js" ) ;
46+ { % - if not webcrypto % }
47+ } ) ;
48+ { % - endif % }
49+ } else {
50+ init_decryptor ( ) ;
51+ }
52+ </ script >
53+ {%- else %}
54+ {%- for library in js_libraries %}
3955< script type ="text/javascript " src ="{{ library }} "> </ script >
40- {%- endfor %}
56+ {%- endfor %}
4157< script type ="text/javascript " src ="{{ base_path }}assets/javascripts/decrypt-contents.js " defer > </ script >
58+ {%- endif %}
4259< script >
4360var encryptcontent_info = document . getElementById ( 'encryptcontent-info' ) ;
4461encryptcontent_info . innerHTML = '<b>keystore length:</b> ' + encryptcontent_keystore . length + '<br>encryptcontent id:<b>:</b> ' + encryptcontent_id ;
0 commit comments