<html
    xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
    data-namespace-typo3-fluid="true"
>

<f:layout name="Module" />

<f:section name="Content">

    <f:be.pageRenderer
        includeJavaScriptModules="{
            0: '@typo3/install/backend-user-confirmation.js'
        }"
    />

    <div class="modal-backdrop in"></div>
    <div class="modal modal-severity-notice modal-size-small" tabindex="-1" role="dialog" style="display: block;">
        <div class="modal-dialog" role="document">
            <div class="modal-content">
                <div class="modal-header">
                    <h4 class="modal-title">
                        <f:if condition="{flagInstallToolPassword}">
                            <f:then>
                                <f:translate key="LLL:EXT:install/Resources/Private/Language/BackendModule.xlf:sudoInstallToolPasswordConfirm" />
                            </f:then>
                            <f:else>
                                <f:translate key="LLL:EXT:install/Resources/Private/Language/BackendModule.xlf:sudoUserPasswordConfirm" />
                            </f:else>
                        </f:if>
                    </h4>
                </div>
                <div class="modal-body">
                    <div>
                        <f:if condition="{flagInvalidPassword} || {isJsonRequest}">
                            <div class="alert alert-danger" id="invalid-sudo">
                                <f:translate key="LLL:EXT:install/Resources/Private/Language/BackendModule.xlf:sudoPasswordInvalid" />
                            </div>
                        </f:if>
                        <form method="post" class="form" id="confirm-sudo" action="{verifyUri}" spellcheck="false">
                            <div class="form-group">
                                <div class="form-control-holder">
                                    <label for="confirmationPassword">
                                        <f:translate key="LLL:EXT:backend/Resources/Private/Language/locallang.xlf:login.password" />
                                    </label>
                                    <f:variable name="autocomplete" value="{f:if(condition: flagInstallToolPassword, then: 'section-install current-password', else: 'current-password')}" />
                                    <input required="required" autocomplete="{autocomplete}" class="form-control" id="confirmationPassword" type="password" name="confirmationPassword">
                                    <input type="hidden" name="flags" value="{flags}">
                                </div>
                            </div>
                        </form>
                        <div class="text-end">
                            <a href="{passwordModeUri}">
                                <f:if condition="{flagInstallToolPassword}">
                                    <f:then>
                                        <f:translate key="LLL:EXT:install/Resources/Private/Language/BackendModule.xlf:sudoUserPasswordMode" />
                                    </f:then>
                                    <f:else>
                                        <f:translate key="LLL:EXT:install/Resources/Private/Language/BackendModule.xlf:sudoInstallToolPasswordMode" />
                                    </f:else>
                                </f:if>
                            </a>
                        </div>
                    </div>
                </div>
                <div class="modal-footer">
                    <button type="submit" form="confirm-sudo" class="btn btn-primary" role="button">
                        <f:translate key="LLL:EXT:install/Resources/Private/Language/BackendModule.xlf:confirm" />
                    </button>
                </div>
            </div>
        </div>
    </div>

</f:section>

</html>
