Optimizasyon ölü kodlar kaldırıldı

This commit is contained in:
Sedat ÖZTÜRK 2026-09-09 12:01:01 +03:00
parent 343bdc2c5d
commit 42d3c55ae3
24 changed files with 11 additions and 226 deletions

View file

@ -136,7 +136,7 @@ DevExtreme bileşenleri bu metadata'ya göre kendini kurar.
| Form | Formik + Yup, DevExtreme Form |
| Kod editörü | Monaco Editor |
| Runtime derleme | @babel/standalone (Custom Component) |
| Takvim/Gantt | FullCalendar, DevExtreme Scheduler/Gantt |
| Takvim/Gantt | DevExtreme Scheduler/Gantt |
| Gerçek zamanlı | @microsoft/signalr |
| PWA | vite-plugin-pwa (Workbox) |
| Node | 24.13 / npm 11 (`volta` ile sabitlenmiş) |

View file

@ -1,4 +1,3 @@
@import './components/index.css';
@import './template/index.css';
@import './vendors/index.css';
@import './tailwind/index.css';

View file

@ -1,152 +0,0 @@
.calendar {
@apply h-full;
.fc {
@apply h-full;
}
.fc-theme-standard .fc-scrollgrid {
@apply border-0;
}
.fc-theme-standard td,
.fc-theme-standard th {
@apply border-gray-200 dark:border-gray-600;
&:last-child {
border-right: 0;
}
}
.fc .fc-col-header-cell-cushion {
@apply text-gray-900 dark:text-gray-100 py-3;
}
.fc-col-header-cell {
border-width: 0px 0px 1px;
}
.fc .fc-daygrid-day-number {
@apply font-semibold p-2;
}
.fc-view {
@apply rounded-lg border border-gray-200 dark:border-gray-600 bg-white dark:bg-gray-800;
}
.fc-daygrid-dot-event .fc-event-title {
@apply text-gray-900 dark:text-gray-100;
}
.fc .fc-button {
@apply rounded-md py-2;
}
.fc .fc-toolbar {
@apply lg:flex-row flex-col items-start lg:items-center gap-2;
}
.fc .fc-button-primary {
@apply bg-white border border-gray-300 dark:bg-gray-700 dark:border-gray-700 text-gray-600 dark:text-gray-100 font-semibold;
&:focus {
@apply shadow-none;
}
&:hover {
@apply hover:bg-gray-50 dark:hover:bg-gray-600 hover:border-gray-300 dark:hover:border-gray-700 hover:text-gray-900 hover:dark:text-gray-100;
}
&:disabled {
@apply cursor-not-allowed bg-white border border-gray-300 dark:bg-gray-700 dark:border-gray-700 text-gray-600 dark:text-gray-100;
&:hover {
@apply bg-white border border-gray-300 dark:bg-gray-700 dark:border-gray-700 text-gray-600 dark:text-gray-100;
}
}
}
.fc .fc-button-primary:not(:disabled):active:focus,
.fc .fc-button-primary:not(:disabled).fc-button-active:focus {
@apply shadow-none;
}
.fc .fc-button-primary:not(:disabled):active,
.fc .fc-button-primary:not(:disabled).fc-button-active {
@apply bg-gray-100 border border-gray-300 dark:bg-gray-500 dark:border-gray-500 text-gray-600 dark:text-gray-100;
}
.fc {
.fc-dayGridMonth-button,
.fc-timeGridDay-button,
.fc-timeGridWeek-button,
.fc-today-button {
@apply px-8 capitalize;
}
}
.fc .fc-highlight {
@apply bg-transparent;
}
.fc-daygrid-dot-event:hover,
.fc-daygrid-dot-event.fc-event-mirror {
@apply bg-transparent;
}
.fc .fc-daygrid-event {
@apply p-0 rounded-md mb-2;
}
.fc-h-event {
@apply bg-transparent border-0;
}
.fc-event-selected,
.fc-event:focus {
@apply shadow-none;
&:after {
@apply bg-transparent;
}
}
.fc .fc-cell-shaded,
.fc .fc-day-disabled {
@apply bg-gray-200 dark:bg-gray-500;
}
.fc-daygrid-bg-harness {
.fc-highlight {
@apply bg-gray-100 dark:bg-gray-700;
}
}
.fc-daygrid-event {
@apply text-xs;
}
.fc .custom-calendar-event {
@apply flex items-center min-h-[28px] p-1.5 rounded-md w-full overflow-hidden text-ellipsis h-full;
}
.fc-v-event {
@apply border-0 bg-transparent;
}
.fc .fc-scrollgrid-section table {
@apply !w-full;
}
.fc .fc-daygrid-body {
@apply !w-full;
}
.fc-direction-ltr .fc-toolbar > * > :not(:first-child) {
@apply mx-0;
}
.fc-toolbar-chunk {
@apply flex flex-col sm:flex-row gap-2 w-full sm:w-auto;
}
}

