<commit_before><!DOCTYPE html>
<!--
 .................................................................................................
:::BSDB'::BSDB'::BSDB':::::BSDB':::BSDBS'::BSDBS'::BSDB'::::BSD'::BSDBS'::BSDBS'::BSDB'::::::BSD'::
::BSDBSD BSDBSD :.BSDBS':BSDBS .:BSD ..BSD  ...BSD 'BSDBS':BSD .BSD ..BSD  ...BSD :BSDBS'::BSDB .::
::COPYRIGHT2017 ::.BS BSDB .BS :BSD .::.BSD :::.BSD :BS .BSDB .BSD .:::BSD ::::BSD :BS BSDB BS .:::
:::BSDSTYLEBSD .:::BS  BS .:BS :BSD ::::BSD ::::BSD :BS ::BSD :BSD :::::...::::BSD :BS :BS  BS ::::
::::.LICENSE .::::BSD .:..::BS 'BSD ::::BSD ::::BSD :BS :::BS :BSD ::BSDBS'::::BSD :BS ::..:BS ':::
:::::::BSD .::::BSDB .::::::BSD 'BSD'::BSD .:::BSD .BSD :::BSD':BSD'::.BSD :::BSD .BSD :::::BSDB'::
::::::::B .::::::BS .:::::::.BSD ::BSDBS .:BSDBS  :BSD .::::BSD :.BSDBS BS BSDB .:BSD .:::::.BS .::
`::::::::.::::::::..::::::::::...:::.....:::.....:::...::::::...:::.............:::...::::::::..::'
-->

<link rel="import" href="../bower_components/iron-selector/iron-selector.html">
<link rel="import" href="../bower_components/paper-icon-button/paper-icon-button.html">
<link rel="import" href="mg-clipboard.html">
<link rel="import" href="mg-item-editor.html">
<link rel="import" href="mg-common-styles.html">
<link rel="import" href="mg-item-image.html">
<link rel="import" href="mg-image-editor.html">

    <dom-module id="mg-gallery-editor">
  <template strip-whitespace>
<style include="mg-item-editor mg-common-styles iron-flex iron-flex-alignment">

.image-selector {
  @apply --layout-horizontal;
  @apply --layout-wrap;
  @apply --layout-flex;
  @apply --layout-start-aligned;
  padding: 0 0 24px 0;
  overflow-y: auto;
  border: 1px solid transparent;
  border-radius: 5px;
  margin: 0 20px 50px 0;
}

:host([idle]) .image-selector {
  border: 1px dashed var(--disabled-text-color);
  color: lightgray;
}

:host([dropenter]) .image-selector {
  border: 1px dashed tomato;
  color: tomato;
}

:host([nokey]) .image-selector {
  display: none;
}

#gallery-container {
}

.image-thumbnail {
  margin: 2px;
  width: 124px;
  height: 124px;
  --mg-image: {
    width: 120px;
    height: 120px;
  }
}

@media (max-width: 767px) {
  .image-selector {
    padding: 0;
  }

  #gallery-container {
    padding-bottom: 15px;
  }

}
</style>

<mg-clipboard clipboard="{{clipboard}}"></mg-clipboard>

<div id="gallery-container" ondrop="_onDrop" class="vertical layout">

    <app-toolbar>
  <div>
<paper-icon-button icon="booed:add-photo" on-click="_onAddButtonClick"></paper-icon-button>
<paper-tooltip>{{localize('add photo')}}</paper-tooltip>
  </div>

  <div>
<paper-icon-button disabled="[[!imageList.length]]" icon="[[copyIcon]]" on-click="_onCopyButtonClick"></paper-icon-button>
<paper-tooltip>{{localize(copyMethod)}}</paper-tooltip>
  </div>

  <div>
<paper-icon-button disabled="[[!clipboard.length]]" icon="content-paste" on-click="_onPasteButtonClick"></paper-icon-button>
<paper-tooltip>{{localize('paste')}}</paper-tooltip>
  </div>

  <div>
<paper-icon-button disabled="[[!clipboard.length]]" icon="booed:content-clear" on-click="_onClearButtonClick"></paper-icon-button>
<paper-tooltip>{{localize('clear clipboard')}}</paper-tooltip>
  </div>
<commit_msg>Should have hide gallery when no key.<commit_after><!DOCTYPE html>
<!--
 .................................................................................................
:::BSDB'::BSDB'::BSDB':::::BSDB':::BSDBS'::BSDBS'::BSDB'::::BSD'::BSDBS'::BSDBS'::BSDB'::::::BSD'::
::BSDBSD BSDBSD :.BSDBS':BSDBS .:BSD ..BSD  ...BSD 'BSDBS':BSD .BSD ..BSD  ...BSD :BSDBS'::BSDB .::
::COPYRIGHT2017 ::.BS BSDB .BS :BSD .::.BSD :::.BSD :BS .BSDB .BSD .:::BSD ::::BSD :BS BSDB BS .:::
:::BSDSTYLEBSD .:::BS  BS .:BS :BSD ::::BSD ::::BSD :BS ::BSD :BSD :::::...::::BSD :BS :BS  BS ::::
::::.LICENSE .::::BSD .:..::BS 'BSD ::::BSD ::::BSD :BS :::BS :BSD ::BSDBS'::::BSD :BS ::..:BS ':::
:::::::BSD .::::BSDB .::::::BSD 'BSD'::BSD .:::BSD .BSD :::BSD':BSD'::.BSD :::BSD .BSD :::::BSDB'::
::::::::B .::::::BS .:::::::.BSD ::BSDBS .:BSDBS  :BSD .::::BSD :.BSDBS BS BSDB .:BSD .:::::.BS .::
`::::::::.::::::::..::::::::::...:::.....:::.....:::...::::::...:::.............:::...::::::::..::'
-->

