DmitrMakeev commited on
Commit
37c1968
·
verified ·
1 Parent(s): 3941128

Update js/rus/rus.js

Browse files
Files changed (1) hide show
  1. js/rus/rus.js +115 -0
js/rus/rus.js CHANGED
@@ -891,6 +891,121 @@ editor.Blocks.add('avp-look_vk-settings-block-block', {
891
 
892
 
893
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
894
 
895
 
896
 
 
891
 
892
 
893
 
894
+
895
+
896
+
897
+
898
+
899
+
900
+ editor.Components.addType('senler_form_v1-settings-block', {
901
+ model: {
902
+ defaults: {
903
+ content: '<div id="set_senler_1"></div>',
904
+ script: function(props) {
905
+ window.avp = props.avp;
906
+ window.grup = props.grup;
907
+ window.red_url = props.red_url;
908
+ window.pol_a = props.pol_a;
909
+ window.pol_b = props.pol_b;
910
+ window.new_w = props.new_w;
911
+ const initBlock = () => {
912
+ console.log('Empty block initialized with props:', { avp, grup, red_url, pol_a, pol_b, new_w });
913
+ };
914
+ const loadScript = (src, callback) => {
915
+ const script = document.createElement('script');
916
+ script.src = src;
917
+ script.onload = callback;
918
+ document.body.appendChild(script);
919
+ };
920
+ if (typeof vkBridge === 'undefined') {
921
+ loadScript('https://unpkg.com/@vkontakte/vk-bridge/dist/browser.min.js', () => {
922
+ console.log('VK Bridge loaded!');
923
+ initBlock();
924
+ });
925
+ } else {
926
+ initBlock();
927
+ }
928
+
929
+ if (typeof VK === 'undefined') {
930
+ loadScript('https://vk.com/js/api/openapi.js?169', () => {
931
+ console.log('VK Open API loaded!');
932
+ });
933
+ }
934
+
935
+ loadScript('https://huggingface.co/spaces/DMTuit/psy_vk/resolve/main/js/avp_form.js', () => {
936
+ console.log('Custom script loaded!');
937
+ });
938
+ },
939
+ 'script-props': ['avp', 'grup', 'red_url', 'pol_a', 'pol_b', 'new_w'],
940
+ traits: [
941
+ {
942
+ type: 'text',
943
+ name: 'avp',
944
+ label: 'AVP',
945
+ changeProp: true
946
+ },
947
+ {
948
+ type: 'text',
949
+ name: 'grup',
950
+ label: 'GRUP',
951
+ changeProp: true
952
+ },
953
+ {
954
+ type: 'text',
955
+ name: 'red_url',
956
+ label: 'RED_URL',
957
+ changeProp: true
958
+ },
959
+ {
960
+ type: 'text',
961
+ name: 'pol_a',
962
+ label: 'POL_A',
963
+ changeProp: true
964
+ },
965
+ {
966
+ type: 'text',
967
+ name: 'pol_b',
968
+ label: 'POL_B',
969
+ changeProp: true
970
+ },
971
+ {
972
+ type: 'checkbox', // Изменено на checkbox
973
+ name: 'new_w',
974
+ label: 'NEW_W', // Обновлен лейбл
975
+ changeProp: true
976
+ }
977
+ ]
978
+ }
979
+ }
980
+ });
981
+
982
+ editor.Blocks.add('senler_form_v1-settings-block-block', {
983
+ label: `
984
+ <!-- icon666.com - MILLIONS vector ICONS FREE --><svg id="Layer_1" enable-background="new 0 0 152 152" viewBox="0 0 152 152" xmlns="http://www.w3.org/2000/svg" width="36" height="36"><path id="Icon" clip-rule="evenodd" d="m74.5 112.8h7.8c1.3-.2 2.6-.8 3.6-1.6.6-1 1.1-2.1 1.1-3.4 0 0-.2-10.4 4.7-12s10.9 10.1 17.4 14.6c4.9 3.4 8.6 2.6 8.6 2.6l17.4-.3s9.1-.5 4.7-7.6c-.3-.6-2.6-5.2-13-14.9-10.9-10.1-9.4-8.4 3.7-26 8-10.6 11.2-17.1 10.2-20s-6.8-1.9-6.8-1.9l-19.5.2c-.8-.2-1.8 0-2.6.5s-1.3 1.3-1.8 2.1c-1.9 5.2-4.4 10.4-7.1 15.3-8.8 14.8-12.2 15.6-13.6 14.6-3.2-2.1-2.4-8.6-2.4-13.2 0-14.3 2.1-20.3-4.2-21.8-2.9-.6-6-1-9.1-1-7 0-12.8 0-16.2 1.6-2.4 1-4 3.4-3 3.4 2.3.2 4.2 1.3 5.8 2.9 1.9 2.8 1.9 8.8 1.9 8.8s1.1 16.9-2.8 19c-2.6 1.5-6.2-1.5-14-14.9-2.6-4.7-5-9.4-7-14.5-.3-.8-1-1.6-1.6-2.1-.3-.2-.6-.5-1-.5-1-.5-2.1-.6-3.2-.6l-17.4.2s-2.8 0-3.7 1.3c-1 1.3 0 3.2 0 3.2s14.6 34.1 31 51.2c15.1 15.9 32.1 14.8 32.1 14.8z" fill-rule="evenodd" fill="#000000" style="fill: rgb(255, 255, 255);"></path></svg>
985
+ avp_form_v1`,
986
+ content: { type: 'senler_form_v1-settings-block' },
987
+ category: 'Сенлер - ВК', // Добавляем категорию "Сенлер - ВК"
988
+ });
989
+
990
+
991
+
992
+
993
+
994
+
995
+
996
+
997
+
998
+
999
+
1000
+
1001
+
1002
+
1003
+
1004
+
1005
+
1006
+
1007
+
1008
+
1009
 
1010
 
1011