axidio-styleguide-library1-v2 0.2.93 → 0.2.95
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -7960,26 +7960,9 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
7960
7960
|
};
|
|
7961
7961
|
const labelInfo = hasDateAndTime(d);
|
|
7962
7962
|
// Apply date-week trimming only for mobile and tablet screens
|
|
7963
|
-
|
|
7964
|
-
|
|
7965
|
-
|
|
7966
|
-
if ((isMobileScreen || isTabletScreen) && labelInfo.isDate && labelInfo.isWeek) {
|
|
7967
|
-
const datePartMatch = d.match(/\d{2,4}[-\/]\d{1,2}[-\/]\d{1,4}/);
|
|
7968
|
-
if (!datePartMatch)
|
|
7969
|
-
return d;
|
|
7970
|
-
const datePart = datePartMatch[0];
|
|
7971
|
-
if (isTabletScreen) {
|
|
7972
|
-
// Return only MM/DD (handle both YYYY/MM/DD and MM/DD/YYYY)
|
|
7973
|
-
const parts = datePart.split(/[-\/]/);
|
|
7974
|
-
if (parts[0].length === 4) {
|
|
7975
|
-
// YYYY/MM/DD -> MM/DD
|
|
7976
|
-
return `${parts[1]}/${parts[2]}`;
|
|
7977
|
-
}
|
|
7978
|
-
// MM/DD/YYYY -> MM/DD
|
|
7979
|
-
return `${parts[0]}/${parts[1]}`;
|
|
7980
|
-
}
|
|
7981
|
-
// Mobile: return full date including year
|
|
7982
|
-
return datePart;
|
|
7963
|
+
if (isSmallScreen && labelInfo.isDate && labelInfo.isWeek) {
|
|
7964
|
+
const datePart = d.match(/\d{2,4}[-\/]\d{1,2}[-\/]\d{1,4}/);
|
|
7965
|
+
return datePart ? datePart[0] : d;
|
|
7983
7966
|
}
|
|
7984
7967
|
// Mobile handling: keep date labels intact for single-series charts (do not trim)
|
|
7985
7968
|
if (isMobile) {
|