Below is a styled version of your input using pure CSS. I will provide the CSS styles for the given HTML structure. Note that I'll assume the q-dialog, q-card, and other components are already styled by their respective frameworks (like Quasar) and focus on the custom input styling.
Given HTML structure (with minor adjustments for standard HTML):
<dialog id="confirmDeleteBase">
<div class="mycard">
<div class="card-header">
<h2 class="tw-text-lg tw-font-bold">حذف فضای کاری</h2>
<p class="tw-text-neutral-content tw-pb-4">
عبارت deletebase را در کادر زیر وارد کنید
</p>
<input
type="text"
id="deleteConfirmText"
class="tw-shadow tw-rounded-md tw-w-full tw-p-1.5 tw-border tw-outline-none"
autofocus
/>
</div>
<div class="card-footer tw-flex tw-items-center tw-justify-between tw-p-2">
<button class="tw-rounded-lg tw-py-2 tw-px-4">لغو</button>
<button
id="deleteButton"
class="tw-py-2 tw-rounded-lg tw-bg-red4 tw-select-none tw-cursor-pointer tw-block tw-text-base-100 tw-px-4 tw-py-0.5"
disabled
>
حذف
</button>
</div>
</div>
</dialog>
And here is the CSS for styling:
/* Style the dialog box */
#confirmDeleteBase {
position: fixed;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
background-color: rgba(0,0,0,0.5);
border: none;
padding: 0;
display: flex;
justify-content: center;
align-items: center;
}
.mycard {
background-color: #fff;
padding: 20px;
border-radius: 10px;
box-shadow: 0 0 10px rgba(0,0,0,0.2);
max-width: 400px;
width: 90%;
}
.card-header {
padding-bottom: 20px;
}
.card-header h2 {
margin-top: 0;
}
#deleteConfirmText {
transition: all 0.3s ease;
}
#deleteConfirmText:focus {
border-color: #86d18e;
box-shadow: 0 0 0 2px rgba(134,209,94,0.5);
}
.card-footer button {
border: none;
padding: 10px 20px;
border-radius: 5px;
cursor: pointer;
}
.card-footer button:hover {
opacity: 0.8;
}
#deleteButton {
background-color: #ff3737;
color: white;
}
#deleteButton:disabled {
background-color: #ccc;
cursor: not-allowed;
}
This CSS provides basic styling for the dialog box, input field, and buttons. You can adjust colors, sizes, and other properties according to your project's requirements. Note that some utility classes (like tw-text-lg, tw-font-bold, etc.) seem to be from Tailwind CSS; if you're using Tailwind, you can directly integrate these classes into your project. If not, the provided CSS should give you a good starting point for custom styling.