<commit_before>{% load i18n %}

<!-- Title Block -->
<div class="library-title-block">
    <div class="">
        <h4 class="title-block-title" style=""> {% trans "Card Manager" %} </h4>
    </div>

    <!-- nav bar -->
    <ul class="nav nav-tabs library-tools">
        <li class="active">
            <a href="#card-crud-settings" class="nav-library-tab-link" data-toggle="tab">
                <i class="ion-settings add-tooltip library-tools-icon" data-bind="tooltip: { title: '{% trans "Settings" %}', placement: 'bottom' }"></i>
            </a>
        </li>
        <li>
            <a href="#card-crud-permissions" class="nav-library-tab-link" data-toggle="tab">
                <i class="ion-ios-people add-tooltip library-tools-icon" data-bind="tooltip: { title: '{% trans "Permissions" %}', placement: 'bottom' }"></i>
            </a>
        </li>
        <li>
            <a href="#card-crud-help" class="nav-library-tab-link" data-toggle="tab">
                <i class="ion-ios-help add-tooltip library-tools-icon" data-bind="tooltip: { title: '{% trans "Help Text" %}', placement: 'bottom' }"></i>
            </a>
        </li>
    </ul>

</div>

<!-- Tabs Content -->
<div class="tab-content listing-container">

    <!-- Card Container Base Settings Form -->
    <div id="card-crud-settings" class="tab-pane fade in active">

        <!-- Card Container Property -->
        {% if graph.isresource and graph.ontology_id %}
        <!-- ko if: !($root.card.isContainer()) -->
        <div class="node-widget-label" style="">
            <div class="control-label">
                {% trans "Relation to Resource" %}
            </div>
            <div>
                <select class="resources" data-bind="value: card().get('ontologyproperty'), options: $root.ontology_properties, valueAllowUnset: true, optionsCaption: '{% trans "Choose a relation..." %}', chosen: {disable_search_threshold: 10, width: '100%'}"></select>
            </div>
        </div>
        <!-- /ko -->
        {% endif %}

        <div class="node-widget-label" style="">
            <div class="control-label">
                {% trans "Card Tab Title" %}
            </div>
            <div>
                <input type="" placeholder="{% trans "Card name" %}" class="form-control input-md widget-input" data-bind="value: card().get('name'), valueUpdate: 'keyup'">
            </div>
        </div>

        <div class="node-widget-label" style="">
            <div class="control-label">
                {% trans "Instructions" %}
            </div>
            <div>
                <input type="" placeholder="{% trans "" %}" class="form-control input-md widget-input" data-bind="value: card().get('instructions'), valueUpdate: 'keyup'">
            </div>
        </div>

        <div class="form-divider">
            <h4 class="title-block-title" style=""> {% trans "Settings" %} </h4>
        </div>

        <!-- Set Cardinaltiy -->
        <div data-bind="component: { name: 'switch-widget', params: {value: card().get('cardinality'), config:{on: 'n', off: '1', label: '{% trans "Allow multiple values" %}', subtitle: '{% trans "Let users enter multiple values for this data entry card" %}'}}}"></div>

        <!-- Multiple values tools -->
        <div class="cardinality-form" data-bind="visible: card().get('cardinality')() === 'n'" style="display: none;">
        </div>

    </div>

    <!-- Card CRUD Permissions Form -->
    <div id="card-crud-permissions" class="tab-pane fade" data-bind="with: permissionsList">

        {% include 'views/graph/card-configuration/component-forms/permissions-list.htm' %}

        <!-- Tertiary Panel For Permissions -->
        <div id="permissions-crud" class="tertiary-panel" data-bind="with: permissionsForm">
            {% include 'views/graph/card-configuration/component-forms/permissions-form.htm' %}
        </div>

    </div>

    <!-- Card CRUD HELP Form -->
    <div id="card-crud-help" class="tab-pane fade">

        <!-- Enable help -->
        <div style="margin-top: 20px;" data-bind="component: { name: 'switch-widget', params: {value: card().get('helpenabled'), config:{label: '{% trans "Enable Card-level help" %}', subtitle: '{% trans "Provide specific user guidance for this card" %}'}}}"></div>

        <!-- Tertiary Panel For Card Help Text-->
        <div id="help-text-crud" class="tertiary-panel" style="display: none;" data-bind="visible: card().get('helpenabled')">
            <div class="tertiary-panel-content">
                <div class="">
                    <h4 class="title-block-title" style=""> {% trans "Card-Level Help" %} </h4>
                </div>

                <!-- Help CRUD -->
                <div class="pad-all">
                    <div class="node-widget-label" style="">
                        <div class="control-label">
                            {% trans "Help Panel Title" %}
                        </div>
                        <div class="col-sm-12 pad-no crud-widget-container">
                            <input type="" placeholder="{% trans "Help title" %}" class="form-control input-md widget-input" data-bind='value: card().get("helptitle")'>
                        </div>
                    </div>

                    <!--Rich text editor-->
                    <div class="node-widget-label" style="">
                        <div class="control-label">
                            {% trans "Help Content" %}
                        </div>
                        <textarea rows="10" cols="80" data-bind="ckeditor: card().get('helptext'), ckeditorOptions: {}, valueUpdate: 'afterkeydown'"></textarea>
                    </div>

                    <!-- Preview help -->
                    <div data-bind="component: { name: 'switch-widget', params: {value: helpPreviewActive, config:{label: '{% trans "Preview Help Panel" %}', subtitle: '{% trans "Display help panel, confirm content" %}'}}}"></div>
                    <div class="toggle-container">
                        <input id="preview-card-help" class="arches-switch" type="checkbox" data-switchery="true" style="display: none;">
                    </div>
                </div>
            </div>
        </div>

    </div>
