src/Cms/ModuleBundle/Resources/views/Content/includes/editor/exit.html.twig line 1

Open in your IDE?
  1. <div id="btnwrapExit" class="editor__btn-wrap">
  2.     {% include '@ui/common/buttons/default.html.twig' with {
  3.         text: 'Cancel',
  4.         htmlId: 'btnExitModal'
  5.     } %}
  6. </div>
  7. {% inline_html %}
  8.     {% embed '@ui/features/workflows/modal.html.twig' with {
  9.         htmlId: 'modalExitModal'
  10.     } %}
  11.         {% block header %}{% endblock %}
  12.         {% block body %}
  13.             <p class="text-center">
  14.                 Are you sure you want to exit the editor?
  15.                 Current changes will be lost.
  16.             </p>
  17.             <p>
  18.                 {% include '@ui/common/buttons/default.html.twig' with {
  19.                     text: 'Exit Editor',
  20.                     helper: 'danger',
  21.                     size: 'lg',
  22.                     block: true,
  23.                     link: redirpath(
  24.                         (draft is defined and draft is not empty) ? routes.draft_list : routes.proxy_list, {
  25.                         container: container.id,
  26.                         module: moduleConfig.key,
  27.                         proxy: (draft is defined and draft is not empty) ? proxy.id : null,
  28.                         draft: null
  29.                     })
  30.                 } %}
  31.             </p>
  32.         {% endblock %}
  33.     {% endembed %}
  34.     {% inline_script %}
  35.         <script>
  36.             $(function() {
  37.                 $('#btnExitModal').click(function (e) {
  38.                     $('#modalExitModal').modal({});
  39.                     e.preventDefault();
  40.                 });
  41.             });
  42.         </script>
  43.     {% endinline %}
  44. {% endinline %}