Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix autocompletes #3806

Merged
merged 3 commits into from
Oct 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 24 additions & 1 deletion resources/views/components/modal-confirmation.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,29 @@ class="p-2 mt-1 w-full text-black rounded input">
@endif
@endif

<!-- Step 3: Password confirmation -->
<div x-show="step === 3 && confirmWithPassword">
<div class="p-4 mb-4 text-white border-l-4 border-red-500 bg-error" role="alert">
<p class="font-bold">Final Confirmation</p>
<p>Please enter your password to confirm this destructive action.</p>
</div>
<div class="flex flex-col gap-2 mb-4">
@php
$passwordConfirm = Str::uuid();
@endphp
<label for="password-confirm-{{ $passwordConfirm }}"
class="block text-sm font-medium text-gray-700 dark:text-gray-300">
Your Password
</label>
<form @submit.prevent="false" @keydown.enter.prevent>
<input type="text" name="username" autocomplete="username" value="{{ auth()->user()->email }}" style="display: none;">
<input type="password" id="password-confirm-{{ $passwordConfirm }}" x-model="password"
class="w-full input" placeholder="Enter your password" autocomplete="current-password">
</form>
<p x-show="passwordError" x-text="passwordError" class="mt-1 text-sm text-red-500"></p>
@error('password')
<p class="mt-1 text-sm text-red-500">{{ $message }}</p>
@enderror
<div class="flex flex-wrap gap-2 justify-between mt-4">
@if (!empty($checkboxes))
<x-forms.button @click="step--"
Expand Down Expand Up @@ -319,7 +342,7 @@ class="w-auto" isError
">
<span x-text="step2ButtonText"></span>
</x-forms.button>
</div>
</div>
</div>

<!-- Step 3: Password confirmation -->
Expand Down
7 changes: 4 additions & 3 deletions resources/views/livewire/notifications/telegram.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,12 @@
<x-forms.checkbox instantSave id="team.telegram_enabled" label="Enabled" />
</div>
<div class="flex gap-2">
<x-forms.input type="password"
helper="Get it from the <a class='inline-block underline dark:text-white' href='https://t.me/botfather' target='_blank'>BotFather Bot</a> on Telegram."

<x-forms.input type="password" autocomplete="new-password"
helper="Get it from the <a class='inline-block underline dark:text-white' href='https://t.me/botfather' target='_blank'>BotFather Bot</a> on Telegram."
required id="team.telegram_token" label="Token" />
<x-forms.input helper="Recommended to add your bot to a group chat and add its Chat ID here." required
id="team.telegram_chat_id" label="Chat ID" />
id="team.telegram_chat_id" label="Chat ID" />
</div>
@if (data_get($team, 'telegram_enabled'))
<h2 class="mt-4">Subscribe to events</h2>
Expand Down
5 changes: 3 additions & 2 deletions resources/views/livewire/settings-email.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@
</div>
<div class="flex flex-col w-full gap-2 xl:flex-row">
<x-forms.input id="settings.smtp_username" label="SMTP Username" />
<x-forms.input id="settings.smtp_password" type="password" label="SMTP Password" />
<x-forms.input id="settings.smtp_password" type="password" label="SMTP Password"
autocomplete="new-password" />
<x-forms.input id="settings.smtp_timeout" helper="Timeout value for sending emails."
label="Timeout" />
</div>
Expand All @@ -57,7 +58,7 @@
<div class="flex flex-col gap-4">
<div class="flex flex-col w-full gap-2 xl:flex-row">
<x-forms.input type="password" id="settings.resend_api_key" placeholder="API key" required
label="Host" />
label="Host" autocomplete="new-password" />
</div>
</div>
</form>
Expand Down
2 changes: 1 addition & 1 deletion resources/views/livewire/settings-oauth.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
<x-forms.input id="oauth_settings_map.{{ $oauth_setting->provider }}.client_id"
label="Client ID" />
<x-forms.input id="oauth_settings_map.{{ $oauth_setting->provider }}.client_secret"
type="password" label="Client Secret" />
type="password" label="Client Secret" autocomplete="new-password" />
<x-forms.input id="oauth_settings_map.{{ $oauth_setting->provider }}.redirect_uri"
label="Redirect URI" />
@if ($oauth_setting->provider == 'azure')
Expand Down