<?xml version="1.0" encoding="UTF-8"?>

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:noNamespaceSchemaLocation="https://raw.githubusercontent.com/shopware/shopware/trunk/src/Core/System/SystemConfig/Schema/config.xsd">

    <card>
        <title>Limited order editing</title>

        <input-field type="bool">
            <name>enabled</name>
            <label>Enable limited-time order editing</label>
            <defaultValue>true</defaultValue>
        </input-field>

        <input-field type="single-select">
            <name>editWindowMinutes</name>
            <label>Customer can edit addresses for (minutes)</label>
            <defaultValue>15</defaultValue>
            <options>
                <option>
                    <id>1</id>
                    <name>1</name>
                </option>
                <option>
                    <id>2</id>
                    <name>2</name>
                </option>
                <option>
                    <id>5</id>
                    <name>5</name>
                </option>
                <option>
                    <id>10</id>
                    <name>10</name>
                </option>
                <option>
                    <id>15</id>
                    <name>15</name>
                </option>
                <option>
                    <id>30</id>
                    <name>30</name>
                </option>
                <option>
                    <id>60</id>
                    <name>60</name>
                </option>
            </options>
        </input-field>

        <input-field type="bool">
            <name>separateStreetAndHouseNumber</name>
            <label>Street and House number in separate fields</label>
            <defaultValue>false</defaultValue>
            <helpText>If enabled, customers will see separate fields for street name and house number when editing addresses.</helpText>
        </input-field>

        <input-field type="bool">
            <name>shippingCountryCanBeChanged</name>
            <label>Shipping country can be changed</label>
            <defaultValue>false</defaultValue>
            <helpText>Changing the shipping country may require additional payment methods/options (depending on shipping costs/taxes). This is not covered yet, but will follow with the next version.</helpText>
        </input-field>

        <input-field type="text">
            <name>editableStateLabel</name>
            <label>Order status label while editable</label>
            <defaultValue>Open for edit</defaultValue>
        </input-field>

        <input-field type="text">
            <name>editableTitleText</name>
            <label>Editable title text (success page)</label>
            <defaultValue></defaultValue>
            <helpText>Leave empty to use the built-in translated text (recommended). Fill in only if you want a custom fixed text for all languages.</helpText>
        </input-field>

        <input-field type="textarea">
            <name>editExpiredMessage</name>
            <label>Message when editing time has expired</label>
            <defaultValue>Sorry, you can't edit this order anymore. The time has expired. Contact our customer service if you need any help.</defaultValue>
            <helpText>This message is shown to the customer when they try to edit an order after the editing window has closed.</helpText>
        </input-field>

        <input-field type="bool">
            <name>applyFreeShippingThresholdRefund</name>
            <label>Apply free shipping threshold refund on upsells</label>
            <defaultValue>false</defaultValue>
            <helpText>If enabled and a post-purchase upsell pushes the combined order total above the free shipping threshold, the shipping cost already paid on the original order is automatically credited as a discount on the supplement order.</helpText>
        </input-field>

        <input-field type="colorpicker">
            <name>colorHeaderBg</name>
            <label>Header background color</label>
            <helpText>Background color for the header bar (title + countdown timer). Leave empty to use the shop's brand primary color.</helpText>
        </input-field>

        <input-field type="colorpicker">
            <name>colorHeaderText</name>
            <label>Header text color</label>
            <helpText>Text color inside the header bar. Leave empty to use white.</helpText>
        </input-field>

        <input-field type="colorpicker">
            <name>colorSectionBg</name>
            <label>Section background color (address &amp; items panels)</label>
            <helpText>Background color for the accordion panel body. Leave empty to use the default light grey.</helpText>
        </input-field>

        <input-field type="colorpicker">
            <name>colorSectionText</name>
            <label>Section text color (address &amp; items panels)</label>
            <helpText>Text color inside the accordion panels. Leave empty to use the default dark color.</helpText>
        </input-field>

        <input-field type="colorpicker">
            <name>colorButtonBg</name>
            <label>Button background color</label>
            <helpText>Background color for the "Add items to order" button. Leave empty to use the shop's brand primary color.</helpText>
        </input-field>

        <input-field type="colorpicker">
            <name>colorButtonText</name>
            <label>Button text color</label>
            <helpText>Text color for the "Add items to order" button. Leave empty to use white.</helpText>
        </input-field>
    </card>

</config>
