PluginProbe ʕ •ᴥ•ʔ
JetFormBuilder — Dynamic Blocks Form Builder / 3.1.6
JetFormBuilder — Dynamic Blocks Form Builder v3.1.6
3.6.3.1 3.6.3 3.6.2.2 3.6.2.1 3.6.2 3.6.1.1 3.6.1 3.6.0.1 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 1.1.2 1.1.3 1.1.4 1.1.5 1.1.6 1.1.7 1.2.0 1.2.1 1.2.2 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.3.0 1.3.1 1.3.2 1.3.3 1.4.0 1.4.1 1.4.2 1.4.3 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4 1.5.5 2.0.0 2.0.1 2.0.2 2.0.3 2.0.4 2.0.5 2.0.6 2.1.0 2.1.1 2.1.10 2.1.11 2.1.2 2.1.3 2.1.4 2.1.5 2.1.6 2.1.7 2.1.8 2.1.9 3.0.0 3.0.0.1 3.0.0.2 3.0.0.3 3.0.1 3.0.1.1 3.0.2 3.0.3 3.0.4 3.0.5 3.0.6 3.0.7 3.0.8 3.0.9 3.1.0 3.1.0.1 3.1.1 3.1.2 3.1.3 3.1.4 3.1.5 3.1.6 3.1.7 3.1.8 3.1.9 3.2.0 3.2.1 3.2.2 3.2.3 3.3.0 3.3.1 3.3.2 3.3.3 3.3.3.1 3.3.4 3.3.4.1 3.3.4.2 3.4.0 3.4.1 3.4.2 3.4.3 3.4.4 3.4.5 3.4.5.1 3.4.5.2 3.4.6 3.4.7 3.4.7.1 3.5.0 3.5.1 3.5.1.1 3.5.1.2 3.5.2 3.5.2.1 3.5.3 3.5.4 3.5.5 3.5.6 3.5.6.1 3.5.6.2 3.5.6.3 3.6.0
jetformbuilder / modules / captcha / assets-src / js / hcaptcha / editor / HCaptchaOptions.js
jetformbuilder / modules / captcha / assets-src / js / hcaptcha / editor Last commit date
HCaptchaBlockEdit.js 2 years ago HCaptchaOptions.js 2 years ago HCaptchaProvider.js 2 years ago main.js 2 years ago preview.js 2 years ago variation.js 2 years ago
HCaptchaOptions.js
81 lines
1 const {
2 __,
3 } = wp.i18n;
4 const {
5 ToggleControl,
6 BaseHelp,
7 } = JetFBComponents;
8 const {
9 useCaptchaProvider,
10 } = JetFBHooks;
11 let {
12 TextControl,
13 NumberControl,
14 __experimentalNumberControl,
15 ExternalLink,
16 } = wp.components;
17
18 NumberControl = NumberControl || __experimentalNumberControl;
19
20 const { globalTab } = JetFBActions;
21
22 const currentTab = globalTab( {
23 slug: 'captcha-tab',
24 element: 'hcaptcha',
25 empty: {},
26 } );
27
28 function HCaptchaOptions() {
29 const [ providerArgs, setProviderArgs ] = useCaptchaProvider();
30
31 const currentArgs = providerArgs.use_global
32 ? currentTab
33 : providerArgs;
34
35 return <>
36 <ToggleControl
37 checked={ providerArgs.use_global }
38 onChange={ use_global => setProviderArgs(
39 { use_global } ) }
40 >
41 { __( 'Use', 'jet-form-builder' ) + ' ' }
42 <a href={ JetFormEditorData.global_settings_url +
43 '#captcha-tab__hcaptcha' }>
44 { __( 'Global Settings', 'jet-form-builder' ) }
45 </a>
46 </ToggleControl>
47 <TextControl
48 label={ __( 'Site Key:', 'jet-form-builder' ) }
49 value={ currentArgs.key }
50 disabled={ providerArgs.use_global }
51 onChange={ key => setProviderArgs( { key } ) }
52 />
53 <BaseHelp>
54 { __(
55 'You can find it on this page in the first column of Sitekey.',
56 'jet-form-builder',
57 ) + ' ' }
58 <ExternalLink href={ 'https://dashboard.hcaptcha.com/sites' }>
59 { __( 'Go to the dashboard of sites', 'jet-form-builder' ) }
60 </ExternalLink>
61 </BaseHelp>
62 <TextControl
63 label={ __( 'Secret Key:', 'jet-form-builder' ) }
64 value={ currentArgs.secret }
65 disabled={ providerArgs.use_global }
66 onChange={ secret => setProviderArgs( { secret } ) }
67 />
68 <BaseHelp>
69 { __(
70 `You can find it on the settings page,
71 this will be the first field.`,
72 'jet-form-builder',
73 ) + ' ' }
74 <ExternalLink href={ 'https://dashboard.hcaptcha.com/settings' }>
75 { __( 'Go to the Settings page', 'jet-form-builder' ) }
76 </ExternalLink>
77 </BaseHelp>
78 </>;
79 }
80
81 export default HCaptchaOptions;