diff --git a/src/pages/Profile.tsx b/src/pages/Profile.tsx
index 6560f572..fe064698 100644
--- a/src/pages/Profile.tsx
+++ b/src/pages/Profile.tsx
@@ -21,6 +21,7 @@ import RouteSelector from './components/RouteSelector'
//API
// import { /*getGtfsRidesList,*/ getRidesAsync } from 'src/api/profileService'
import { getRoutesAsync } from '../api/gtfsService'
+import Widget from 'src/shared/Widget'
// time inputs
// import { DateSelector } from './components/DateSelector'
@@ -92,7 +93,7 @@ const LineProfileComponent = ({ search }: { search: PageSearchState }) => {
return (
-
+
{t('profile_page')}
@@ -143,7 +144,7 @@ const LineProfileComponent = ({ search }: { search: PageSearchState }) => {
-
+
)
}
diff --git a/src/pages/components/Widget.stories.tsx b/src/pages/components/Widget.stories.tsx
index 75652428..064e47a0 100644
--- a/src/pages/components/Widget.stories.tsx
+++ b/src/pages/components/Widget.stories.tsx
@@ -1,15 +1,16 @@
import type { Meta, StoryObj } from '@storybook/react'
import { BusToolTip } from './MapLayers/BusToolTip'
import '../../shared/shared.css'
+import Widget from 'src/shared/Widget'
const meta = {
title: 'Components/Widget',
component: () => (
-
+
שלום חברים!
ככה נראה widget util
-
+
),
parameters: {
diff --git a/src/pages/dashboard/AllLineschart/AllLinesChart.tsx b/src/pages/dashboard/AllLineschart/AllLinesChart.tsx
index 801d19fa..c669894d 100644
--- a/src/pages/dashboard/AllLineschart/AllLinesChart.tsx
+++ b/src/pages/dashboard/AllLineschart/AllLinesChart.tsx
@@ -6,6 +6,7 @@ import OperatorHbarChart from './OperatorHbarChart/OperatorHbarChart'
import { GroupByRes, useGroupBy } from 'src/api/groupByService'
import { FC } from 'react'
import { Moment } from 'moment/moment'
+import Widget from 'src/shared/Widget'
const convertToChartCompatibleStruct = (arr: GroupByRes[]) => {
return arr.map((item: GroupByRes) => ({
@@ -29,7 +30,7 @@ export const AllLinesChart: FC = ({ startDate, endDate }
})
return (
-
+
{TEXTS.dashboard_page_title}
= ({ startDate, endDate }
) : (
)}
-
+
)
}
diff --git a/src/pages/dashboard/ArrivalByTimeChart/DayTimeChart.tsx b/src/pages/dashboard/ArrivalByTimeChart/DayTimeChart.tsx
index 976622f3..483b15ac 100644
--- a/src/pages/dashboard/ArrivalByTimeChart/DayTimeChart.tsx
+++ b/src/pages/dashboard/ArrivalByTimeChart/DayTimeChart.tsx
@@ -4,6 +4,7 @@ import { Skeleton, Radio, RadioChangeEvent } from 'antd'
import ArrivalByTimeChart from './ArrivalByTimeChart'
import { GroupByRes, useGroupBy } from 'src/api/groupByService'
import { Moment } from 'moment/moment'
+import Widget from 'src/shared/Widget'
const convertToGraphCompatibleStruct = (arr: GroupByRes[]) => {
return arr.map((item: GroupByRes) => ({
@@ -33,7 +34,7 @@ const DayTimeChart: FC = ({ startDate, endDate, operatorId })
})
return (
-
+
{groupByHour ? TEXTS.dashboard_page_graph_title_hour : TEXTS.dashboard_page_graph_title_day}
@@ -52,7 +53,7 @@ const DayTimeChart: FC = ({ startDate, endDate, operatorId })
operatorId={operatorId}
/>
)}
-
+
)
}
diff --git a/src/pages/dashboard/WorstLinesChart/WorstLinesChart.tsx b/src/pages/dashboard/WorstLinesChart/WorstLinesChart.tsx
index 87059d69..55f8e529 100644
--- a/src/pages/dashboard/WorstLinesChart/WorstLinesChart.tsx
+++ b/src/pages/dashboard/WorstLinesChart/WorstLinesChart.tsx
@@ -4,6 +4,7 @@ import LinesHbarChart from './LineHbarChart/LinesHbarChart'
import { TEXTS } from 'src/resources/texts'
import { FC } from 'react'
import { Moment } from 'moment/moment'
+import Widget from 'src/shared/Widget'
interface WorstLinesChartProps {
startDate: Moment
@@ -35,7 +36,7 @@ export const WorstLinesChart: FC = ({ startDate, endDate,
}
return (
-
+
{TEXTS.worst_lines_page_title}
{lineDataLoading ? (
@@ -45,7 +46,7 @@ export const WorstLinesChart: FC = ({ startDate, endDate,
operators_whitelist={['אלקטרה אפיקים', 'דן', 'מטרופולין', 'קווים', 'אגד']}
/>
)}
-
+
)
}
diff --git a/src/pages/gapsPatterns/GapsPatternsPage.tsx b/src/pages/gapsPatterns/GapsPatternsPage.tsx
index 6ff0173c..27778c80 100644
--- a/src/pages/gapsPatterns/GapsPatternsPage.tsx
+++ b/src/pages/gapsPatterns/GapsPatternsPage.tsx
@@ -34,6 +34,7 @@ import { DateSelector } from '../components/DateSelector'
import { INPUT_SIZE } from 'src/resources/sizes'
const { Title } = Typography
import { useTranslation } from 'react-i18next'
+import Widget from 'src/shared/Widget'
// Define prop types for the component
interface BusLineStatisticsProps {
lineRef: number
@@ -71,7 +72,7 @@ function GapsByHour({ lineRef, operatorRef, fromDate, toDate }: BusLineStatistic
return (
lineRef > 0 && (
-
+
{t('dashboard_page_graph_title')}
{isLoading && lineRef ? (
@@ -137,7 +138,7 @@ function GapsByHour({ lineRef, operatorRef, fromDate, toDate }: BusLineStatistic
>
)}
-
+
)
)
}
diff --git a/src/shared/Widget.tsx b/src/shared/Widget.tsx
new file mode 100644
index 00000000..5ce1393c
--- /dev/null
+++ b/src/shared/Widget.tsx
@@ -0,0 +1,5 @@
+const Widget = (props: { children: React.ReactNode }) => {
+ return {props.children}
+}
+
+export default Widget