</div>
<commit_msg>added visible and active switches to the card configuration, re #1618<commit_after>{% load i18n %}

<!-- Title Block -->
<div class="library-title-block">
    <div class="">
        <h4 class="title-block-title" style=""> {% trans "Card Manager" %} </h4>
    </div>

    <!-- nav bar -->
    <ul class="nav nav-tabs library-tools">
        <li class="active">
            <a href="#card-crud-settings" class="nav-library-tab-link" data-toggle="tab">
                <i class="ion-settings add-tooltip library-tools-icon" data-bind="tooltip: { title: '{% trans "Settings" %}', placement: 'bottom' }"></i>
            </a>
        </li>
        <li>
            <a href="#card-crud-permissions" class="nav-library-tab-link" data-toggle="tab">
                <i class="ion-ios-people add-tooltip library-tools-icon" data-bind="tooltip: { title: '{% trans "Permissions" %}', placement: 'bottom' }"></i>
            </a>
        </li>
        <li>
            <a href="#card-crud-help" class="nav-library-tab-link" data-toggle="tab">
                <i class="ion-ios-help add-tooltip library-tools-icon" data-bind="tooltip: { title: '{% trans "Help Text" %}', placement: 'bottom' }"></i>
            </a>
        </li>
    </ul>

</div>