<link rel="import" href="../bower_components/iron-selector/iron-selector.html">
<link rel="import" href="../bower_components/paper-icon-button/paper-icon-button.html">
<link rel="import" href="mg-clipboard.html">
<link rel="import" href="mg-item-editor.html">
<link rel="import" href="mg-common-styles.html">
<link rel="import" href="mg-item-image.html">
<link rel="import" href="mg-image-editor.html">

    <dom-module id="mg-gallery-editor">
  <template strip-whitespace>
<style include="mg-item-editor mg-common-styles iron-flex iron-flex-alignment">

.image-selector {
  @apply --layout-horizontal;
  @apply --layout-wrap;
  @apply --layout-flex;
  @apply --layout-start-aligned;
  padding: 0 0 24px 0;
  overflow-y: auto;
  border: 1px solid transparent;
  border-radius: 5px;
  margin: 0 20px 50px 0;
}

:host([idle]) .image-selector {
  border: 1px dashed var(--disabled-text-color);
  color: lightgray;
}

:host([dropenter]) .image-selector {
  border: 1px dashed tomato;
  color: tomato;
}

:host([nokey]) .image-selector {
  display: none;
}

#gallery-container {
}

.image-thumbnail {
  margin: 2px;
  width: 124px;
  height: 124px;
  --mg-image: {
    width: 120px;
    height: 120px;
  }
}

@media (max-width: 767px) {
  .image-selector {
    padding: 0;
  }

  #gallery-container {
    padding-bottom: 15px;
  }

}
</style>

<mg-clipboard clipboard="{{clipboard}}"></mg-clipboard>

<div id="gallery-container" ondrop="_onDrop" class="vertical layout">

    <app-toolbar hidden$="[[nokey]]">
  <div>
<paper-icon-button icon="booed:add-photo" on-click="_onAddButtonClick"></paper-icon-button>
<paper-tooltip>{{localize('add photo')}}</paper-tooltip>
  </div>

  <div>
<paper-icon-button disabled="[[!imageList.length]]" icon="[[copyIcon]]" on-click="_onCopyButtonClick"></paper-icon-button>
<paper-tooltip>{{localize(copyMethod)}}</paper-tooltip>
  </div>

  <div>
<paper-icon-button disabled="[[!clipboard.length]]" icon="content-paste" on-click="_onPasteButtonClick"></paper-icon-button>
<paper-tooltip>{{localize('paste')}}</paper-tooltip>
  </div>

  <div>
<paper-icon-button disabled="[[!clipboard.length]]" icon="booed:content-clear" on-click="_onClearButtonClick"></paper-icon-button>
<paper-tooltip>{{localize('clear clipboard')}}</paper-tooltip>
  </div>

{'fraction_non_alphanumeric': 0.29458204334365323, 'fraction_numerical': 0.011764705882352941, 'mean_word_length': 3.7264081931236284, 'pattern_counts': {'":': 0, '<': 85, '<?xml version=': 0, '>': 85, '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': '6064928', 'n_tokens_mistral': 2620, 'n_tokens_neox': 2337, 'n_words': 435}