<Button değişiklikleri
This commit is contained in:
parent
5110349a6b
commit
bf5088609e
134 changed files with 1126 additions and 1132 deletions
|
|
@ -270,6 +270,18 @@
|
|||
"en": "Login",
|
||||
"tr": "Giriş"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Save",
|
||||
"en": "Save",
|
||||
"tr": "Kaydet"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Saving",
|
||||
"en": "Saving...",
|
||||
"tr": "Kaydediliyor..."
|
||||
},
|
||||
{
|
||||
"resourceName": "AbpAccount",
|
||||
"key": "Cancel",
|
||||
|
|
@ -1014,6 +1026,36 @@
|
|||
"en": "Manager",
|
||||
"tr": "Yönetici"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Submit",
|
||||
"en": "Submit",
|
||||
"tr": "Gönder"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Submitting",
|
||||
"en": "Submitting",
|
||||
"tr": "Submitting..."
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "SendCode",
|
||||
"en": "Send Code",
|
||||
"tr": "Kod Gönder"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "SendingCode",
|
||||
"en": "Sending code...",
|
||||
"tr": "Kod Gönderiliyor"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "OK",
|
||||
"en": "OK",
|
||||
"tr": "Tamam"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Cancel",
|
||||
|
|
@ -2382,6 +2424,12 @@
|
|||
"en": "Sign Up",
|
||||
"tr": "Üye Ol"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Abp.Account.CreatingAccount",
|
||||
"en": "Creating Account...",
|
||||
"tr": "Hesap oluşturuluyor..."
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Abp.Account.SignUp.Message",
|
||||
|
|
@ -4122,12 +4170,6 @@
|
|||
"en": "Edit Room",
|
||||
"tr": "Odayı Düzenle"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "App.Videoroom.SaveChanges",
|
||||
"en": "Save Changes",
|
||||
"tr": "Değişiklikleri Kaydet"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "App.Videoroom.CameraOff",
|
||||
|
|
@ -7316,10 +7358,16 @@
|
|||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Public.common.send",
|
||||
"key": "Send",
|
||||
"tr": "Gönder",
|
||||
"en": "Send"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Resend",
|
||||
"tr": "Tekrar Gönder",
|
||||
"en": "Resend"
|
||||
},
|
||||
{
|
||||
"resourceName": "Platform",
|
||||
"key": "Public.common.subscribe",
|
||||
|
|
|
|||
|
|
@ -66,7 +66,6 @@ export const PanelManager: React.FC<PanelManagerProps> = ({
|
|||
)
|
||||
}
|
||||
variant={panelState[key] ? "twoTone" : "plain"}
|
||||
color="blue-600"
|
||||
size="xs"
|
||||
title={panelState[key] ? "Hide" : "Show"}
|
||||
/>
|
||||
|
|
|
|||
|
|
@ -289,7 +289,6 @@ const PropertyPanel: React.FC<PropertyPanelProps> = ({
|
|||
onClick={() => openTailwindModal(property.name)}
|
||||
icon={<FaCode className="w-3 h-3" />}
|
||||
variant="solid"
|
||||
color="blue-600"
|
||||
size="xs"
|
||||
title="Select Tailwind Classes"
|
||||
>
|
||||
|
|
@ -325,7 +324,6 @@ const PropertyPanel: React.FC<PropertyPanelProps> = ({
|
|||
onClick={() => openTailwindModal(property.name)}
|
||||
icon={<FaCode className="w-3 h-3" />}
|
||||
variant="solid"
|
||||
color="blue-600"
|
||||
size="xs"
|
||||
title="Select Tailwind Classes"
|
||||
>
|
||||
|
|
@ -498,7 +496,6 @@ const PropertyPanel: React.FC<PropertyPanelProps> = ({
|
|||
<div className="flex gap-2 p-1">
|
||||
<Button
|
||||
variant={activeTab === "props" ? "twoTone" : "plain"}
|
||||
color="blue-600"
|
||||
size="xs"
|
||||
onClick={() => setActiveTab("props")}
|
||||
>
|
||||
|
|
@ -506,7 +503,6 @@ const PropertyPanel: React.FC<PropertyPanelProps> = ({
|
|||
</Button>
|
||||
<Button
|
||||
variant={activeTab === "hooks" ? "twoTone" : "plain"}
|
||||
color="blue-600"
|
||||
size="xs"
|
||||
onClick={() => setActiveTab("hooks")}
|
||||
>
|
||||
|
|
|
|||
|
|
@ -111,8 +111,7 @@ const TailwindModal: React.FC<TailwindModalProps> = ({
|
|||
>
|
||||
<Button
|
||||
block
|
||||
variant="twoTone"
|
||||
color="blue-600"
|
||||
variant="solid"
|
||||
size="xs"
|
||||
onClick={() => handleClassSelect(className)}
|
||||
className="justify-start"
|
||||
|
|
@ -142,7 +141,6 @@ const TailwindModal: React.FC<TailwindModalProps> = ({
|
|||
</Button>
|
||||
<Button
|
||||
variant="solid"
|
||||
color="blue-600"
|
||||
size="sm"
|
||||
onClick={onClose}
|
||||
>
|
||||
|
|
|
|||
|
|
@ -347,8 +347,6 @@ export const ImportDashboard: React.FC<ImportDashboardProps> = ({ gridDto }) =>
|
|||
)
|
||||
}
|
||||
variant={activeTab === tab ? 'solid' : 'plain'}
|
||||
color="blue-600"
|
||||
size="sm"
|
||||
className={activeTab === tab ? 'shadow-md' : ''}
|
||||
>
|
||||
<span className="capitalize">{tab}</span>
|
||||
|
|
@ -379,7 +377,6 @@ export const ImportDashboard: React.FC<ImportDashboardProps> = ({ gridDto }) =>
|
|||
disabled={generating}
|
||||
icon={<FaFileExcel className="w-3.5 h-3.5" />}
|
||||
variant="twoTone"
|
||||
color="green-600"
|
||||
size="xs"
|
||||
>
|
||||
{translate('::App.Listforms.ImportManager.ExcelTemplate')}
|
||||
|
|
@ -390,7 +387,6 @@ export const ImportDashboard: React.FC<ImportDashboardProps> = ({ gridDto }) =>
|
|||
disabled={generating}
|
||||
icon={<FaFileAlt className="w-3.5 h-3.5" />}
|
||||
variant="twoTone"
|
||||
color="blue-600"
|
||||
size="xs"
|
||||
>
|
||||
{translate('::App.Listforms.ImportManager.CsvTemplate')}
|
||||
|
|
@ -607,7 +603,6 @@ export const ImportDashboard: React.FC<ImportDashboardProps> = ({ gridDto }) =>
|
|||
}}
|
||||
icon={<FaSync className="w-4 h-4" />}
|
||||
variant="twoTone"
|
||||
color="blue-600"
|
||||
size="xs"
|
||||
title={translate('::App.Listforms.ImportManager.RefreshExecutionDetails')}
|
||||
/>
|
||||
|
|
|
|||
|
|
@ -329,7 +329,6 @@ export const ImportPreview: React.FC<ImportPreviewProps> = ({
|
|||
loading={loading}
|
||||
icon={<FaPlay className="w-4 h-4" />}
|
||||
variant="solid"
|
||||
color="blue-600"
|
||||
size="sm"
|
||||
>
|
||||
{loading
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import View from '@/views/Views'
|
||||
import React, { useEffect, useState } from 'react'
|
||||
import { useLocation, Link } from 'react-router-dom'
|
||||
import { useLocation, Link, useNavigate } from 'react-router-dom'
|
||||
import { FaFacebook, FaTwitter, FaLinkedin, FaInstagram } from 'react-icons/fa'
|
||||
import {
|
||||
LuMenu,
|
||||
|
|
@ -36,6 +36,7 @@ interface NavLink {
|
|||
|
||||
const PublicLayout = () => {
|
||||
const location = useLocation()
|
||||
const navigate = useNavigate()
|
||||
const { translate } = useLocalization()
|
||||
const [isDarkMode, setThemeMode] = useDarkMode()
|
||||
|
||||
|
|
@ -155,7 +156,7 @@ const PublicLayout = () => {
|
|||
size="xs"
|
||||
className={`!h-8 !w-8 xl:!w-auto !px-0 xl:!px-2.5 !rounded-r-md !rounded-l-none !border-transparent !shadow-none ${
|
||||
isDarkMode
|
||||
? '!bg-white !text-gray-950'
|
||||
? '!bg-gray-300 !text-gray-800'
|
||||
: '!bg-transparent !text-gray-300 hover:!bg-transparent hover:!text-white'
|
||||
}`}
|
||||
/>
|
||||
|
|
@ -251,13 +252,15 @@ const PublicLayout = () => {
|
|||
.filter((l) => isLoginLink(l.resourceKey))
|
||||
.map((link) =>
|
||||
link.path ? (
|
||||
<Link
|
||||
<Button
|
||||
key={link.path}
|
||||
to={link.path}
|
||||
className="inline-flex h-9 items-center gap-1.5 px-4 text-sm font-semibold text-white bg-blue-600 hover:bg-blue-500 rounded-lg shadow-md shadow-blue-900/30 transition-all duration-200 hover:shadow-blue-700/40 hover:-translate-y-px"
|
||||
type="button"
|
||||
variant="solid"
|
||||
shape="round"
|
||||
onClick={() => navigate(link.path!)}
|
||||
>
|
||||
{link.name}
|
||||
</Link>
|
||||
</Button>
|
||||
) : null,
|
||||
)}
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -53,8 +53,7 @@ export const BillingControls: React.FC<BillingControlsProps> = ({
|
|||
onClick={() => !hasCartItems && setGlobalBillingCycle('monthly')}
|
||||
disabled={hasCartItems}
|
||||
variant={globalBillingCycle === 'monthly' ? 'solid' : 'default'}
|
||||
color="blue-600"
|
||||
size="sm"
|
||||
size="xs"
|
||||
className={globalBillingCycle === 'monthly' ? 'shadow-md' : ''}
|
||||
title={
|
||||
hasCartItems ? 'Sepette ürün varken faturalama döngüsü değiştirilemez' : undefined
|
||||
|
|
@ -66,8 +65,7 @@ export const BillingControls: React.FC<BillingControlsProps> = ({
|
|||
onClick={() => !hasCartItems && setGlobalBillingCycle('yearly')}
|
||||
disabled={hasCartItems}
|
||||
variant={globalBillingCycle === 'yearly' ? 'solid' : 'default'}
|
||||
color="blue-600"
|
||||
size="sm"
|
||||
size="xs"
|
||||
className={globalBillingCycle === 'yearly' ? 'shadow-md' : ''}
|
||||
title={
|
||||
hasCartItems ? 'Sepette ürün varken faturalama döngüsü değiştirilemez' : undefined
|
||||
|
|
@ -98,8 +96,8 @@ export const BillingControls: React.FC<BillingControlsProps> = ({
|
|||
/>
|
||||
|
||||
<div className="flex items-center space-x-2 bg-gray-50 px-2 py-1 rounded-lg dark:bg-gray-800">
|
||||
<span className="font-bold text-lg text-blue-600">{globalPeriod}</span>
|
||||
<span className="text-sm text-gray-600 dark:text-gray-300">
|
||||
<span className="font-bold text-lg text-gray-600 dark:text-white">{globalPeriod}</span>
|
||||
<span className="text-xs text-gray-600 dark:text-white">
|
||||
{globalBillingCycle === 'monthly'
|
||||
? translate('::Public.products.billingcycle.month')
|
||||
: translate('::Public.products.billingcycle.year')}
|
||||
|
|
@ -119,10 +117,10 @@ export const BillingControls: React.FC<BillingControlsProps> = ({
|
|||
|
||||
<Button
|
||||
onClick={onCartClick}
|
||||
icon={<FaShoppingCart className="w-5 h-5" />}
|
||||
icon={<FaShoppingCart className="w-3 h-3" />}
|
||||
variant="solid"
|
||||
color="green-600"
|
||||
size="sm"
|
||||
size="xs"
|
||||
className="relative shadow-md"
|
||||
>
|
||||
<span className="font-medium text-sm">{translate('::Public.nav.basket')}</span>
|
||||
|
|
|
|||
|
|
@ -170,7 +170,6 @@ export const Cart: React.FC<CartProps> = ({
|
|||
onClick={onCheckout}
|
||||
block
|
||||
variant="solid"
|
||||
color="blue-600"
|
||||
size="md"
|
||||
>
|
||||
{translate('::Public.cart.checkout')}
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ export const PaymentForm: React.FC<PaymentFormProps> = ({
|
|||
}
|
||||
|
||||
return (
|
||||
<div className="mx-auto px-4 lg:px-8 mb-6">
|
||||
<div className="mx-auto px-4 lg:px-8 mt-5">
|
||||
{loading ? (
|
||||
<div className="text-center py-12 text-gray-500">
|
||||
{translate('::App.Loading')}
|
||||
|
|
@ -258,14 +258,14 @@ export const PaymentForm: React.FC<PaymentFormProps> = ({
|
|||
<FaLock className="w-5 h-5 text-green-600 mr-2" />{' '}
|
||||
{translate('::Public.payment.method.title')}
|
||||
</h2>
|
||||
<div className="space-y-2">
|
||||
<div className="space-y-3">
|
||||
{paymentMethods.map((method) => (
|
||||
<label
|
||||
key={method.id}
|
||||
className={`flex items-center p-3 border-2 rounded-lg cursor-pointer transition-all ${
|
||||
className={`group flex items-center gap-3 rounded-xl border p-4 cursor-pointer transition-all ${
|
||||
selectedPaymentMethod === method.name
|
||||
? 'border-blue-500 bg-blue-50'
|
||||
: 'border-gray-200 hover:border-gray-300 dark:border-gray-700 dark:hover:border-gray-500'
|
||||
? 'border-blue-500 bg-blue-50 shadow-sm ring-1 ring-blue-500/20 dark:border-blue-400 dark:bg-blue-950/30 dark:ring-blue-400/20'
|
||||
: 'border-gray-200 bg-white hover:border-blue-300 hover:bg-gray-50 dark:border-gray-700 dark:bg-gray-950/40 dark:hover:border-blue-500 dark:hover:bg-gray-800/70'
|
||||
}`}
|
||||
>
|
||||
<input
|
||||
|
|
@ -278,15 +278,30 @@ export const PaymentForm: React.FC<PaymentFormProps> = ({
|
|||
}}
|
||||
className="sr-only"
|
||||
/>
|
||||
<span className="text-2xl mr-3">{method.logo}</span>
|
||||
<div>
|
||||
<div className="font-medium text-gray-900 dark:text-gray-100">{method.name}</div>
|
||||
<div className="text-sm text-gray-600 dark:text-gray-300">
|
||||
<span
|
||||
className={`flex h-10 w-10 shrink-0 items-center justify-center rounded-lg text-xl ${
|
||||
selectedPaymentMethod === method.name
|
||||
? 'bg-blue-100 text-blue-700 dark:bg-blue-900/50 dark:text-blue-200'
|
||||
: 'bg-gray-100 text-gray-500 group-hover:bg-blue-50 group-hover:text-blue-600 dark:bg-gray-800 dark:text-gray-300 dark:group-hover:bg-blue-900/30 dark:group-hover:text-blue-200'
|
||||
}`}
|
||||
>
|
||||
{method.logo}
|
||||
</span>
|
||||
<div className="min-w-0 flex-1">
|
||||
<div className="font-semibold text-gray-900 dark:text-gray-100">{method.name}</div>
|
||||
<div className="text-sm text-gray-600 dark:text-gray-400">
|
||||
{method.name === defaultPaymentMethod
|
||||
? translate('::Public.payment.method.installmentsAvailable')
|
||||
: translate('::Public.payment.method.noCommission')}
|
||||
</div>
|
||||
</div>
|
||||
<span
|
||||
className={`h-3 w-3 shrink-0 rounded-full border ${
|
||||
selectedPaymentMethod === method.name
|
||||
? 'border-blue-500 bg-blue-500 dark:border-blue-300 dark:bg-blue-300'
|
||||
: 'border-gray-300 dark:border-gray-600'
|
||||
}`}
|
||||
/>
|
||||
</label>
|
||||
))}
|
||||
</div>
|
||||
|
|
@ -304,8 +319,8 @@ export const PaymentForm: React.FC<PaymentFormProps> = ({
|
|||
key={option.id}
|
||||
className={`flex flex-col items-center justify-center h-full p-4 border-2 rounded-xl cursor-pointer transition-all text-xs md:text-sm text-center select-none ${
|
||||
selectedInstallment?.installment === option.installment
|
||||
? 'border-blue-500 bg-blue-50 shadow-md scale-105'
|
||||
: 'border-gray-200 hover:border-blue-200 dark:border-gray-700 dark:hover:border-blue-500'
|
||||
? 'border-blue-500 bg-blue-50 shadow-md scale-105 dark:border-blue-400 dark:bg-blue-950/30 dark:shadow-blue-950/20'
|
||||
: 'border-gray-200 bg-white hover:border-blue-200 hover:bg-gray-50 dark:border-gray-700 dark:bg-gray-950/40 dark:hover:border-blue-500 dark:hover:bg-gray-800/70'
|
||||
}`}
|
||||
>
|
||||
<input
|
||||
|
|
@ -323,7 +338,7 @@ export const PaymentForm: React.FC<PaymentFormProps> = ({
|
|||
%{(option.commission * 100).toFixed(1)}
|
||||
</span>
|
||||
</div>
|
||||
<div className="text-blue-700 font-bold mb-1">
|
||||
<div className="font-bold mb-1">
|
||||
{option.installment > 1
|
||||
? `${option.installment} ${translate('::Public.payment.installments.monthly')}`
|
||||
: translate('::Public.payment.installments.single')}
|
||||
|
|
@ -457,7 +472,6 @@ export const PaymentForm: React.FC<PaymentFormProps> = ({
|
|||
type="submit"
|
||||
icon={<FaCreditCard className="w-5 h-5" />}
|
||||
variant="solid"
|
||||
color="green-600"
|
||||
size="sm"
|
||||
>
|
||||
{selectedPaymentMethod === 'bank-transfer'
|
||||
|
|
|
|||
|
|
@ -171,7 +171,6 @@ export const ProductCard: React.FC<ProductCardProps> = ({
|
|||
disabled={isDisabled}
|
||||
block
|
||||
variant="solid"
|
||||
color="blue-600"
|
||||
size="md"
|
||||
className={!isDisabled ? 'hover:scale-[1.02] active:scale-[0.98]' : ''}
|
||||
>
|
||||
|
|
|
|||
|
|
@ -103,7 +103,6 @@ export const ProductCatalog: React.FC<ProductCatalogProps> = ({
|
|||
onClick={() => setSelectedCategory(category)}
|
||||
block
|
||||
variant={selectedCategory === category ? 'twoTone' : 'plain'}
|
||||
color="blue-600"
|
||||
size="md"
|
||||
className="justify-start text-left"
|
||||
>
|
||||
|
|
|
|||
|
|
@ -154,7 +154,6 @@ export const TenantForm: React.FC<TenantFormProps> = ({ onSubmit }) => {
|
|||
onClick={getTenantInfo}
|
||||
icon={<FaSearch className="w-4 h-4" />}
|
||||
variant="solid"
|
||||
color="blue-600"
|
||||
size="sm"
|
||||
className="!h-[40px] min-w-[180px] sm:mr-2 sm:rounded-r-lg sm:rounded-l-none [&>span]:gap-2"
|
||||
>
|
||||
|
|
|
|||
|
|
@ -798,11 +798,9 @@ const MessengerWidget = () => {
|
|||
type="button"
|
||||
size="lg"
|
||||
variant="solid"
|
||||
color="emerald-600"
|
||||
shape="circle"
|
||||
icon={<IoChatbubbleEllipsesOutline />}
|
||||
onClick={() => (open ? closeWidget() : setOpen(true))}
|
||||
className="!h-12 !w-12 !px-0 text-2xl shadow-xl transition hover:!bg-emerald-700"
|
||||
/>
|
||||
{unread > 0 && (
|
||||
<span className="absolute -right-1 -top-1 flex min-h-[20px] min-w-[20px] items-center justify-center rounded-full bg-red-500 px-1.5 text-xs font-semibold leading-none text-white ring-2 ring-white dark:ring-gray-800">
|
||||
|
|
|
|||
|
|
@ -197,7 +197,7 @@ const _Search = ({ className }: { className?: string }) => {
|
|||
onKeyDown={(e) => e.key === 'Enter' && handleSearch()}
|
||||
/>
|
||||
</div>
|
||||
<Button icon={<FaSearch />} size="sm" onClick={handleSearch}></Button>
|
||||
<Button size="sm" variant='solid' icon={<FaSearch />} onClick={handleSearch}></Button>
|
||||
</div>
|
||||
<div>
|
||||
<div className="flex items-center justify-between p-4 border-b border-gray-200 dark:border-gray-600">
|
||||
|
|
|
|||
|
|
@ -9,231 +9,210 @@ import { Spinner } from '../Spinner'
|
|||
import type { CommonProps, TypeAttributes, ColorLevel } from '../@types/common'
|
||||
import type { ReactNode, ComponentPropsWithRef, MouseEvent } from 'react'
|
||||
|
||||
export interface ButtonProps
|
||||
extends CommonProps,
|
||||
Omit<ComponentPropsWithRef<'button'>, 'onClick'> {
|
||||
active?: boolean
|
||||
block?: boolean
|
||||
color?: string
|
||||
disabled?: boolean
|
||||
icon?: string | ReactNode
|
||||
loading?: boolean
|
||||
onClick?: (e: MouseEvent<HTMLButtonElement>) => void
|
||||
shape?: TypeAttributes.Shape
|
||||
size?: TypeAttributes.Size
|
||||
variant?: 'solid' | 'twoTone' | 'plain' | 'default'
|
||||
export interface ButtonProps extends CommonProps, Omit<ComponentPropsWithRef<'button'>, 'onClick'> {
|
||||
active?: boolean
|
||||
block?: boolean
|
||||
color?: string
|
||||
disabled?: boolean
|
||||
icon?: string | ReactNode
|
||||
loading?: boolean
|
||||
onClick?: (e: MouseEvent<HTMLButtonElement>) => void
|
||||
shape?: TypeAttributes.Shape
|
||||
size?: TypeAttributes.Size
|
||||
variant?: 'solid' | 'twoTone' | 'plain' | 'default'
|
||||
}
|
||||
|
||||
type ButtonColor = {
|
||||
bgColor: string
|
||||
hoverColor: string
|
||||
activeColor: string
|
||||
textColor: string
|
||||
bgColor: string
|
||||
hoverColor: string
|
||||
activeColor: string
|
||||
textColor: string
|
||||
}
|
||||
|
||||
const Button = forwardRef<HTMLButtonElement, ButtonProps>((props, ref) => {
|
||||
const {
|
||||
active = false,
|
||||
block = false,
|
||||
children,
|
||||
className,
|
||||
color = '',
|
||||
disabled,
|
||||
icon,
|
||||
loading = false,
|
||||
shape = 'round',
|
||||
size,
|
||||
variant = 'default',
|
||||
...rest
|
||||
} = props
|
||||
const { themeColor, controlSize, primaryColorLevel } = useConfig()
|
||||
const formControlSize = useForm()?.size
|
||||
const inputGroupSize = useInputGroup()?.size
|
||||
const defaultClass = 'button'
|
||||
const sizeIconClass = 'inline-flex items-center justify-center'
|
||||
const {
|
||||
active = false,
|
||||
block = false,
|
||||
children,
|
||||
className,
|
||||
color = '',
|
||||
disabled,
|
||||
icon,
|
||||
loading = false,
|
||||
shape = 'round',
|
||||
size = 'sm',
|
||||
variant = 'default',
|
||||
...rest
|
||||
} = props
|
||||
const { themeColor, controlSize, primaryColorLevel } = useConfig()
|
||||
const formControlSize = useForm()?.size
|
||||
const inputGroupSize = useInputGroup()?.size
|
||||
const defaultClass = 'button'
|
||||
const sizeIconClass = 'inline-flex items-center justify-center'
|
||||
|
||||
const splitedColor = color?.split('-') || []
|
||||
const splitedColor = color?.split('-') || []
|
||||
|
||||
const buttonSize = size || inputGroupSize || formControlSize || controlSize
|
||||
const buttonColor = splitedColor[0] || themeColor
|
||||
const buttonColorLevel = splitedColor[1] || primaryColorLevel
|
||||
const buttonSize = size || inputGroupSize || formControlSize || controlSize
|
||||
const buttonColor = splitedColor[0] || themeColor
|
||||
const buttonColorLevel = splitedColor[1] || primaryColorLevel
|
||||
|
||||
const [increaseLevel, decreaseLevel] = useColorLevel(
|
||||
buttonColorLevel as ColorLevel
|
||||
)
|
||||
const [increaseLevel, decreaseLevel] = useColorLevel(buttonColorLevel as ColorLevel)
|
||||
|
||||
const getButtonSize = () => {
|
||||
let sizeClass = ''
|
||||
switch (buttonSize) {
|
||||
case SIZES.LG:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.lg}`,
|
||||
icon && !children
|
||||
? `w-${CONTROL_SIZES.lg} ${sizeIconClass} text-2xl`
|
||||
: 'px-8 text-base'
|
||||
)
|
||||
break
|
||||
case SIZES.SM:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.sm}`,
|
||||
icon && !children
|
||||
? `w-${CONTROL_SIZES.sm} ${sizeIconClass} text-lg`
|
||||
: 'px-3 text-sm'
|
||||
)
|
||||
break
|
||||
case SIZES.XS:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.xs}`,
|
||||
icon && !children
|
||||
? `w-${CONTROL_SIZES.xs} ${sizeIconClass} text-base`
|
||||
: 'px-2 text-xs'
|
||||
)
|
||||
break
|
||||
default:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.md}`,
|
||||
icon && !children
|
||||
? `w-${CONTROL_SIZES.md} ${sizeIconClass} text-xl`
|
||||
: 'px-8'
|
||||
)
|
||||
break
|
||||
}
|
||||
return sizeClass
|
||||
const getButtonSize = () => {
|
||||
let sizeClass = ''
|
||||
switch (buttonSize) {
|
||||
case SIZES.LG:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.lg}`,
|
||||
icon && !children ? `w-${CONTROL_SIZES.lg} ${sizeIconClass} text-2xl` : 'px-8 text-base',
|
||||
)
|
||||
break
|
||||
case SIZES.SM:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.sm}`,
|
||||
icon && !children ? `w-${CONTROL_SIZES.sm} ${sizeIconClass} text-lg` : 'px-3 text-sm',
|
||||
)
|
||||
break
|
||||
case SIZES.XS:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.xs}`,
|
||||
icon && !children ? `w-${CONTROL_SIZES.xs} ${sizeIconClass} text-base` : 'px-2 text-xs',
|
||||
)
|
||||
break
|
||||
default:
|
||||
sizeClass = classNames(
|
||||
`h-${CONTROL_SIZES.md}`,
|
||||
icon && !children ? `w-${CONTROL_SIZES.md} ${sizeIconClass} text-xl` : 'px-8',
|
||||
)
|
||||
break
|
||||
}
|
||||
return sizeClass
|
||||
}
|
||||
|
||||
const disabledClass = 'opacity-50 cursor-not-allowed'
|
||||
|
||||
const solidColor = () => {
|
||||
const btn = {
|
||||
bgColor: active
|
||||
? `bg-${buttonColor}-${increaseLevel}`
|
||||
: `bg-${buttonColor}-${buttonColorLevel}`,
|
||||
textColor: 'text-white',
|
||||
hoverColor: active ? '' : `hover:bg-${buttonColor}-${decreaseLevel}`,
|
||||
activeColor: `active:bg-${buttonColor}-${increaseLevel}`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
}
|
||||
|
||||
const twoToneColor = () => {
|
||||
const btn = {
|
||||
bgColor: active
|
||||
? `bg-${buttonColor}-200 dark:bg-${buttonColor}-50`
|
||||
: `bg-${buttonColor}-50 dark:bg-${buttonColor}-500 dark:bg-opacity-20`,
|
||||
textColor: `text-${buttonColor}-${buttonColorLevel} dark:text-${buttonColor}-50`,
|
||||
hoverColor: active
|
||||
? ''
|
||||
: `hover:bg-${buttonColor}-100 dark:hover:bg-${buttonColor}-500 dark:hover:bg-opacity-30`,
|
||||
activeColor: `active:bg-${buttonColor}-200 dark:active:bg-${buttonColor}-500 dark:active:bg-opacity-40`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
}
|
||||
|
||||
const defaultColor = () => {
|
||||
const btn = {
|
||||
bgColor: active
|
||||
? `bg-gray-100 border border-gray-300 dark:bg-gray-500 dark:border-gray-500`
|
||||
: `bg-white border border-gray-300 dark:bg-gray-700 dark:border-gray-700`,
|
||||
textColor: `text-gray-600 dark:text-gray-100`,
|
||||
hoverColor: active ? '' : `hover:bg-gray-50 dark:hover:bg-gray-600`,
|
||||
activeColor: `active:bg-gray-100 dark:active:bg-gray-500 dark:active:border-gray-500`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
}
|
||||
|
||||
const plainColor = () => {
|
||||
const btn = {
|
||||
bgColor: active ? `bg-gray-100 dark:bg-gray-500` : 'bg-transparent border border-transparent',
|
||||
textColor: `text-gray-600 dark:text-gray-100`,
|
||||
hoverColor: active ? '' : `hover:bg-gray-50 dark:hover:bg-gray-600`,
|
||||
activeColor: `active:bg-gray-100 dark:active:bg-gray-500 dark:active:border-gray-500`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
}
|
||||
|
||||
const getBtnColor = ({ bgColor, hoverColor, activeColor, textColor }: ButtonColor) => {
|
||||
return `${bgColor} ${
|
||||
disabled || loading ? disabledClass : hoverColor + ' ' + activeColor
|
||||
} ${textColor}`
|
||||
}
|
||||
|
||||
const btnColor = () => {
|
||||
switch (variant) {
|
||||
case 'solid':
|
||||
return solidColor()
|
||||
case 'twoTone':
|
||||
return twoToneColor()
|
||||
case 'plain':
|
||||
return plainColor()
|
||||
case 'default':
|
||||
return defaultColor()
|
||||
default:
|
||||
return defaultColor()
|
||||
}
|
||||
}
|
||||
|
||||
const classes = classNames(
|
||||
defaultClass,
|
||||
btnColor(),
|
||||
`radius-${shape}`,
|
||||
getButtonSize(),
|
||||
className,
|
||||
block ? 'w-full' : '',
|
||||
)
|
||||
|
||||
const handleClick = (e: MouseEvent<HTMLButtonElement>) => {
|
||||
const { onClick } = props
|
||||
if (disabled || loading) {
|
||||
e.preventDefault()
|
||||
return
|
||||
}
|
||||
onClick?.(e)
|
||||
}
|
||||
|
||||
const renderChildren = () => {
|
||||
if (loading && children) {
|
||||
return (
|
||||
<span className="flex items-center justify-center">
|
||||
<Spinner enableTheme={false} className="mr-1" />
|
||||
{children}
|
||||
</span>
|
||||
)
|
||||
}
|
||||
|
||||
const disabledClass = 'opacity-50 cursor-not-allowed'
|
||||
|
||||
const solidColor = () => {
|
||||
const btn = {
|
||||
bgColor: active
|
||||
? `bg-${buttonColor}-${increaseLevel}`
|
||||
: `bg-${buttonColor}-${buttonColorLevel}`,
|
||||
textColor: 'text-white',
|
||||
hoverColor: active
|
||||
? ''
|
||||
: `hover:bg-${buttonColor}-${decreaseLevel}`,
|
||||
activeColor: `active:bg-${buttonColor}-${increaseLevel}`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
if (icon && !children && loading) {
|
||||
return <Spinner enableTheme={false} />
|
||||
}
|
||||
|
||||
const twoToneColor = () => {
|
||||
const btn = {
|
||||
bgColor: active
|
||||
? `bg-${buttonColor}-200 dark:bg-${buttonColor}-50`
|
||||
: `bg-${buttonColor}-50 dark:bg-${buttonColor}-500 dark:bg-opacity-20`,
|
||||
textColor: `text-${buttonColor}-${buttonColorLevel} dark:text-${buttonColor}-50`,
|
||||
hoverColor: active
|
||||
? ''
|
||||
: `hover:bg-${buttonColor}-100 dark:hover:bg-${buttonColor}-500 dark:hover:bg-opacity-30`,
|
||||
activeColor: `active:bg-${buttonColor}-200 dark:active:bg-${buttonColor}-500 dark:active:bg-opacity-40`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
if (icon && !children && !loading) {
|
||||
return <>{icon}</>
|
||||
}
|
||||
|
||||
const defaultColor = () => {
|
||||
const btn = {
|
||||
bgColor: active
|
||||
? `bg-gray-100 border border-gray-300 dark:bg-gray-500 dark:border-gray-500`
|
||||
: `bg-white border border-gray-300 dark:bg-gray-700 dark:border-gray-700`,
|
||||
textColor: `text-gray-600 dark:text-gray-100`,
|
||||
hoverColor: active ? '' : `hover:bg-gray-50 dark:hover:bg-gray-600`,
|
||||
activeColor: `active:bg-gray-100 dark:active:bg-gray-500 dark:active:border-gray-500`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
if (icon && children && !loading) {
|
||||
return (
|
||||
<span className="flex items-center justify-center">
|
||||
<span className="text-lg">{icon}</span>
|
||||
<span className="ltr:ml-1 rtl:mr-1">{children}</span>
|
||||
</span>
|
||||
)
|
||||
}
|
||||
|
||||
const plainColor = () => {
|
||||
const btn = {
|
||||
bgColor: active
|
||||
? `bg-gray-100 dark:bg-gray-500`
|
||||
: 'bg-transparent border border-transparent',
|
||||
textColor: `text-gray-600 dark:text-gray-100`,
|
||||
hoverColor: active ? '' : `hover:bg-gray-50 dark:hover:bg-gray-600`,
|
||||
activeColor: `active:bg-gray-100 dark:active:bg-gray-500 dark:active:border-gray-500`,
|
||||
}
|
||||
return getBtnColor(btn)
|
||||
}
|
||||
return <>{children}</>
|
||||
}
|
||||
|
||||
const getBtnColor = ({
|
||||
bgColor,
|
||||
hoverColor,
|
||||
activeColor,
|
||||
textColor,
|
||||
}: ButtonColor) => {
|
||||
return `${bgColor} ${
|
||||
disabled || loading ? disabledClass : hoverColor + ' ' + activeColor
|
||||
} ${textColor}`
|
||||
}
|
||||
|
||||
const btnColor = () => {
|
||||
switch (variant) {
|
||||
case 'solid':
|
||||
return solidColor()
|
||||
case 'twoTone':
|
||||
return twoToneColor()
|
||||
case 'plain':
|
||||
return plainColor()
|
||||
case 'default':
|
||||
return defaultColor()
|
||||
default:
|
||||
return defaultColor()
|
||||
}
|
||||
}
|
||||
|
||||
const classes = classNames(
|
||||
defaultClass,
|
||||
btnColor(),
|
||||
`radius-${shape}`,
|
||||
getButtonSize(),
|
||||
className,
|
||||
block ? 'w-full' : ''
|
||||
)
|
||||
|
||||
const handleClick = (e: MouseEvent<HTMLButtonElement>) => {
|
||||
const { onClick } = props
|
||||
if (disabled || loading) {
|
||||
e.preventDefault()
|
||||
return
|
||||
}
|
||||
onClick?.(e)
|
||||
}
|
||||
|
||||
const renderChildren = () => {
|
||||
if (loading && children) {
|
||||
return (
|
||||
<span className="flex items-center justify-center">
|
||||
<Spinner enableTheme={false} className="mr-1" />
|
||||
{children}
|
||||
</span>
|
||||
)
|
||||
}
|
||||
|
||||
if (icon && !children && loading) {
|
||||
return <Spinner enableTheme={false} />
|
||||
}
|
||||
|
||||
if (icon && !children && !loading) {
|
||||
return <>{icon}</>
|
||||
}
|
||||
|
||||
if (icon && children && !loading) {
|
||||
return (
|
||||
<span className="flex items-center justify-center">
|
||||
<span className="text-lg">{icon}</span>
|
||||
<span className="ltr:ml-1 rtl:mr-1">{children}</span>
|
||||
</span>
|
||||
)
|
||||
}
|
||||
|
||||
return <>{children}</>
|
||||
}
|
||||
|
||||
return (
|
||||
<button ref={ref} className={classes} {...rest} onClick={handleClick}>
|
||||
{renderChildren()}
|
||||
</button>
|
||||
)
|
||||
return (
|
||||
<button ref={ref} className={classes} {...rest} onClick={handleClick}>
|
||||
{renderChildren()}
|
||||
</button>
|
||||
)
|
||||
})
|
||||
|
||||
Button.displayName = 'Button'
|
||||
|
|
|
|||
|
|
@ -311,7 +311,7 @@ const DateTimepicker = forwardRef<HTMLInputElement, DateTimepickerProps>(
|
|||
size="sm"
|
||||
onChange={handleTimeChange}
|
||||
/>
|
||||
<Button size="sm" disabled={!_value} onClick={handleOk}>
|
||||
<Button size="sm" variant='solid' disabled={!_value} onClick={handleOk}>
|
||||
{okButtonContent}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@ import Notification from '../Notification/Notification'
|
|||
import toast from '../toast/toast'
|
||||
import type { CommonProps } from '../@types/common'
|
||||
import type { ReactNode, ChangeEvent, MouseEvent } from 'react'
|
||||
import { useLocalization } from '@/utils/hooks/useLocalization'
|
||||
|
||||
export interface UploadProps extends CommonProps {
|
||||
accept?: string
|
||||
|
|
@ -56,6 +57,7 @@ const Upload = forwardRef<HTMLDivElement, UploadProps>((props, ref) => {
|
|||
const fileInputField = useRef<HTMLInputElement>(null)
|
||||
const [files, setFiles] = useState(fileList)
|
||||
const [dragOver, setDragOver] = useState(false)
|
||||
const { translate } = useLocalization()
|
||||
|
||||
const { themeColor, primaryColorLevel } = useConfig()
|
||||
|
||||
|
|
@ -144,8 +146,8 @@ const Upload = forwardRef<HTMLDivElement, UploadProps>((props, ref) => {
|
|||
const renderChildren = () => {
|
||||
if (!draggable && !children) {
|
||||
return (
|
||||
<Button disabled={disabled} onClick={(e) => e.preventDefault()}>
|
||||
Upload
|
||||
<Button size="sm" variant="solid" disabled={disabled} onClick={(e) => e.preventDefault()}>
|
||||
{translate('::FileManager.Upload')}
|
||||
</Button>
|
||||
)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ const Log = ({
|
|||
))}
|
||||
<div className="text-center">
|
||||
{loadable ? (
|
||||
<Button loading={isLoading} onClick={onLoadMore} className="dark:bg-gray-700 dark:text-white dark:hover:bg-gray-600">
|
||||
<Button size="sm" loading={isLoading} onClick={onLoadMore} variant='solid'>
|
||||
{translate('::Abp.Identity.ActivityLogs.LoadMore')}
|
||||
</Button>
|
||||
) : (
|
||||
|
|
|
|||
|
|
@ -59,10 +59,11 @@ export const CreateFolderModal = forwardRef<HTMLDivElement, CreateFolderModalPro
|
|||
</form>
|
||||
|
||||
<div className="flex justify-end space-x-2 pt-4 border-t">
|
||||
<Button variant="default" onClick={handleClose} disabled={loading}>
|
||||
<Button size='sm' variant="default" onClick={handleClose} disabled={loading}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button
|
||||
size='sm'
|
||||
variant="solid"
|
||||
onClick={handleSubmit}
|
||||
loading={loading}
|
||||
|
|
@ -156,10 +157,11 @@ export const RenameItemModal = forwardRef<HTMLDivElement, RenameItemModalProps>(
|
|||
</form>
|
||||
|
||||
<div className="flex justify-end space-x-2 pt-4 border-t">
|
||||
<Button variant="default" onClick={handleClose} disabled={loading}>
|
||||
<Button size='sm' variant="default" onClick={handleClose} disabled={loading}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button
|
||||
size='sm'
|
||||
variant="solid"
|
||||
onClick={handleSubmit}
|
||||
loading={loading}
|
||||
|
|
@ -238,12 +240,12 @@ export const DeleteConfirmModal = forwardRef<HTMLDivElement, DeleteConfirmModalP
|
|||
</div>
|
||||
|
||||
<div className="flex justify-end space-x-2 pt-4 border-t">
|
||||
<Button variant="default" onClick={onClose} disabled={loading}>
|
||||
<Button size='sm' variant="default" onClick={onClose} disabled={loading}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button
|
||||
size='sm'
|
||||
variant="solid"
|
||||
className="bg-red-600 hover:bg-red-700 text-white"
|
||||
onClick={handleDelete}
|
||||
loading={loading}
|
||||
>
|
||||
|
|
|
|||
|
|
@ -355,10 +355,11 @@ const FileUploadModal = forwardRef<HTMLDivElement, FileUploadModalProps>((props,
|
|||
Clear Errors
|
||||
</Button>
|
||||
)}
|
||||
<Button variant="default" onClick={handleClose} disabled={uploading}>
|
||||
<Button size="sm" variant="default" onClick={handleClose} disabled={uploading}>
|
||||
{uploading ? 'Uploading...' : 'Close'}
|
||||
</Button>
|
||||
<Button
|
||||
size="sm"
|
||||
variant="solid"
|
||||
onClick={handleUpload}
|
||||
disabled={pendingFiles === 0 || uploading}
|
||||
|
|
|
|||
|
|
@ -79,8 +79,8 @@ function ChartTabAnimation(props: FormEditProps) {
|
|||
<Field type="number" name="animationDto.maxPointCountSupported" component={Input} />
|
||||
</FormItem>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -660,8 +660,8 @@ function ChartTabAnnotations(props: FormEditProps) {
|
|||
</TabContent>
|
||||
</Tabs>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -541,8 +541,8 @@ function ChartTabAxis(props: FormEditProps) {
|
|||
</TabContent>
|
||||
</Tabs>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -716,8 +716,8 @@ function ChartTabCommonSettings(props: FormEditProps) {
|
|||
</TabContent>
|
||||
</Tabs>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ function ChartTabCrosshair(props: FormEditProps) {
|
|||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
|
|
@ -112,7 +112,7 @@ function ChartTabCrosshair(props: FormEditProps) {
|
|||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
|
|
@ -157,64 +157,28 @@ function ChartTabCrosshair(props: FormEditProps) {
|
|||
</Card>
|
||||
|
||||
<Card className="my-2" header="Font Options">
|
||||
<FormItem
|
||||
label="Color"
|
||||
invalid={
|
||||
!!(
|
||||
errors.crosshairDto?.label?.font?.color &&
|
||||
touched.crosshairDto?.label?.font?.color
|
||||
)
|
||||
}
|
||||
errorMessage={errors.crosshairDto?.label?.font?.color}
|
||||
>
|
||||
<FormItem label="Color">
|
||||
<Field name="crosshairDto.label.font.color">
|
||||
{({ field, form }: FieldProps) => (
|
||||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Family"
|
||||
invalid={
|
||||
!!(
|
||||
errors.crosshairDto?.label?.font?.family &&
|
||||
touched.crosshairDto?.label?.font?.family
|
||||
)
|
||||
}
|
||||
errorMessage={errors.crosshairDto?.label?.font?.family}
|
||||
>
|
||||
<FormItem label="Family">
|
||||
<Field type="text" name="crosshairDto.label.font.family" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Size"
|
||||
invalid={
|
||||
!!(
|
||||
errors.crosshairDto?.label?.font?.size &&
|
||||
touched.crosshairDto?.label?.font?.size
|
||||
)
|
||||
}
|
||||
errorMessage={errors.crosshairDto?.label?.font?.size}
|
||||
>
|
||||
<FormItem label="Size">
|
||||
<Field type="number" name="crosshairDto.label.font.size" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Weight"
|
||||
invalid={
|
||||
!!(
|
||||
errors.crosshairDto?.label?.font?.weight &&
|
||||
touched.crosshairDto?.label?.font?.weight
|
||||
)
|
||||
}
|
||||
errorMessage={errors.crosshairDto?.label?.font?.weight}
|
||||
>
|
||||
<FormItem label="Weight">
|
||||
<Field type="number" name="crosshairDto.label.font.weight" component={Input} />
|
||||
</FormItem>
|
||||
</Card>
|
||||
|
|
@ -232,7 +196,7 @@ function ChartTabCrosshair(props: FormEditProps) {
|
|||
>
|
||||
<Field name="crosshairDto.horizontalLine.visible" component={Checkbox} />
|
||||
</FormItem>
|
||||
|
||||
|
||||
<FormItem
|
||||
label="Color"
|
||||
invalid={
|
||||
|
|
@ -248,7 +212,7 @@ function ChartTabCrosshair(props: FormEditProps) {
|
|||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
|
|
@ -324,7 +288,7 @@ function ChartTabCrosshair(props: FormEditProps) {
|
|||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
|
|
@ -372,8 +336,8 @@ function ChartTabCrosshair(props: FormEditProps) {
|
|||
</Card>
|
||||
</div>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -65,8 +65,8 @@ function ChartTabExport(props: FormEditProps) {
|
|||
</FormItem>
|
||||
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -216,8 +216,8 @@ function ChartTabLegend(props: FormEditProps) {
|
|||
</Card>
|
||||
</div>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -155,8 +155,8 @@ function ChartTabPanes(props: FormEditProps) {
|
|||
setData={setJsonRowOpModalData}
|
||||
/>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -523,8 +523,8 @@ function ChartTabSeries(props: FormEditProps & { listFormCode: string }) {
|
|||
</TabContent>
|
||||
</Tabs>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -176,8 +176,8 @@ const ChartTabZoomAndPan = (props: FormEditProps) => {
|
|||
</Card>
|
||||
</div>
|
||||
<div className="mt-4">
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -294,8 +294,8 @@ function FormCustomization({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -310,8 +310,8 @@ function FormTabColumns(props: FormEditProps) {
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -387,8 +387,8 @@ function FormTabDatabaseDataSource(props: FormEditProps) {
|
|||
</FormItem>
|
||||
</Card>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -116,8 +116,8 @@ function FormTabDatabaseDelete({
|
|||
</FormItem>
|
||||
</div>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Card>
|
||||
|
||||
|
|
|
|||
|
|
@ -114,8 +114,8 @@ function FormTabDatabaseInsert({
|
|||
/>
|
||||
</FormItem>
|
||||
</div>
|
||||
<Button block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Card>
|
||||
|
||||
|
|
|
|||
|
|
@ -65,8 +65,8 @@ function FormTabDatabaseSelect({
|
|||
component={Input}
|
||||
/>
|
||||
</FormItem>
|
||||
<Button block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Card>
|
||||
|
||||
|
|
|
|||
|
|
@ -114,8 +114,8 @@ function FormTabDatabaseUpdate({
|
|||
/>
|
||||
</FormItem>
|
||||
</div>
|
||||
<Button block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Card>
|
||||
|
||||
|
|
|
|||
|
|
@ -437,8 +437,8 @@ function FormTabDetails(
|
|||
</Card>
|
||||
</div>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -454,8 +454,8 @@ function FormTabEdit(props: FormEditProps & { listFormCode: string }) {
|
|||
)}
|
||||
</Card>
|
||||
</div>
|
||||
<Button block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -304,8 +304,8 @@ function FormTabFilters(props: FormEditProps) {
|
|||
</TabContent>
|
||||
</Tabs>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -471,8 +471,8 @@ function FormTabGantt(props: FormEditProps) {
|
|||
</Card>
|
||||
</div>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -54,8 +54,8 @@ function FormTabGroup(props: FormEditProps) {
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -235,8 +235,8 @@ function FormTabPager(props: FormEditProps) {
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -239,8 +239,8 @@ function FormTabPermissions(props: FormEditProps) {
|
|||
</FormItem>
|
||||
)}
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -186,8 +186,8 @@ function FormTabColumns(props: FormEditProps) {
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -98,8 +98,8 @@ function FormTabRow(props: FormEditProps) {
|
|||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -363,8 +363,8 @@ function FormTabScheduler(props: FormEditProps) {
|
|||
</FormItem>
|
||||
</Card>
|
||||
</div>
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>{' '}
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -55,8 +55,8 @@ function FormTabSearch(props: FormEditProps) {
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -128,8 +128,8 @@ function FormTabSelect(props: FormEditProps) {
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -74,8 +74,8 @@ function FormTabSorting(props: FormEditProps) {
|
|||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -97,8 +97,8 @@ function FormTabState(props: FormEditProps) {
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -185,8 +185,8 @@ function FormTabTree(props: FormEditProps) {
|
|||
component={Checkbox}
|
||||
/>
|
||||
</FormItem>
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit" className="my-2">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -450,8 +450,8 @@ export function FormTabWorkflow(
|
|||
</FormItem>
|
||||
</div>
|
||||
|
||||
<Button block variant="solid" type="submit" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" type="submit" loading={isSubmitting}>
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Card>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -316,8 +316,8 @@ function FormFieldTabConditionalFormatting({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isLoading} type="submit">
|
||||
{isLoading ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isLoading} type="submit">
|
||||
{isLoading ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -63,8 +63,8 @@ function FormFieldTabCssOptions({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -70,8 +70,8 @@ function FormFieldTabCustomization({
|
|||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -133,8 +133,8 @@ function FormFieldTabDetails({
|
|||
</FormItem>
|
||||
</Card>
|
||||
</div>
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Form>
|
||||
)}
|
||||
|
|
|
|||
|
|
@ -84,8 +84,8 @@ function FormFieldTabFiltering({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -176,8 +176,8 @@ function FormFieldTabGroupSummary({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -61,8 +61,8 @@ function FormFieldTabGrouping({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -65,8 +65,8 @@ function FormFieldTabHeadering({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -234,8 +234,8 @@ function FormFieldTabJoinOptions({
|
|||
</FormItem>
|
||||
</Card>
|
||||
</div>
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Form>
|
||||
)}
|
||||
|
|
|
|||
|
|
@ -218,10 +218,8 @@ function TablePickerModal({
|
|||
}}
|
||||
block
|
||||
variant="solid"
|
||||
color="indigo-600"
|
||||
className="mt-1 !h-auto !rounded !py-1.5 text-xs font-semibold text-white transition-colors hover:!bg-indigo-700 disabled:cursor-not-allowed disabled:opacity-40"
|
||||
>
|
||||
Tamam
|
||||
{translate('::OK')}
|
||||
</Button>
|
||||
</>
|
||||
)}
|
||||
|
|
@ -467,8 +465,8 @@ function FormFieldTabLookup({
|
|||
</FormItem>
|
||||
</Card>
|
||||
</div>
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Form>
|
||||
)}
|
||||
|
|
|
|||
|
|
@ -113,8 +113,8 @@ function FormFieldTabOptions({
|
|||
</Card>
|
||||
</div>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Form>
|
||||
)}
|
||||
|
|
|
|||
|
|
@ -159,8 +159,8 @@ function FormFieldTabPermissions({
|
|||
<Field name="permissionDto.i" component={Checkbox} />
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -214,8 +214,8 @@ function FormFieldTabPivotSetting({
|
|||
</FormItem>
|
||||
</Card>
|
||||
</div>
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Form>
|
||||
)}
|
||||
|
|
|
|||
|
|
@ -177,8 +177,8 @@ function FormFieldTabTotalSummary({
|
|||
/>
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -355,8 +355,8 @@ function FormFieldTabValidationRules({
|
|||
<Field name="trim" placeholder="Trim" component={Checkbox} />
|
||||
</FormItem>
|
||||
|
||||
<Button className="mt-1" block variant="solid" loading={isLoading} type="submit">
|
||||
{isLoading ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" className="mt-1" block variant="solid" loading={isLoading} type="submit">
|
||||
{isLoading ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -390,7 +390,7 @@ function FormFields({
|
|||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? '...' : translate('::ListForms.ListFormField.Filter')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
|
|
@ -684,8 +684,8 @@ function FormFields({
|
|||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
@ -1023,8 +1023,8 @@ function FormFields({
|
|||
<Field name="copiedFields.pivotSetting" component={Checkbox} className="mr-1" />
|
||||
</FormItem>
|
||||
</div>
|
||||
<Button block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" block variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -987,10 +987,10 @@ function EditorOptionsBuilderDialog({
|
|||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t border-gray-200 pt-3 mt-1 dark:border-gray-700">
|
||||
<Button size="sm" type="button" variant="plain" icon={<FaTimes />} onClick={onClose}>
|
||||
Vazgeç
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button size="sm" type="button" variant="solid" icon={<FaCheck />} onClick={applyOptions}>
|
||||
Uygula
|
||||
{translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Dialog>
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { Button, Dialog } from '@/components/ui'
|
||||
import { SelectBoxOption } from '@/types/shared'
|
||||
import { useLocalization } from '@/utils/hooks/useLocalization'
|
||||
import Editor from '@monaco-editor/react'
|
||||
import { useEffect, useMemo, useState } from 'react'
|
||||
import { FaBolt, FaCheck, FaCode, FaMagic, FaPlus, FaTimes, FaTrash } from 'react-icons/fa'
|
||||
|
|
@ -558,7 +559,8 @@ function EditorScriptBuilderDialog({
|
|||
const [serviceCall, setServiceCall] = useState('')
|
||||
const [scriptEditorValue, setScriptEditorValue] = useState('')
|
||||
const [lastGeneratedScript, setLastGeneratedScript] = useState('')
|
||||
|
||||
const { translate } = useLocalization()
|
||||
|
||||
useEffect(() => {
|
||||
if (!isOpen) return
|
||||
setCopyMappings([])
|
||||
|
|
@ -1354,7 +1356,7 @@ function EditorScriptBuilderDialog({
|
|||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t border-gray-200 pt-3 mt-1 dark:border-gray-700">
|
||||
<Button size="sm" type="button" variant="plain" icon={<FaTimes />} onClick={onClose}>
|
||||
Vazgeç
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button
|
||||
size="sm"
|
||||
|
|
@ -1366,7 +1368,7 @@ function EditorScriptBuilderDialog({
|
|||
onClose()
|
||||
}}
|
||||
>
|
||||
Uygula
|
||||
{translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Dialog>
|
||||
|
|
|
|||
|
|
@ -95,410 +95,394 @@ function JsonRowOpDialogAnnotation({
|
|||
>
|
||||
{(data.operation === 'create' || data.operation === 'update') && (
|
||||
<Formik
|
||||
initialValues={
|
||||
data.chartAnnotationValues ?? {
|
||||
argument: '',
|
||||
border: {
|
||||
color: '#d3d3d3',
|
||||
cornerRadius: 0,
|
||||
dashStyle: 'solid',
|
||||
visible: false,
|
||||
width: 1,
|
||||
},
|
||||
color: '',
|
||||
description: '',
|
||||
font: {
|
||||
color: '#FFFFFF',
|
||||
family: '"Segoe UI", "Helvetica Neue", "Trebuchet MS", Verdana, sans-serif',
|
||||
size: 12,
|
||||
weight: 400,
|
||||
},
|
||||
height: 0,
|
||||
image: '',
|
||||
name: '',
|
||||
offsetX: 0,
|
||||
offsetY: 0,
|
||||
paddingLeftRight: 0,
|
||||
paddingTopBottom: 0,
|
||||
series: '',
|
||||
text: '',
|
||||
tooltipEnabled: false,
|
||||
type: '',
|
||||
value: '',
|
||||
width: 0,
|
||||
wordWrap: '',
|
||||
x: 0,
|
||||
y: 0,
|
||||
}
|
||||
initialValues={
|
||||
data.chartAnnotationValues ?? {
|
||||
argument: '',
|
||||
border: {
|
||||
color: '#d3d3d3',
|
||||
cornerRadius: 0,
|
||||
dashStyle: 'solid',
|
||||
visible: false,
|
||||
width: 1,
|
||||
},
|
||||
color: '',
|
||||
description: '',
|
||||
font: {
|
||||
color: '#FFFFFF',
|
||||
family: '"Segoe UI", "Helvetica Neue", "Trebuchet MS", Verdana, sans-serif',
|
||||
size: 12,
|
||||
weight: 400,
|
||||
},
|
||||
height: 0,
|
||||
image: '',
|
||||
name: '',
|
||||
offsetX: 0,
|
||||
offsetY: 0,
|
||||
paddingLeftRight: 0,
|
||||
paddingTopBottom: 0,
|
||||
series: '',
|
||||
text: '',
|
||||
tooltipEnabled: false,
|
||||
type: '',
|
||||
value: '',
|
||||
width: 0,
|
||||
wordWrap: '',
|
||||
x: 0,
|
||||
y: 0,
|
||||
}
|
||||
validationSchema={schema}
|
||||
onSubmit={async (values, { setSubmitting }) => {
|
||||
setSubmitting(true)
|
||||
try {
|
||||
const input: ListFormJsonRowDto = {
|
||||
index: data.index,
|
||||
fieldName: data.tabName,
|
||||
itemChartAnnotation: values,
|
||||
}
|
||||
if (data.index === -1) {
|
||||
await postListFormJsonRow(data.id, input)
|
||||
} else {
|
||||
await putListFormJsonRow(data.id, input)
|
||||
}
|
||||
toast.push(
|
||||
<Notification type="success">
|
||||
{data.index === -1 ? 'Kayıt eklendi' : 'Kayıt güncellendi'}
|
||||
</Notification>,
|
||||
{ placement: 'top-end' },
|
||||
)
|
||||
handleClose()
|
||||
} catch (error: any) {
|
||||
toast.push(
|
||||
<Notification type="danger">
|
||||
Hata
|
||||
<code>{error}</code>
|
||||
</Notification>,
|
||||
{ placement: 'top-end' },
|
||||
)
|
||||
} finally {
|
||||
setSubmitting(false)
|
||||
}
|
||||
validationSchema={schema}
|
||||
onSubmit={async (values, { setSubmitting }) => {
|
||||
setSubmitting(true)
|
||||
try {
|
||||
const input: ListFormJsonRowDto = {
|
||||
index: data.index,
|
||||
fieldName: data.tabName,
|
||||
itemChartAnnotation: values,
|
||||
}
|
||||
}}
|
||||
>
|
||||
{({ touched, errors, values, isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2 overflow-hidden">
|
||||
<h5 className="flex-shrink-0">{data.index === -1 ? 'Add' : 'Update'}</h5>
|
||||
<div className="flex-1 overflow-y-auto">
|
||||
<Tabs defaultValue="annotations_general">
|
||||
<TabList>
|
||||
<TabNav value="annotations_general">General</TabNav>
|
||||
<TabNav value="annotations_border">Border</TabNav>
|
||||
</TabList>
|
||||
<TabContent value="annotations_general">
|
||||
<div className="p-3 grid grid-cols-3 gap-x-4 gap-y-1">
|
||||
<FormItem
|
||||
label="Tooltip Enabled"
|
||||
invalid={errors.tooltipEnabled && touched.tooltipEnabled}
|
||||
errorMessage={errors.tooltipEnabled}
|
||||
>
|
||||
<Field name="tooltipEnabled" component={Checkbox} />
|
||||
</FormItem>
|
||||
if (data.index === -1) {
|
||||
await postListFormJsonRow(data.id, input)
|
||||
} else {
|
||||
await putListFormJsonRow(data.id, input)
|
||||
}
|
||||
toast.push(
|
||||
<Notification type="success">
|
||||
{data.index === -1 ? 'Kayıt eklendi' : 'Kayıt güncellendi'}
|
||||
</Notification>,
|
||||
{ placement: 'top-end' },
|
||||
)
|
||||
handleClose()
|
||||
} catch (error: any) {
|
||||
toast.push(
|
||||
<Notification type="danger">
|
||||
Hata
|
||||
<code>{error}</code>
|
||||
</Notification>,
|
||||
{ placement: 'top-end' },
|
||||
)
|
||||
} finally {
|
||||
setSubmitting(false)
|
||||
}
|
||||
}}
|
||||
>
|
||||
{({ touched, errors, values, isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2 overflow-hidden">
|
||||
<h5 className="flex-shrink-0">{data.index === -1 ? 'Add' : 'Update'}</h5>
|
||||
<div className="flex-1 overflow-y-auto">
|
||||
<Tabs defaultValue="annotations_general">
|
||||
<TabList>
|
||||
<TabNav value="annotations_general">General</TabNav>
|
||||
<TabNav value="annotations_border">Border</TabNav>
|
||||
</TabList>
|
||||
<TabContent value="annotations_general">
|
||||
<div className="p-3 grid grid-cols-3 gap-x-4 gap-y-1">
|
||||
<FormItem
|
||||
label="Tooltip Enabled"
|
||||
invalid={errors.tooltipEnabled && touched.tooltipEnabled}
|
||||
errorMessage={errors.tooltipEnabled}
|
||||
>
|
||||
<Field name="tooltipEnabled" component={Checkbox} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Type"
|
||||
invalid={errors.type && touched.type}
|
||||
errorMessage={errors.type}
|
||||
>
|
||||
<Field type="text" name="type">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
options={chartAnnotationTypeListOptions}
|
||||
isClearable={true}
|
||||
value={chartAnnotationTypeListOptions.filter(
|
||||
(option) => option.value === values.type,
|
||||
)}
|
||||
onChange={(option) =>
|
||||
form.setFieldValue(field.name, option?.value)
|
||||
}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Type"
|
||||
invalid={errors.type && touched.type}
|
||||
errorMessage={errors.type}
|
||||
>
|
||||
<Field type="text" name="type">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
options={chartAnnotationTypeListOptions}
|
||||
isClearable={true}
|
||||
value={chartAnnotationTypeListOptions.filter(
|
||||
(option) => option.value === values.type,
|
||||
)}
|
||||
onChange={(option) => form.setFieldValue(field.name, option?.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Series"
|
||||
invalid={errors.series && touched.series}
|
||||
errorMessage={errors.series}
|
||||
>
|
||||
<Field type="text" name="series">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
isClearable={true}
|
||||
options={SeriesList()}
|
||||
value={SeriesList()?.find(
|
||||
(option) => option.value === values.series,
|
||||
)}
|
||||
onChange={(option) =>
|
||||
form.setFieldValue(field.name, option?.value)
|
||||
}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Series"
|
||||
invalid={errors.series && touched.series}
|
||||
errorMessage={errors.series}
|
||||
>
|
||||
<Field type="text" name="series">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
isClearable={true}
|
||||
options={SeriesList()}
|
||||
value={SeriesList()?.find(
|
||||
(option) => option.value === values.series,
|
||||
)}
|
||||
onChange={(option) => form.setFieldValue(field.name, option?.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Name"
|
||||
invalid={errors.name && touched.name}
|
||||
errorMessage={errors.name}
|
||||
>
|
||||
<Field type="text" name="name" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Name"
|
||||
invalid={errors.name && touched.name}
|
||||
errorMessage={errors.name}
|
||||
>
|
||||
<Field type="text" name="name" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Text"
|
||||
invalid={errors.text && touched.text}
|
||||
errorMessage={errors.text}
|
||||
>
|
||||
<Field type="text" name="text" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Text"
|
||||
invalid={errors.text && touched.text}
|
||||
errorMessage={errors.text}
|
||||
>
|
||||
<Field type="text" name="text" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Value"
|
||||
invalid={errors.value && touched.value}
|
||||
errorMessage={errors.value}
|
||||
>
|
||||
<Field type="text" name="value" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Value"
|
||||
invalid={errors.value && touched.value}
|
||||
errorMessage={errors.value}
|
||||
>
|
||||
<Field type="text" name="value" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Argument"
|
||||
invalid={errors.argument && touched.argument}
|
||||
errorMessage={errors.argument}
|
||||
>
|
||||
<Field name="argument" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Argument"
|
||||
invalid={errors.argument && touched.argument}
|
||||
errorMessage={errors.argument}
|
||||
>
|
||||
<Field name="argument" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Color"
|
||||
invalid={errors.color && touched.color}
|
||||
errorMessage={errors.color}
|
||||
>
|
||||
<Field name="color">
|
||||
{({ field, form }: FieldProps) => (
|
||||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Color"
|
||||
invalid={errors.color && touched.color}
|
||||
errorMessage={errors.color}
|
||||
>
|
||||
<Field name="color">
|
||||
{({ field, form }: FieldProps) => (
|
||||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Word Wrap"
|
||||
invalid={errors.wordWrap && touched.wordWrap}
|
||||
errorMessage={errors.wordWrap}
|
||||
>
|
||||
<Field type="text" name="wordWrap">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
options={chartTitleWordWrapListOptions}
|
||||
isClearable={true}
|
||||
value={chartTitleWordWrapListOptions.filter(
|
||||
(option) => option.value === values.wordWrap,
|
||||
)}
|
||||
onChange={(option) =>
|
||||
form.setFieldValue(field.name, option?.value)
|
||||
}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Word Wrap"
|
||||
invalid={errors.wordWrap && touched.wordWrap}
|
||||
errorMessage={errors.wordWrap}
|
||||
>
|
||||
<Field type="text" name="wordWrap">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
options={chartTitleWordWrapListOptions}
|
||||
isClearable={true}
|
||||
value={chartTitleWordWrapListOptions.filter(
|
||||
(option) => option.value === values.wordWrap,
|
||||
)}
|
||||
onChange={(option) => form.setFieldValue(field.name, option?.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Description"
|
||||
invalid={errors.description && touched.description}
|
||||
errorMessage={errors.description}
|
||||
>
|
||||
<Field type="text" name="description" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Description"
|
||||
invalid={errors.description && touched.description}
|
||||
errorMessage={errors.description}
|
||||
>
|
||||
<Field type="text" name="description" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Image"
|
||||
invalid={errors.image && touched.image}
|
||||
errorMessage={errors.image}
|
||||
>
|
||||
<Field type="text" name="image" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Image"
|
||||
invalid={errors.image && touched.image}
|
||||
errorMessage={errors.image}
|
||||
>
|
||||
<Field type="text" name="image" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Width"
|
||||
invalid={errors.width && touched.width}
|
||||
errorMessage={errors.width}
|
||||
>
|
||||
<Field type="number" name="width" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Width"
|
||||
invalid={errors.width && touched.width}
|
||||
errorMessage={errors.width}
|
||||
>
|
||||
<Field type="number" name="width" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Height"
|
||||
invalid={errors.height && touched.height}
|
||||
errorMessage={errors.height}
|
||||
>
|
||||
<Field type="number" name="height" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Height"
|
||||
invalid={errors.height && touched.height}
|
||||
errorMessage={errors.height}
|
||||
>
|
||||
<Field type="number" name="height" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Padding Left/Right"
|
||||
invalid={errors.paddingLeftRight && touched.paddingLeftRight}
|
||||
errorMessage={errors.paddingLeftRight}
|
||||
>
|
||||
<Field type="number" name="paddingLeftRight" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Padding Left/Right"
|
||||
invalid={errors.paddingLeftRight && touched.paddingLeftRight}
|
||||
errorMessage={errors.paddingLeftRight}
|
||||
>
|
||||
<Field type="number" name="paddingLeftRight" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Padding Top/Bottom"
|
||||
invalid={errors.paddingTopBottom && touched.paddingTopBottom}
|
||||
errorMessage={errors.paddingTopBottom}
|
||||
>
|
||||
<Field type="number" name="paddingTopBottom" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Padding Top/Bottom"
|
||||
invalid={errors.paddingTopBottom && touched.paddingTopBottom}
|
||||
errorMessage={errors.paddingTopBottom}
|
||||
>
|
||||
<Field type="number" name="paddingTopBottom" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="X"
|
||||
invalid={errors.x && touched.x}
|
||||
errorMessage={errors.x}
|
||||
>
|
||||
<Field type="number" name="x" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem label="X" invalid={errors.x && touched.x} errorMessage={errors.x}>
|
||||
<Field type="number" name="x" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Y"
|
||||
invalid={errors.y && touched.y}
|
||||
errorMessage={errors.y}
|
||||
>
|
||||
<Field type="number" name="y" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem label="Y" invalid={errors.y && touched.y} errorMessage={errors.y}>
|
||||
<Field type="number" name="y" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="OffsetX"
|
||||
invalid={errors.offsetX && touched.offsetX}
|
||||
errorMessage={errors.offsetX}
|
||||
>
|
||||
<Field type="number" name="offsetX" component={Input} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="OffsetX"
|
||||
invalid={errors.offsetX && touched.offsetX}
|
||||
errorMessage={errors.offsetX}
|
||||
>
|
||||
<Field type="number" name="offsetX" component={Input} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="OffsetY"
|
||||
invalid={errors.offsetY && touched.offsetY}
|
||||
errorMessage={errors.offsetY}
|
||||
>
|
||||
<Field type="number" name="offsetY" component={Input} />
|
||||
</FormItem>
|
||||
</div>
|
||||
</TabContent>
|
||||
<TabContent value="annotations_border">
|
||||
<div className="p-3 grid grid-cols-2 gap-x-4 gap-y-1">
|
||||
<FormItem
|
||||
label="Visible"
|
||||
invalid={errors.border?.visible && touched.border?.visible}
|
||||
errorMessage={errors.border?.visible}
|
||||
>
|
||||
<Field name="border.visible" component={Checkbox} />
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="OffsetY"
|
||||
invalid={errors.offsetY && touched.offsetY}
|
||||
errorMessage={errors.offsetY}
|
||||
>
|
||||
<Field type="number" name="offsetY" component={Input} />
|
||||
</FormItem>
|
||||
</div>
|
||||
</TabContent>
|
||||
<TabContent value="annotations_border">
|
||||
<div className="p-3 grid grid-cols-2 gap-x-4 gap-y-1">
|
||||
<FormItem
|
||||
label="Visible"
|
||||
invalid={errors.border?.visible && touched.border?.visible}
|
||||
errorMessage={errors.border?.visible}
|
||||
>
|
||||
<Field name="border.visible" component={Checkbox} />
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Color"
|
||||
invalid={errors.border?.color && touched.border?.color}
|
||||
errorMessage={errors.border?.color}
|
||||
>
|
||||
<Field name="border.color">
|
||||
{({ field, form }: FieldProps) => (
|
||||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Color"
|
||||
invalid={errors.border?.color && touched.border?.color}
|
||||
errorMessage={errors.border?.color}
|
||||
>
|
||||
<Field name="border.color">
|
||||
{({ field, form }: FieldProps) => (
|
||||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Dash Style"
|
||||
invalid={errors.border?.dashStyle && touched.border?.dashStyle}
|
||||
errorMessage={errors.border?.dashStyle}
|
||||
>
|
||||
<Field type="text" name="border.dashStyle">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
options={chartSeriesDashStyleOptions}
|
||||
isClearable={true}
|
||||
value={chartSeriesDashStyleOptions.filter(
|
||||
(option) => option.value === values.border.dashStyle,
|
||||
)}
|
||||
onChange={(option) =>
|
||||
form.setFieldValue(field.name, option?.value)
|
||||
}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
<FormItem
|
||||
label="Dash Style"
|
||||
invalid={errors.border?.dashStyle && touched.border?.dashStyle}
|
||||
errorMessage={errors.border?.dashStyle}
|
||||
>
|
||||
<Field type="text" name="border.dashStyle">
|
||||
{({ field, form }: FieldProps<SelectBoxOption>) => (
|
||||
<Select
|
||||
field={field}
|
||||
form={form}
|
||||
options={chartSeriesDashStyleOptions}
|
||||
isClearable={true}
|
||||
value={chartSeriesDashStyleOptions.filter(
|
||||
(option) => option.value === values.border.dashStyle,
|
||||
)}
|
||||
onChange={(option) => form.setFieldValue(field.name, option?.value)}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
</FormItem>
|
||||
|
||||
<FormItem
|
||||
label="Width"
|
||||
invalid={errors.border?.width && touched.border?.width}
|
||||
errorMessage={errors.border?.width}
|
||||
>
|
||||
<Field type="number" name="border.width" component={Input} />
|
||||
</FormItem>
|
||||
</div>
|
||||
</TabContent>
|
||||
</Tabs>
|
||||
</div>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Form>
|
||||
)}
|
||||
</Formik>
|
||||
<FormItem
|
||||
label="Width"
|
||||
invalid={errors.border?.width && touched.border?.width}
|
||||
errorMessage={errors.border?.width}
|
||||
>
|
||||
<Field type="number" name="border.width" component={Input} />
|
||||
</FormItem>
|
||||
</div>
|
||||
</TabContent>
|
||||
</Tabs>
|
||||
</div>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Form>
|
||||
)}
|
||||
</Formik>
|
||||
)}
|
||||
{data.operation === 'delete' && (
|
||||
<Formik
|
||||
initialValues={data}
|
||||
onSubmit={async (values, { setSubmitting }) => {
|
||||
setSubmitting(true)
|
||||
try {
|
||||
await deleteListFormJsonRow(data.id, data.tabName, values.index)
|
||||
toast.push(<Notification type="success">Kayıt silindi </Notification>, {
|
||||
placement: 'top-end',
|
||||
})
|
||||
handleClose()
|
||||
} catch (error: any) {
|
||||
toast.push(
|
||||
<Notification type="danger">
|
||||
Hata
|
||||
<code>{error}</code>
|
||||
</Notification>,
|
||||
{ placement: 'top-end' },
|
||||
)
|
||||
} finally {
|
||||
setSubmitting(false)
|
||||
}
|
||||
}}
|
||||
>
|
||||
{({ isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2">
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Form>
|
||||
)}
|
||||
</Formik>
|
||||
initialValues={data}
|
||||
onSubmit={async (values, { setSubmitting }) => {
|
||||
setSubmitting(true)
|
||||
try {
|
||||
await deleteListFormJsonRow(data.id, data.tabName, values.index)
|
||||
toast.push(<Notification type="success">Kayıt silindi </Notification>, {
|
||||
placement: 'top-end',
|
||||
})
|
||||
handleClose()
|
||||
} catch (error: any) {
|
||||
toast.push(
|
||||
<Notification type="danger">
|
||||
Hata
|
||||
<code>{error}</code>
|
||||
</Notification>,
|
||||
{ placement: 'top-end' },
|
||||
)
|
||||
} finally {
|
||||
setSubmitting(false)
|
||||
}
|
||||
}}
|
||||
>
|
||||
{({ isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2">
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Form>
|
||||
)}
|
||||
</Formik>
|
||||
)}
|
||||
</Dialog>
|
||||
)
|
||||
|
|
|
|||
|
|
@ -310,8 +310,10 @@ function JsonRowOpDialogAxis({
|
|||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) =>
|
||||
form.setFieldValue(field.name, e.target.value)
|
||||
}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
|
|
@ -340,8 +342,10 @@ function JsonRowOpDialogAxis({
|
|||
<Input
|
||||
{...field}
|
||||
type="color"
|
||||
className='!h-10 !p-0 !m-0 !border-0'
|
||||
onChange={(e) => form.setFieldValue(field.name, e.target.value)}
|
||||
className="!h-10 !p-0 !m-0 !border-0"
|
||||
onChange={(e) =>
|
||||
form.setFieldValue(field.name, e.target.value)
|
||||
}
|
||||
/>
|
||||
)}
|
||||
</Field>
|
||||
|
|
@ -450,11 +454,16 @@ function JsonRowOpDialogAxis({
|
|||
</Tabs>
|
||||
</div>
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button
|
||||
size="sm"
|
||||
className="ltr:mr-2 rtl:ml-2"
|
||||
variant="plain"
|
||||
onClick={handleClose}
|
||||
>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
@ -495,10 +504,10 @@ function JsonRowOpDialogAxis({
|
|||
<Form>
|
||||
<FormContainer size="sm">
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -366,11 +366,11 @@ function JsonRowOpDialogCommand({
|
|||
</Tabs>
|
||||
</div>
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
@ -411,10 +411,10 @@ function JsonRowOpDialogCommand({
|
|||
<Form>
|
||||
<FormContainer size="sm">
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{ translate('::Cancel') }
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -239,11 +239,11 @@ function JsonRowOpDialogDatabase({
|
|||
)}
|
||||
</div>
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{ translate('::Cancel') }
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
@ -284,10 +284,10 @@ function JsonRowOpDialogDatabase({
|
|||
<Form>
|
||||
<FormContainer size="sm">
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{ translate('::Cancel') }
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -893,11 +893,11 @@ function JsonRowOpDialogEditForm({
|
|||
{translate('::ListForms.ListFormFieldEdit.HelperOpen')}
|
||||
</Button>
|
||||
<div className="flex gap-2">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{ translate('::Cancel') }
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</Dialog.Footer>
|
||||
|
|
@ -930,14 +930,14 @@ function JsonRowOpDialogEditForm({
|
|||
{({ isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2">
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
<h5>{translate('::Delete')}</h5>
|
||||
<p>{translate('::DeleteConfirmation')}</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{ translate('::Cancel') }
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
|
|
|
|||
|
|
@ -286,11 +286,11 @@ function JsonRowOpDialogExtraFilter({
|
|||
</FormItem>
|
||||
</div>
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
@ -331,10 +331,10 @@ function JsonRowOpDialogExtraFilter({
|
|||
<Form>
|
||||
<FormContainer size="sm">
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -152,11 +152,11 @@ function JsonRowOpDialogPane({
|
|||
</FormItem>
|
||||
</div>
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
@ -196,10 +196,10 @@ function JsonRowOpDialogPane({
|
|||
<Form>
|
||||
<FormContainer size="sm">
|
||||
<div className="text-right mt-4">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" className="ltr:mr-2 rtl:ml-2" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -535,11 +535,11 @@ function JsonRowOpDialogSeries({
|
|||
</div>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Form>
|
||||
|
|
@ -573,14 +573,14 @@ function JsonRowOpDialogSeries({
|
|||
{({ isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2">
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
<h5>{translate('::Delete')}</h5>
|
||||
<p>{translate('::DeleteConfirmation')}</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
|
|
|
|||
|
|
@ -433,11 +433,11 @@ function JsonRowOpDialogSubForm({
|
|||
</div>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Form>
|
||||
|
|
@ -470,14 +470,14 @@ function JsonRowOpDialogSubForm({
|
|||
{({ isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2">
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
<h5>{translate('::Delete')}</h5>
|
||||
<p>{translate('::DeleteConfirmation')}</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
|
|
|
|||
|
|
@ -427,11 +427,11 @@ function JsonRowOpDialogWidget({
|
|||
</div>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Form>
|
||||
|
|
@ -466,14 +466,14 @@ function JsonRowOpDialogWidget({
|
|||
{({ isSubmitting }) => (
|
||||
<Form className="flex flex-col h-full">
|
||||
<Dialog.Body className="flex flex-col gap-2">
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
<h5>{translate('::Delete')}</h5>
|
||||
<p>{translate('::DeleteConfirmation')}</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2 border-t pt-3 mt-1">
|
||||
<Button variant="plain" onClick={handleClose}>
|
||||
Cancel
|
||||
<Button size="sm" variant="plain" onClick={handleClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? 'Deleting' : 'Delete'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
|
|
|
|||
|
|
@ -227,7 +227,7 @@ const WizardFileManager = () => {
|
|||
variant="plain"
|
||||
className="text-red-500 hover:bg-red-50 dark:hover:bg-red-900/20"
|
||||
type="button"
|
||||
title={translate('::App.Platform.Delete') || 'Delete'}
|
||||
title={translate('::Delete') || 'Delete'}
|
||||
loading={deletingFile === f.fileName}
|
||||
onClick={() =>
|
||||
setConfirm({ fileName: f.fileName, wizardName: f.wizardName || f.fileName })
|
||||
|
|
@ -279,16 +279,15 @@ const WizardFileManager = () => {
|
|||
</div>
|
||||
<div className="flex justify-end gap-2 mt-4">
|
||||
<Button size="sm" variant="plain" type="button" onClick={() => setConfirm(null)}>
|
||||
İptal
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button
|
||||
size="sm"
|
||||
variant="solid"
|
||||
color="red"
|
||||
type="button"
|
||||
onClick={handleDeleteConfirm}
|
||||
>
|
||||
{translate('::App.Platform.Delete') || 'Yes, Delete'}
|
||||
{translate('::Delete') || 'Yes, Delete'}
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -529,9 +529,7 @@ const WizardStep1 = ({
|
|||
}}
|
||||
size="xs"
|
||||
variant="solid"
|
||||
color="green-500"
|
||||
icon={<FaPlus className="text-xs" />}
|
||||
className="!inline-flex !h-auto !items-center !justify-center gap-1 !rounded !px-2 !py-0.5 text-xs text-white whitespace-nowrap hover:!bg-green-600"
|
||||
>
|
||||
<span className="whitespace-nowrap">
|
||||
{translate('::ListForms.Wizard.Add') || 'Ekle'}
|
||||
|
|
|
|||
|
|
@ -548,7 +548,6 @@ function SortableItem({
|
|||
}}
|
||||
block
|
||||
variant="solid"
|
||||
color="indigo-600"
|
||||
className="mt-1 !h-auto !rounded !py-1.5 text-xs font-semibold text-white transition-colors hover:!bg-indigo-700 disabled:cursor-not-allowed disabled:opacity-40"
|
||||
>
|
||||
Tamam
|
||||
|
|
|
|||
|
|
@ -439,10 +439,15 @@ function WizardStep4({
|
|||
</FormItem>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2">
|
||||
<Button type="button" variant="plain" onClick={() => setDialogIndex(null)}>
|
||||
Cancel
|
||||
<Button
|
||||
size="sm"
|
||||
type="button"
|
||||
variant="plain"
|
||||
onClick={() => setDialogIndex(null)}
|
||||
>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button type="submit" variant="solid">
|
||||
<Button size="sm" type="submit" variant="solid">
|
||||
{translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
|
|
@ -458,15 +463,15 @@ function WizardStep4({
|
|||
onRequestClose={() => setDeleteIndex(null)}
|
||||
>
|
||||
<Dialog.Body>
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
<h5>{translate('::Delete')}</h5>
|
||||
<p>{translate('::DeleteConfirmation')}</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2">
|
||||
<Button type="button" variant="plain" onClick={() => setDeleteIndex(null)}>
|
||||
Cancel
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button type="button" variant="solid" onClick={removeSubForm}>
|
||||
Delete
|
||||
{translate('::Delete')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Dialog>
|
||||
|
|
|
|||
|
|
@ -318,7 +318,7 @@ function WizardStep5({ widgets, translate, onChange, onBack, onNext }: Props) {
|
|||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2">
|
||||
<Button type="button" variant="plain" onClick={() => setDialogIndex(null)}>
|
||||
Cancel
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button type="submit" variant="solid">
|
||||
{translate('::Save')}
|
||||
|
|
@ -336,15 +336,15 @@ function WizardStep5({ widgets, translate, onChange, onBack, onNext }: Props) {
|
|||
onRequestClose={() => setDeleteIndex(null)}
|
||||
>
|
||||
<Dialog.Body>
|
||||
<h5>Delete</h5>
|
||||
<p>Silmek istediğinize emin misiniz?</p>
|
||||
<h5>{translate('::Delete')}</h5>
|
||||
<p>{translate('::DeleteConfirmation')}</p>
|
||||
</Dialog.Body>
|
||||
<Dialog.Footer className="flex justify-end gap-2">
|
||||
<Button type="button" variant="plain" onClick={() => setDeleteIndex(null)}>
|
||||
Cancel
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button type="button" variant="solid" onClick={removeWidget}>
|
||||
Delete
|
||||
{translate('::Delete')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Dialog>
|
||||
|
|
|
|||
|
|
@ -121,7 +121,7 @@ function Section({ title, badge, children, defaultOpen = true }: SectionProps) {
|
|||
onClick={() => setOpen((v) => !v)}
|
||||
variant="plain"
|
||||
shape="none"
|
||||
className="w-full !h-auto !items-center !justify-between !rounded-none bg-gray-50 !px-4 !py-2.5 transition-colors hover:!bg-gray-100 dark:bg-gray-800 dark:hover:!bg-gray-750"
|
||||
className="w-full !h-auto !items-center !justify-between !rounded-none !bg-gray-50 !px-4 !py-2.5 transition-colors hover:!bg-gray-100 dark:!bg-gray-800 dark:hover:!bg-gray-700"
|
||||
>
|
||||
<div className="flex items-center gap-2">
|
||||
{open ? (
|
||||
|
|
|
|||
|
|
@ -463,6 +463,7 @@ export function WorkflowCriteria({
|
|||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button
|
||||
size="sm"
|
||||
type="button"
|
||||
variant="plain"
|
||||
disabled={busy || !formValues.id}
|
||||
|
|
@ -470,7 +471,7 @@ export function WorkflowCriteria({
|
|||
>
|
||||
{translate('::Delete')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={busy} type="submit">
|
||||
<Button size="sm" variant="solid" loading={busy} type="submit">
|
||||
{translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
|
|
|
|||
|
|
@ -177,8 +177,8 @@ function DesignerToolbar({
|
|||
<div className="flex flex-wrap justify-end gap-2">
|
||||
<Button
|
||||
type="button"
|
||||
variant="plain"
|
||||
shape="none"
|
||||
variant="solid"
|
||||
shape="round"
|
||||
className={classNames(
|
||||
designerButtonClass,
|
||||
'border-gray-300 !bg-white text-slate-700 hover:!bg-gray-50 dark:border-gray-700 dark:!bg-gray-800 dark:text-gray-200 dark:hover:!bg-gray-700',
|
||||
|
|
@ -192,8 +192,8 @@ function DesignerToolbar({
|
|||
</Button>
|
||||
<Button
|
||||
type="button"
|
||||
variant="plain"
|
||||
shape="none"
|
||||
variant="solid"
|
||||
shape="round"
|
||||
className={classNames(
|
||||
designerButtonClass,
|
||||
'border-blue-600 !bg-white text-blue-600 hover:!bg-blue-50 dark:border-blue-500 dark:!bg-gray-800 dark:text-blue-300 dark:hover:!bg-blue-900/30',
|
||||
|
|
@ -207,8 +207,8 @@ function DesignerToolbar({
|
|||
</Button>
|
||||
<Button
|
||||
type="button"
|
||||
variant="plain"
|
||||
shape="none"
|
||||
variant="solid"
|
||||
shape="round"
|
||||
className={classNames(
|
||||
designerIconButtonClass,
|
||||
'border-blue-600 !bg-white text-blue-600 hover:!bg-blue-50 dark:border-blue-500 dark:!bg-gray-800 dark:text-blue-300 dark:hover:!bg-blue-900/30',
|
||||
|
|
@ -220,8 +220,8 @@ function DesignerToolbar({
|
|||
</Button>
|
||||
<Button
|
||||
type="button"
|
||||
variant="plain"
|
||||
shape="none"
|
||||
variant="solid"
|
||||
shape="round"
|
||||
className={classNames(
|
||||
designerIconButtonClass,
|
||||
'border-blue-600 !bg-white text-blue-600 hover:!bg-blue-50 dark:border-blue-500 dark:!bg-gray-800 dark:text-blue-300 dark:hover:!bg-blue-900/30',
|
||||
|
|
@ -240,8 +240,8 @@ function DesignerToolbar({
|
|||
<Button
|
||||
key={option.value}
|
||||
type="button"
|
||||
variant="plain"
|
||||
shape="none"
|
||||
variant="solid"
|
||||
shape="round"
|
||||
className={classNames(
|
||||
designerButtonClass,
|
||||
'border-blue-600 !bg-white text-blue-600 hover:!bg-blue-50 dark:border-blue-500 dark:!bg-gray-800 dark:text-blue-300 dark:hover:!bg-blue-900/30',
|
||||
|
|
|
|||
|
|
@ -95,10 +95,10 @@ function CreateNotification({
|
|||
</FormItem>
|
||||
|
||||
<div className="mt-6 flex flex-row justify-end gap-3">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
<Button type="button" variant="plain" onClick={onDialogClose}>
|
||||
<Button size="sm" type="button" variant="plain" onClick={onDialogClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -388,7 +388,7 @@ const OrganizationUnits = () => {
|
|||
<div
|
||||
className={classNames(
|
||||
'h-8 text-md flex gap-2 items-center',
|
||||
node.isSelected ? 'bg-indigo-200 text-black dark:text-black' : '',
|
||||
node.isSelected ? 'bg-indigo-100 text-gray-900 dark:bg-gray-700 dark:text-gray-100' : '',
|
||||
)}
|
||||
style={style}
|
||||
ref={dragHandle}
|
||||
|
|
@ -401,7 +401,7 @@ const OrganizationUnits = () => {
|
|||
{node.isInternal && (node.isOpen ? <FaMinusCircle /> : <FaPlusCircle />)}
|
||||
</div>
|
||||
|
||||
<FaFolder className="w-3" color="#337ab7" />
|
||||
<FaFolder className="w-3" />
|
||||
|
||||
<span className="node-text m-1">
|
||||
{node.isEditing ? (
|
||||
|
|
@ -431,21 +431,27 @@ const OrganizationUnits = () => {
|
|||
<Button
|
||||
size='xs'
|
||||
variant='plain'
|
||||
icon={<FaUserPlus color="#2d6da3" />}
|
||||
shape="circle"
|
||||
className="!h-6 !w-6 !bg-blue-50 !p-0 text-blue-600 hover:!bg-blue-100 hover:text-blue-700 dark:!bg-blue-900/30 dark:text-blue-300 dark:hover:!bg-blue-800/60 dark:hover:text-blue-100"
|
||||
icon={<FaUserPlus className="text-xs" />}
|
||||
onClick={() => setIsMoveAllUsersOpen(true)}
|
||||
title={translate('::Abp.Identity.OrganizationUnit.MoveAllUsers')}
|
||||
></Button>
|
||||
<Button
|
||||
size='xs'
|
||||
variant='plain'
|
||||
icon={<FaEdit className="text-teal-900" />}
|
||||
shape="circle"
|
||||
className="!h-6 !w-6 !bg-teal-50 !p-0 text-teal-600 hover:!bg-teal-100 hover:text-teal-700 dark:!bg-teal-900/30 dark:text-teal-300 dark:hover:!bg-teal-800/60 dark:hover:text-teal-100"
|
||||
icon={<FaEdit className="text-xs" />}
|
||||
onClick={() => node.edit()}
|
||||
title={translate('::Abp.Identity.OrganizationUnit.Rename')}
|
||||
></Button>
|
||||
<Button
|
||||
size='xs'
|
||||
variant='plain'
|
||||
icon={<FaTrashAlt color="#d9534f" />}
|
||||
shape="circle"
|
||||
className="!h-6 !w-6 !bg-red-50 !p-0 text-red-600 hover:!bg-red-100 hover:text-red-700 dark:!bg-red-900/30 dark:text-red-300 dark:hover:!bg-red-800/60 dark:hover:text-red-100"
|
||||
icon={<FaTrashAlt className="text-xs" />}
|
||||
onClick={() => setDeleteRow({ id: node.data.id, name: 'Organization Unit' })}
|
||||
title={translate('::Delete')}
|
||||
></Button>
|
||||
|
|
@ -715,10 +721,10 @@ const OrganizationUnits = () => {
|
|||
</FormItem>
|
||||
|
||||
<div className="mt-6 flex flex-row justify-end gap-3">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::...') : translate('::Save')}
|
||||
</Button>
|
||||
<Button type="button" variant="plain" onClick={onDialogClose}>
|
||||
<Button size="sm" type="button" variant="plain" onClick={onDialogClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
@ -1048,10 +1054,11 @@ const OrganizationUnits = () => {
|
|||
</FormItem>
|
||||
|
||||
<div className="mt-6 flex flex-row justify-end gap-3">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::...') : translate('::Save')}
|
||||
</Button>
|
||||
<Button
|
||||
size="sm"
|
||||
type="button"
|
||||
variant="plain"
|
||||
onClick={() => setIsMoveAllUsersOpen(false)}
|
||||
|
|
|
|||
|
|
@ -383,9 +383,16 @@ const General = () => {
|
|||
beforeUpload={beforeUpload}
|
||||
onChange={onChooseImage}
|
||||
>
|
||||
<Button icon={<FaPlus />} type="button"></Button>
|
||||
<Button
|
||||
size="sm"
|
||||
variant="default"
|
||||
icon={<FaPlus />}
|
||||
type="button"
|
||||
></Button>
|
||||
</Upload>
|
||||
<Button
|
||||
size="sm"
|
||||
variant="solid"
|
||||
type="button"
|
||||
icon={<FaTrashAlt />}
|
||||
onClick={() => setImage(undefined)}
|
||||
|
|
@ -403,11 +410,16 @@ const General = () => {
|
|||
</div>
|
||||
</div>
|
||||
<div className="mt-4 ltr:text-right">
|
||||
<Button className="ltr:mr-2 rtl:ml-2" type="button" onClick={() => resetForm()}>
|
||||
<Button
|
||||
size="sm"
|
||||
className="ltr:mr-2 rtl:ml-2"
|
||||
type="button"
|
||||
onClick={() => resetForm()}
|
||||
>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
<Button size="sm" variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -138,7 +138,7 @@ const Password = ({ data }: { data?: LoginHistory[] }) => {
|
|||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
|
|
|
|||
|
|
@ -165,7 +165,7 @@ function PermissionDialogContent({
|
|||
|
||||
<Dialog.Footer className="flex justify-between items-center mt-4 pt-3 border-t">
|
||||
<div className="flex items-center">
|
||||
<Button variant="solid" color="sky-500" onClick={() => setCopyDialogOpen(true)}>
|
||||
<Button variant="plain" onClick={() => setCopyDialogOpen(true)}>
|
||||
{translate('::AbpIdentity.Roles.CopyPermissions')}
|
||||
</Button>
|
||||
</div>
|
||||
|
|
@ -174,7 +174,7 @@ function PermissionDialogContent({
|
|||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isLoading} onClick={onDialogOk}>
|
||||
{isLoading ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isLoading ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</Dialog.Footer>
|
||||
|
|
|
|||
|
|
@ -337,18 +337,17 @@ function TenantConnectionString({
|
|||
disabled={connectionString.isNew}
|
||||
className="mr-auto"
|
||||
type="button"
|
||||
color="red-500"
|
||||
variant="twoTone"
|
||||
variant="plain"
|
||||
onClick={deleteConnectionString}
|
||||
>
|
||||
{translate('::Delete')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
</Button>
|
||||
<Button type="button" variant="plain" onClick={onDialogClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
@ -395,6 +394,9 @@ function TenantConnectionString({
|
|||
</FormItem>
|
||||
|
||||
<div className="mt-6 flex flex-row justify-end gap-3">
|
||||
<Button type="button" variant="plain" onClick={onDialogClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting
|
||||
? connectionString.isNew
|
||||
|
|
@ -404,9 +406,6 @@ function TenantConnectionString({
|
|||
? translate('::Abp.Identity.CreateUser')
|
||||
: translate('::AbpTenantManagement.Tenants.DatabaseSeed')}
|
||||
</Button>
|
||||
<Button type="button" variant="plain" onClick={onDialogClose}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -593,7 +593,7 @@ function UserDetails() {
|
|||
|
||||
<div className="mt-4 ltr:text-right">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</Form>
|
||||
|
|
@ -705,7 +705,7 @@ function UserDetails() {
|
|||
|
||||
<div className="mt-4 ltr:text-right">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</Form>
|
||||
|
|
@ -887,7 +887,7 @@ function UserDetails() {
|
|||
|
||||
<div className="mt-4 ltr:text-right">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</Form>
|
||||
|
|
@ -1244,7 +1244,7 @@ function UserDetails() {
|
|||
|
||||
<div className="mt-4 ltr:text-right">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</Form>
|
||||
|
|
@ -1632,7 +1632,7 @@ function UserDetails() {
|
|||
|
||||
<div className="mt-4 ltr:text-right">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</Form>
|
||||
|
|
@ -1747,12 +1747,12 @@ function UserDetails() {
|
|||
</FormItem>
|
||||
|
||||
<div className="mt-6 flex flex-row justify-end gap-3">
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
</Button>
|
||||
<Button type="button" variant="plain" onClick={() => setOpen(false)}>
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isSubmitting} type="submit">
|
||||
{isSubmitting ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</div>
|
||||
</FormContainer>
|
||||
</Form>
|
||||
|
|
|
|||
|
|
@ -171,10 +171,10 @@ function UserPermissionDialogContent({
|
|||
|
||||
<Dialog.Footer className="flex justify-end items-center mt-4 pt-3 border-t gap-2">
|
||||
<Button variant="plain" onClick={onDialogClose}>
|
||||
Cancel
|
||||
{translate('::Cancel')}
|
||||
</Button>
|
||||
<Button variant="solid" loading={isLoading} onClick={onDialogOk}>
|
||||
{isLoading ? translate('::SavingWithThreeDot') : translate('::Save')}
|
||||
{isLoading ? translate('::Saving') : translate('::Save')}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</>
|
||||
|
|
|
|||
|
|
@ -454,11 +454,11 @@ const RoomList: React.FC = () => {
|
|||
className="flex items-center gap-1"
|
||||
onClick={() => openDeleteModal(classSession)}
|
||||
disabled={!!classSession.actualStartTime}
|
||||
title={translate('::App.Platform.Delete')}
|
||||
title={translate('::Delete')}
|
||||
>
|
||||
|
||||
<span className="hidden sm:inline">
|
||||
{translate('::App.Platform.Delete')}
|
||||
{translate('::Delete')}
|
||||
</span>
|
||||
</Button>
|
||||
</>
|
||||
|
|
@ -880,10 +880,10 @@ const RoomList: React.FC = () => {
|
|||
>
|
||||
{translate('::Cancel') || 'İptal'}
|
||||
</Button>
|
||||
<Button type="submit" variant="solid" color="blue-600">
|
||||
<Button type="submit" variant="solid">
|
||||
{showCreateModal
|
||||
? translate('::App.Videoroom.CreateRoom') || 'Oda Oluştur'
|
||||
: translate('::App.Videoroom.SaveChanges') || 'Değişiklikleri Kaydet'}
|
||||
: translate('::App.SaveChanges') || 'Değişiklikleri Kaydet'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</form>
|
||||
|
|
@ -932,7 +932,7 @@ const RoomList: React.FC = () => {
|
|||
{translate('::Cancel') || 'İptal'}
|
||||
</Button>
|
||||
<Button variant="solid" color="red-600" onClick={handleDeleteClass}>
|
||||
{translate('::App.Platform.Delete') || 'Sil'}
|
||||
{translate('::Delete') || 'Sil'}
|
||||
</Button>
|
||||
</Dialog.Footer>
|
||||
</Dialog>
|
||||
|
|
|
|||
|
|
@ -142,8 +142,9 @@ const ExtendLogin = () => {
|
|||
onExpire={() => setFieldValue('captchaResponse', '')}
|
||||
onSuccess={(token: string) => setFieldValue('captchaResponse', token)}
|
||||
/>
|
||||
<Button block loading={isSubmitting} variant="solid" type="submit">
|
||||
{emailSent ? 'Resend Email' : 'Send Email'}
|
||||
<Button variant="solid" block loading={isSubmitting} type="submit">
|
||||
{translate('::Abp.Account.Backto')}
|
||||
{emailSent ? translate('::Resend') : translate('::Send')}
|
||||
</Button>
|
||||
<div className="mt-4 text-center">
|
||||
<span>{translate('::Abp.Account.Backto')} </span>
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue