<commit_before><template lang="pug">
  .settings(:class="{open: open}")
    .settings-header
      .settings-toggle.settings-state-indicator(@mousedown="toggle()", :class="state.changes")
        svg.i(xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16")
          path(fill="context-fill" d="M15 7h-2.1a4.967 4.967 0 0 0-.732-1.753l1.49-1.49a1 1 0 0 0-1.414-1.414l-1.49 1.49A4.968 4.968 0 0 0 9 3.1V1a1 1 0 0 0-2 0v2.1a4.968 4.968 0 0 0-1.753.732l-1.49-1.49a1 1 0 0 0-1.414 1.415l1.49 1.49A4.967 4.967 0 0 0 3.1 7H1a1 1 0 0 0 0 2h2.1a4.968 4.968 0 0 0 .737 1.763c-.014.013-.032.017-.045.03l-1.45 1.45a1 1 0 1 0 1.414 1.414l1.45-1.45c.013-.013.018-.031.03-.045A4.968 4.968 0 0 0 7 12.9V15a1 1 0 0 0 2 0v-2.1a4.968 4.968 0 0 0 1.753-.732l1.49 1.49a1 1 0 0 0 1.414-1.414l-1.49-1.49A4.967 4.967 0 0 0 12.9 9H15a1 1 0 0 0 0-2zM5 8a3 3 0 1 1 3 3 3 3 0 0 1-3-3z")
      h2.title
        img.favicon.icon(src="fav-1.png")
        span Red Panda Launcher
      .tabs
        .tab(@click='tab = "general"', :class='{active: tab == "general"}') General
        .tab(@click='tab = "engines"', :class='{active: tab == "engines"}') Search engines
        .tab(@click='tab = "advanced"', :class='{active: tab == "advanced"}') Advanced
    .settings-content(v-if="editor")
      .tab-content(v-show='tab == "general"')
        label.control
          .control-input: input(type='checkbox' v-model="settings.sync")
          .control-label Sync settings between devices
        label.control
          .control-input: input(type='checkbox' v-model="settings.focusHack")
          .control-label Focus hack

        HomePageSettings(:settings="settings.home")
      SearchEngineSettings.tab-content(:show='tab == "engines"' v-if="loadSearch", :editor="editor")
      <!--SearchTransformSettings.tab-content(v-show='tab == "advanced"' v-if="loadSearch", :settings="settings.search.transforms")-->
      message.settings-message(:action="state.lastAction")

</template>
<script>

import EngineSettingsEditor from './EngineEditor'
import SearchTransformSettings from './settings.transforms.vue'
import SearchEngineSettings from './settings.engines.vue'<commit_msg>remove settings editor when not active<commit_after><template lang="pug">
  .settings(:class="{open: open}")
    .settings-header
      .settings-toggle.settings-state-indicator(@mousedown="toggle()", :class="state.changes")
        svg.i(xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16")
          path(fill="context-fill" d="M15 7h-2.1a4.967 4.967 0 0 0-.732-1.753l1.49-1.49a1 1 0 0 0-1.414-1.414l-1.49 1.49A4.968 4.968 0 0 0 9 3.1V1a1 1 0 0 0-2 0v2.1a4.968 4.968 0 0 0-1.753.732l-1.49-1.49a1 1 0 0 0-1.414 1.415l1.49 1.49A4.967 4.967 0 0 0 3.1 7H1a1 1 0 0 0 0 2h2.1a4.968 4.968 0 0 0 .737 1.763c-.014.013-.032.017-.045.03l-1.45 1.45a1 1 0 1 0 1.414 1.414l1.45-1.45c.013-.013.018-.031.03-.045A4.968 4.968 0 0 0 7 12.9V15a1 1 0 0 0 2 0v-2.1a4.968 4.968 0 0 0 1.753-.732l1.49 1.49a1 1 0 0 0 1.414-1.414l-1.49-1.49A4.967 4.967 0 0 0 12.9 9H15a1 1 0 0 0 0-2zM5 8a3 3 0 1 1 3 3 3 3 0 0 1-3-3z")
      h2.title
        img.favicon.icon(src="fav-1.png")
        span Red Panda Launcher
      .tabs
        .tab(@click='tab = "general"', :class='{active: tab == "general"}') General
        .tab(@click='tab = "engines"', :class='{active: tab == "engines"}') Search engines
        .tab(@click='tab = "advanced"', :class='{active: tab == "advanced"}') Advanced
    .settings-content(v-if="editor && open")
      .tab-content(v-show='tab == "general"')
        label.control
          .control-input: input(type='checkbox' v-model="settings.sync")
          .control-label Sync settings between devices
        label.control
          .control-input: input(type='checkbox' v-model="settings.focusHack")
          .control-label Focus hack

        HomePageSettings(:settings="settings.home")
      SearchEngineSettings.tab-content(:show='tab == "engines"' v-if="loadSearch", :editor="editor")
      <!--SearchTransformSettings.tab-content(v-show='tab == "advanced"' v-if="loadSearch", :settings="settings.search.transforms")-->
      message.settings-message(:action="state.lastAction")

</template>
<script>

import EngineSettingsEditor from './EngineEditor'
import SearchTransformSettings from './settings.transforms.vue'
import SearchEngineSettings from './settings.engines.vue'
{'fraction_non_alphanumeric': 0.17471689392188583, 'fraction_numerical': 0.15622833371851166, 'mean_word_length': 2.9779411764705883, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4007298', 'n_tokens_mistral': 2082, 'n_tokens_neox': 1647, 'n_words': 375}