<!-- Tabs Content -->
<div class="tab-content listing-container">

    <!-- Card Container Base Settings Form -->
    <div id="card-crud-settings" class="tab-pane fade in active">

        <!-- Card Container Property -->
        {% if graph.isresource and graph.ontology_id %}
        <!-- ko if: !($root.card.isContainer()) -->
        <div class="node-widget-label" style="">
            <div class="control-label">
                {% trans "Relation to Resource" %}
            </div>
            <div>
                <select class="resources" data-bind="value: card().get('ontologyproperty'), options: $root.ontology_properties, valueAllowUnset: true, optionsCaption: '{% trans "Choose a relation..." %}', chosen: {disable_search_threshold: 10, width: '100%'}"></select>
            </div>
        </div>
        <!-- /ko -->
        {% endif %}

        <div class="node-widget-label" style="">
            <div class="control-label">
                {% trans "Card Tab Title" %}
            </div>
            <div>
                <input type="" placeholder="{% trans "Card name" %}" class="form-control input-md widget-input" data-bind="value: card().get('name'), valueUpdate: 'keyup'">
            </div>
        </div>

        <div class="node-widget-label" style="">
            <div class="control-label">
                {% trans "Instructions" %}
            </div>
            <div>
                <input type="" placeholder="{% trans "" %}" class="form-control input-md widget-input" data-bind="value: card().get('instructions'), valueUpdate: 'keyup'">
            </div>
        </div>

        <div class="form-divider">
            <h4 class="title-block-title" style=""> {% trans "Settings" %} </h4>
        </div>

        <!-- Card Visibility -->
        <div data-bind="component: { name: 'switch-widget', params: {value: card().get('visible'), config:{label: '{% trans "Make Card Visible" %}', subtitle: '{% trans "Show this card by default" %}'}}}"></div>

        <!-- Active -->
        <div data-bind="component: { name: 'switch-widget', params: {value: card().get('active'), config:{label: '{% trans "Make Card Active" %}', subtitle: '{% trans "This card is active and can be used for data entry" %}'}}}"></div>

        <!-- Set Cardinaltiy -->
        <div data-bind="component: { name: 'switch-widget', params: {value: card().get('cardinality'), config:{on: 'n', off: '1', label: '{% trans "Allow multiple values" %}', subtitle: '{% trans "Let users enter multiple values for this data entry card" %}'}}}"></div>

        <!-- Multiple values tools -->
        <div class="cardinality-form" data-bind="visible: card().get('cardinality')() === 'n'" style="display: none;">
        </div>

    </div>

    <!-- Card CRUD Permissions Form -->
    <div id="card-crud-permissions" class="tab-pane fade" data-bind="with: permissionsList">

        {% include 'views/graph/card-configuration/component-forms/permissions-list.htm' %}

        <!-- Tertiary Panel For Permissions -->
        <div id="permissions-crud" class="tertiary-panel" data-bind="with: permissionsForm">
            {% include 'views/graph/card-configuration/component-forms/permissions-form.htm' %}
        </div>

    </div>

    <!-- Card CRUD HELP Form -->
    <div id="card-crud-help" class="tab-pane fade">

        <!-- Enable help -->
        <div style="margin-top: 20px;" data-bind="component: { name: 'switch-widget', params: {value: card().get('helpenabled'), config:{label: '{% trans "Enable Card-level help" %}', subtitle: '{% trans "Provide specific user guidance for this card" %}'}}}"></div>

        <!-- Tertiary Panel For Card Help Text-->
        <div id="help-text-crud" class="tertiary-panel" style="display: none;" data-bind="visible: card().get('helpenabled')">
            <div class="tertiary-panel-content">
                <div class="">
                    <h4 class="title-block-title" style=""> {% trans "Card-Level Help" %} </h4>
                </div>

                <!-- Help CRUD -->
                <div class="pad-all">
                    <div class="node-widget-label" style="">
                        <div class="control-label">
                            {% trans "Help Panel Title" %}
                        </div>
                        <div class="col-sm-12 pad-no crud-widget-container">
                            <input type="" placeholder="{% trans "Help title" %}" class="form-control input-md widget-input" data-bind='value: card().get("helptitle")'>
                        </div>
                    </div>

                    <!--Rich text editor-->
                    <div class="node-widget-label" style="">
                        <div class="control-label">
                            {% trans "Help Content" %}
                        </div>
                        <textarea rows="10" cols="80" data-bind="ckeditor: card().get('helptext'), ckeditorOptions: {}, valueUpdate: 'afterkeydown'"></textarea>
                    </div>

                    <!-- Preview help -->
                    <div data-bind="component: { name: 'switch-widget', params: {value: helpPreviewActive, config:{label: '{% trans "Preview Help Panel" %}', subtitle: '{% trans "Display help panel, confirm content" %}'}}}"></div>
                    <div class="toggle-container">
                        <input id="preview-card-help" class="arches-switch" type="checkbox" data-switchery="true" style="display: none;">
                    </div>
                </div>
            </div>
        </div>

    </div>
</div>

{'fraction_non_alphanumeric': 0.18699186991869918, 'fraction_numerical': 0.0036815462494247586, 'mean_word_length': 2.0464953271028037, 'pattern_counts': {'":': 0, '<': 235, '<?xml version=': 0, '>': 235, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6004425', 'n_tokens_mistral': 3822, 'n_tokens_neox': 3594, 'n_words': 885}