View file

@ -1 +0,0 @@
@import './_full-calendar.css';

View file

@ -1,5 +1,4 @@
import classNames from 'classnames'
import { HEADER_HEIGHT_CLASS } from '@/constants/theme.constant'
import type { ReactNode } from 'react'
import type { CommonProps } from '@/proxy/common'

View file

@ -8,7 +8,6 @@ import { useStoreState, useStoreActions } from '@/store'
import { FaCheck } from 'react-icons/fa'
import type { CommonProps } from '@/proxy/common'
import appConfig from '@/proxy/configs/app.config'
import { useLocalization } from '@/utils/hooks/useLocalization'
const _LanguageSelector = ({ className }: CommonProps) => {
const [loading, setLoading] = useState(false)
@ -22,8 +21,6 @@ const _LanguageSelector = ({ className }: CommonProps) => {
return languageList?.find((lang) => lang.cultureName === currentLang)?.cultureName
}, [currentLang, languageList])
const { translate } = useLocalization()
const selectedLanguage = (
<div className={classNames(className, 'flex items-center')}>
{loading ? (

View file

@ -37,7 +37,7 @@ const ListItem = (props: {
keyWord: string
onNavigate: () => void
}) => {
const { icon, label, url = '', isLast, keyWord, onNavigate } = props
const { label, url = '', isLast, keyWord, onNavigate } = props
const { textTheme } = useThemeClass()

View file

@ -1,7 +1,7 @@
import Button from '@/components/ui/Button'
import ScrollBar from '@/components/ui/ScrollBar'
import classNames from 'classnames'
import { HEADER_HEIGHT_CLASS, DIR_LTR, DIR_RTL } from '@/constants/theme.constant'
import { DIR_LTR, DIR_RTL } from '@/constants/theme.constant'
import VerticalMenuContent from '@/components/template/VerticalMenuContent'
import { FaArrowLeft, FaArrowRight } from 'react-icons/fa'
import type { NavigationTree } from '@/proxy/menus/navigation'

View file

@ -12,7 +12,6 @@ import {
LAYOUT_TYPE_SIMPLE,
LAYOUT_TYPE_DECKED,
LAYOUT_TYPE_BLANK,
NAV_MODE_TRANSPARENT,
} from '@/constants/theme.constant'
import type { LayoutType } from '@/proxy/theme/models'
import { useLocalization } from '@/utils/hooks/useLocalization'
@ -58,7 +57,7 @@ const layouts = [
const LayoutSwitcher = () => {
const type = useStoreState((state) => state.theme.layout.type)
const { setLayout, setNavMode } = useStoreActions((actions) => actions.theme)
const { setLayout } = useStoreActions((actions) => actions.theme)
const onLayoutSelect = (val: LayoutType) => {
setLayout(val)

View file

@ -112,7 +112,7 @@ const AutoComplete = forwardRef<HTMLInputElement, AutoCompleteProps>((props, ref
clearable = true,
name,
field,
form,
form: _form,
minChars = 1,
...rest
} = props

View file

@ -70,7 +70,7 @@ const Chips = forwardRef<HTMLDivElement, ChipsProps>((props, ref) => {
onRemove,
name,
field,
form,
form: _form,
...rest
} = props

View file

@ -118,10 +118,6 @@ const Knob = forwardRef<SVGSVGElement, KnobProps>((props, ref) => {
const fullArcLength = (KNOB_RANGE / 360) * circumference
// Çember yayını SVG stroke-dashoffset ile çiziyoruz
// SVG default: 0 derece = sağ (3 saat), CW pozitif
// Bizim 0 = üst → rotate(-90) + açı offset
const startAngleRad = ((KNOB_START_ANGLE - 90) * Math.PI) / 180
const resolveValueColor = () =>
valueColor ?? `var(--color-${themeColor}-${primaryColorLevel}, #6366f1)`
const resolveRangeColor = () => rangeColor ?? `currentColor`

View file

@ -20,7 +20,7 @@ const MenuCollapse = (props: MenuCollapseProps) => {
const [isExpanded, setIsExpanded] = useState(expanded)
const { menuItemHeight, variant, sideCollapsed, defaultExpandedKeys } = useContext(MenuContext)
const { variant, sideCollapsed, defaultExpandedKeys } = useContext(MenuContext)
const { direction } = useConfig()

View file

@ -37,7 +37,6 @@ const Tooltip = (props: TooltipProps) => {
placement = 'top',
title,
wrapperClass,
...rest
} = props
const [tooltipOpen, setTooltipOpen] = useState<boolean>(isOpen)

View file

@ -1,11 +1,9 @@
import classNames from 'classnames'
import Widget, { type colorType } from './Widget'
import { WidgetEditDto, WidgetGroupDto } from '@/proxy/form/models'
import { useNavigate } from 'react-router-dom'
import { useLocalization } from '@/utils/hooks/useLocalization'
export default function WidgetGroup({ widgetGroups }: { widgetGroups: WidgetGroupDto[] }) {
const navigate = useNavigate()
const { translate } = useLocalization()
// Sorgudan gelen basliklar dil anahtaridir; karsiligi yoksa translate metni aynen dondurur,
@ -54,4 +52,3 @@ export default function WidgetGroup({ widgetGroups }: { widgetGroups: WidgetGrou
</div>
)
}

View file

@ -1,5 +1,4 @@
import { AuditedEntityDto } from '@/proxy/abp'
import { PermissionCrudDto, SummaryTypeEnum } from '@/proxy/form/models'
import { SummaryTypeEnum } from '@/proxy/form/models'
export interface BreakDto {
endValue: number

View file

@ -1,19 +0,0 @@
export type ItemType = 'service' | 'support'
export interface Service {
tenantId?: string
icon?: string
title: string
description?: string
type: ItemType
features: string[]
}
export interface ServiceDto {
tenantId?: string
icon?: string
title: string
description?: string
type: ItemType
features: string[]
}

View file

@ -139,9 +139,6 @@ const DATE_EDITORS = ['dxDateBox', 'dxCalendar', 'dxDateRangeBox']
const IMAGE_EDITORS = ['dxImageUpload', 'dxImageViewer']
const SLIDER_EDITORS = ['dxSlider', 'dxRangeSlider']
/** Metin girişi olmayan editörlerde placeholder/mask alanlarını gizlemek için. */
const NON_INPUT_EDITORS = ['dxCheckBox', 'dxSwitch', 'dxRadioGroup', ...SLIDER_EDITORS]
/* ------------------------------------------------------------------ *
* Ayar sözlüğü
* ------------------------------------------------------------------ */

View file

@ -250,23 +250,6 @@ const OrganizationUnits = () => {
setDialogItem(undefined)
}
const onDropdownItemClick = (node: NodeApi<TreeViewData>, eventKey: string) => {
if (eventKey == 'edit') {
setDialogItem({
id: node.data.id,
displayName: node.data.name,
parentId: node.parent?.isRoot ? undefined : node.parent?.data.id,
})
} else if (eventKey == 'add-sub-unit') {
setDialogItem({
displayName: '',
parentId: node.data.id,
})
} else if (eventKey == 'delete') {
setDeleteRow({ id: node.data.id, name: 'Organization Unit' })
}
}
const onSelect = async (nodes: NodeApi<TreeViewData>[]) => {
if (nodes.length === 0) {
setActiveOu(undefined)

View file

@ -10,7 +10,7 @@ import { FormContainer, FormItem } from '@/components/ui/Form'
import Input from '@/components/ui/Input'
import PlatformLoginResultType from '@/constants/login.result.enum'
import { ROUTES_ENUM } from '@/routes/route.constant'
import { useStoreActions, useStoreState } from '@/store'
import { useStoreActions } from '@/store'
import useAuth from '@/utils/hooks/useAuth'
import { useLocalization } from '@/utils/hooks/useLocalization'
import useTimeOutMessage from '@/utils/hooks/useTimeOutMessage'

View file

@ -17,7 +17,6 @@ import {
orColumnCount,
quoteLiteral,
type CriteriaRow,
type GroupMode,
type ViewSource,
} from './viewModel'

View file

@ -53,7 +53,7 @@ interface SchedulerViewProps {
}
const SchedulerView = (props: SchedulerViewProps) => {
const { listFormCode, searchParams, isSubForm, level, gridDto: extGridDto } = props
const { listFormCode, searchParams, isSubForm, gridDto: extGridDto } = props
const { translate } = useLocalization()
const isPwaMode = usePWA()
const useMobileEditPopup = shouldUseMobileEditPopup()

View file

@ -206,7 +206,7 @@ const priorityLabel = (
}
const TodoBoard = (props: TodoBoardProps) => {
const { listFormCode, searchParams, isSubForm, gridDto: extGridDto } = props
const { listFormCode, gridDto: extGridDto } = props
// Alt form olarak açıldığında tanım dışarıdan gelmez; kendisi yükler.
const gridDto = useListFormGridDto(listFormCode, extGridDto)

View file

@ -92,13 +92,6 @@ const Blog: React.FC = () => {
setCurrentPage(1)
}
const categoryButtonClass = (isActive: boolean) =>
`px-4 py-2 text-sm font-medium rounded-lg transition-colors ${
isActive
? 'bg-blue-600 text-white hover:bg-blue-700 dark:bg-blue-900 dark:hover:bg-blue-800'
: 'bg-gray-200 text-gray-700 hover:bg-gray-300 dark:bg-gray-800 dark:text-gray-200 dark:hover:bg-gray-700'
}`
if (loading && posts.length === 0) {
return <PublicPageLoader />
}