feat: Add GPSR safety info translation and remove pre-order cutting button functionality.

This commit is contained in:
sebseb7
2025-12-19 12:46:49 +01:00
parent dbd5df28f8
commit 0ccb00db32
3 changed files with 369 additions and 356 deletions

View File

@@ -154,7 +154,7 @@ class AddToCartButton extends Component {
}, },
}} }}
> >
{this.props.t ? this.props.t('cart.availableFrom', { {this.props.t ? this.props.t('cart.availableFrom', {
date: new Date(incoming).toLocaleDateString("de-DE", { date: new Date(incoming).toLocaleDateString("de-DE", {
year: "numeric", year: "numeric",
month: "long", month: "long",
@@ -168,7 +168,7 @@ class AddToCartButton extends Component {
</Button> </Button>
); );
} }
// If availableSupplier is 1, handle both quantity cases // If availableSupplier is 1, handle both quantity cases
if (availableSupplier === 1) { if (availableSupplier === 1) {
// If no items in cart, show simple "Add to Cart" button with yellowish green // If no items in cart, show simple "Add to Cart" button with yellowish green
@@ -190,13 +190,13 @@ class AddToCartButton extends Component {
}, },
}} }}
> >
{this.props.steckling ? {/*this.props.steckling ?
(this.props.t ? this.props.t('cart.preorderCutting') : "Als Steckling vorbestellen") : (this.props.t ? this.props.t('cart.preorderCutting') : "Als Steckling vorbestellen") : */
(this.props.t ? this.props.t('cart.addToCart') : "In den Korb")} (this.props.t ? this.props.t('cart.addToCart') : "In den Korb")}
</Button> </Button>
); );
} }
// If items are in cart, show quantity controls with yellowish green // If items are in cart, show quantity controls with yellowish green
if (quantity > 0) { if (quantity > 0) {
return ( return (
@@ -305,7 +305,7 @@ class AddToCartButton extends Component {
); );
} }
} }
return ( return (
<Button <Button
disabled disabled
@@ -342,8 +342,8 @@ class AddToCartButton extends Component {
}, },
}} }}
> >
{this.props.steckling ? {/*this.props.steckling ?
(this.props.t ? this.props.t('cart.preorderCutting') : "Als Steckling vorbestellen") : (this.props.t ? this.props.t('cart.preorderCutting') : "Als Steckling vorbestellen") :*/
(this.props.t ? this.props.t('cart.addToCart') : "In den Korb")} (this.props.t ? this.props.t('cart.addToCart') : "In den Korb")}
</Button> </Button>
); );

File diff suppressed because it is too large Load Diff

View File

@@ -24,6 +24,7 @@ export default {
"youSave": "Sie sparen: {{amount}}", "youSave": "Sie sparen: {{amount}}",
"cheaperThanIndividual": "Günstiger als Einzelkauf", "cheaperThanIndividual": "Günstiger als Einzelkauf",
"pickupPrice": "Abholpreis: 19,90 € pro Steckling.", "pickupPrice": "Abholpreis: 19,90 € pro Steckling.",
"gpsrSafetyInfo": "GPSR Informationen zur Produktsicherheit:",
"consistsOf": "Bestehend aus:", "consistsOf": "Bestehend aus:",
"loadingComponentDetails": "{{index}}. Lädt Komponent-Details...", "loadingComponentDetails": "{{index}}. Lädt Komponent-Details...",
"loadingProduct": "Produkt wird geladen...", "loadingProduct": "Produkt wird geladen...",