Folders – Unlimited Folders to Organize Media Library Folder, Pages, Posts, File Manager - Version 2.3.2

Version Description

You can customize the folders look and feel now: change colors, font, and size of folders. We've also added some features to improve the easy-of-use like Enter key to create a new folder and more.

Download this release

Release Info

Developer galdub
Plugin Icon wp plugin Folders – Unlimited Folders to Organize Media Library Folder, Pages, Posts, File Manager
Version 2.3.2
Comparing to
See all releases

Code changes from version 2.3.1 to 2.3.2

assets/css/design.css CHANGED
@@ -76,6 +76,7 @@
76
 
77
  .wcp-container .first-space {
78
  margin-left: 10px;
 
79
  }
80
 
81
  i.fa-caret-right {
@@ -290,11 +291,21 @@ body.no-hover-css .wcp-container .route .title:hover {
290
  -webkit-box-shadow: 0 3px 5px -3px #333333;
291
  -moz-box-shadow: 0 3px 5px -3px #333333;
292
  box-shadow: 0 3px 5px -3px #333333;
 
293
  }
294
  .add-new-folder:hover, .add-new-folder:focus {
295
- background: #bc0f50;
296
  color: #ffffff;
297
- border: solid 1px #bc0f50
 
 
 
 
 
 
 
 
 
298
  }
299
  .add-new-folder span {
300
  display: block;
@@ -309,7 +320,7 @@ body.no-hover-css .wcp-container .route .title:hover {
309
  .form-options {
310
  background: #fff;
311
  padding: 10px 10px 0 10px;
312
- margin: 10px 0 0px;
313
  }
314
  .form-options ul {
315
  margin: 0;
@@ -333,7 +344,7 @@ body.no-hover-css .wcp-container .route .title:hover {
333
  vertical-align: middle;
334
  border: solid 1px #ccc;
335
  border-radius: 3px;
336
- margin: 0 0 10px 0;
337
  }
338
  .form-options li.last a {
339
  padding: 3px;
@@ -496,7 +507,7 @@ display: inline;
496
  .form-loader {
497
  width: 100%;
498
  height: 5px;
499
- margin: 0 0 20px;
500
  }
501
  .form-loader-count {
502
  width: 0;
@@ -899,11 +910,22 @@ button.button.organize-button {
899
  -webkit-box-shadow: 0 3px 5px -3px #333333;
900
  -moz-box-shadow: 0 3px 5px -3px #333333;
901
  box-shadow: 0 3px 5px -3px #333333;
 
902
  }
903
  button.button.organize-button:hover, button.button.organize-button:focus {
904
- background: #bc0f50;
905
  color: #ffffff;
906
- border: solid 1px #bc0f50;
 
 
 
 
 
 
 
 
 
 
907
  }
908
  .tree-structure-content ul {
909
  margin: 0;
@@ -1002,7 +1024,7 @@ span.media-info-message.active {
1002
  -moz-border-radius: 10px;
1003
  border-radius: 10px;
1004
  }
1005
- .folder-form-buttons a {
1006
  display: inline-block;
1007
  padding: 10px 20px;
1008
  text-decoration: none;
@@ -1011,11 +1033,83 @@ span.media-info-message.active {
1011
  line-height: 22px;
1012
  border-radius: .25em;
1013
  color: #ffffff;
 
1014
  }
1015
- .folder-form-buttons a span {
1016
  -webkit-animation: fa-spin 0.75s infinite linear;
1017
  animation: fa-spin 0.75s infinite linear;
1018
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1019
  @-webkit-keyframes fa-spin {
1020
  0% {
1021
  -webkit-transform: rotate(0deg);
@@ -1026,7 +1120,7 @@ span.media-info-message.active {
1026
  transform: rotate(359deg);
1027
  }
1028
  }
1029
- .folder-form-buttons a:hover, .folder-form-buttons a:focus {
1030
  color: #ffffff;
1031
  background-image: linear-gradient(rgba(0,0,0,.1),rgba(0,0,0,.1));
1032
  }
76
 
77
  .wcp-container .first-space {
78
  margin-left: 10px;
79
+ top: 10px;
80
  }
81
 
82
  i.fa-caret-right {
291
  -webkit-box-shadow: 0 3px 5px -3px #333333;
292
  -moz-box-shadow: 0 3px 5px -3px #333333;
293
  box-shadow: 0 3px 5px -3px #333333;
294
+ position: relative;
295
  }
296
  .add-new-folder:hover, .add-new-folder:focus {
297
+ /*background: #bc0f50;*/
298
  color: #ffffff;
299
+ /*border: solid 1px #bc0f50;*/
300
+ }
301
+ .add-new-folder:hover:after {
302
+ content: "";
303
+ width: 100%;
304
+ height: 100%;
305
+ background: rgba(0,0,0,0.10);
306
+ position: absolute;
307
+ top: 0;
308
+ left: 0;
309
  }
310
  .add-new-folder span {
311
  display: block;
320
  .form-options {
321
  background: #fff;
322
  padding: 10px 10px 0 10px;
323
+ margin: 0 0px;
324
  }
325
  .form-options ul {
326
  margin: 0;
344
  vertical-align: middle;
345
  border: solid 1px #ccc;
346
  border-radius: 3px;
347
+ margin: 0 0 12px 0;
348
  }
349
  .form-options li.last a {
350
  padding: 3px;
507
  .form-loader {
508
  width: 100%;
509
  height: 5px;
510
+ margin: 0 0 10px;
511
  }
512
  .form-loader-count {
513
  width: 0;
910
  -webkit-box-shadow: 0 3px 5px -3px #333333;
911
  -moz-box-shadow: 0 3px 5px -3px #333333;
912
  box-shadow: 0 3px 5px -3px #333333;
913
+ position: relative;
914
  }
915
  button.button.organize-button:hover, button.button.organize-button:focus {
916
+ /*background: #bc0f50;*/
917
  color: #ffffff;
918
+ /*border: solid 1px #bc0f50;*/
919
+ }
920
+
921
+ button.button.organize-button:hover:after {
922
+ content: "";
923
+ width: 100%;
924
+ height: 100%;
925
+ background: rgba(0,0,0,0.10);
926
+ position: absolute;
927
+ top: 0;
928
+ left: 0;
929
  }
930
  .tree-structure-content ul {
931
  margin: 0;
1024
  -moz-border-radius: 10px;
1025
  border-radius: 10px;
1026
  }
1027
+ .folder-form-buttons a, .folder-form-buttons button {
1028
  display: inline-block;
1029
  padding: 10px 20px;
1030
  text-decoration: none;
1033
  line-height: 22px;
1034
  border-radius: .25em;
1035
  color: #ffffff;
1036
+ border: none;
1037
  }
1038
+ .folder-form-buttons a span, .folder-form-buttons button span {
1039
  -webkit-animation: fa-spin 0.75s infinite linear;
1040
  animation: fa-spin 0.75s infinite linear;
1041
  }
1042
+
1043
+ [data-tooltip] {
1044
+ position: relative; /* opinion 1 */
1045
+ }
1046
+
1047
+ /* Applies to all tooltips */
1048
+ [data-tooltip]::before,
1049
+ [data-tooltip]::after {
1050
+ text-transform: none; /* opinion 2 */
1051
+ font-size: .9em; /* opinion 3 */
1052
+ line-height: 1;
1053
+ user-select: none;
1054
+ pointer-events: none;
1055
+ position: absolute;
1056
+ display: none;
1057
+ opacity: 0;
1058
+ }
1059
+ [data-tooltip]::before {
1060
+ content: '';
1061
+ border: 5px solid transparent; /* opinion 4 */
1062
+ z-index: 1001; /* absurdity 1 */
1063
+ }
1064
+ [data-tooltip]::after {
1065
+ content: attr(data-tooltip); /* magic! */
1066
+
1067
+ /* most of the rest of this is opinion */
1068
+ font-family: Helvetica, sans-serif;
1069
+ text-align: center;
1070
+
1071
+ /*
1072
+ Let the content set the size of the tooltips
1073
+ but this will also keep them from being obnoxious
1074
+ */
1075
+ min-width: 3em;
1076
+ max-width: 21em;
1077
+ white-space: nowrap;
1078
+ overflow: hidden;
1079
+ text-overflow: ellipsis;
1080
+ padding: 1ch 1.5ch;
1081
+ border-radius: .3ch;
1082
+ box-shadow: 0 1em 2em -.5em rgba(0, 0, 0, 0.35);
1083
+ background: #333;
1084
+ color: #fff;
1085
+ z-index: 1000; /* absurdity 2 */
1086
+ }
1087
+
1088
+ /* Make the tooltips respond to hover */
1089
+ [data-tooltip]:hover::before,
1090
+ [data-tooltip]:hover::after {
1091
+ display: block;
1092
+ opacity: 1;
1093
+ }
1094
+ /* FLOW: UP */
1095
+ [data-tooltip]:not([flow])::before,
1096
+ [data-tooltip][flow^="up"]::before {
1097
+ bottom: 100%;
1098
+ border-bottom-width: 0;
1099
+ border-top-color: #333;
1100
+ }
1101
+ [data-tooltip]:not([flow])::after,
1102
+ [data-tooltip][flow^="up"]::after {
1103
+ bottom: calc(100% + 5px);
1104
+ }
1105
+ [data-tooltip]:not([flow])::before,
1106
+ [data-tooltip]:not([flow])::after,
1107
+ [data-tooltip][flow^="up"]::before,
1108
+ [data-tooltip][flow^="up"]::after {
1109
+ left: 50%;
1110
+ transform: translate(-50%, -.5em);
1111
+ }
1112
+
1113
  @-webkit-keyframes fa-spin {
1114
  0% {
1115
  -webkit-transform: rotate(0deg);
1120
  transform: rotate(359deg);
1121
  }
1122
  }
1123
+ .folder-form-buttons a:hover, .folder-form-buttons a:focus, .folder-form-buttons button:hover, .folder-form-buttons button:focus {
1124
  color: #ffffff;
1125
  background-image: linear-gradient(rgba(0,0,0,.1),rgba(0,0,0,.1));
1126
  }
assets/css/media.css CHANGED
@@ -15,6 +15,5 @@
15
  color: #000000;
16
  }
17
  #media-attachment-taxonomy-filter option:first-child {
18
- color: #FF5983;
19
  font-weight: bold;
20
  }
15
  color: #000000;
16
  }
17
  #media-attachment-taxonomy-filter option:first-child {
 
18
  font-weight: bold;
19
  }
assets/css/settings.css ADDED
@@ -0,0 +1,277 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ span.upgrade-message {
2
+ padding: 5px 10px;
3
+ background: #fff;
4
+ display: inline-block;
5
+ font-size: 14px;
6
+ color: #000;
7
+ }
8
+ a.pink, span.pink {
9
+ color: #FF5983;
10
+ text-decoration: none;
11
+ font-weight: bold;
12
+ }
13
+ /*#setting-form {
14
+ float: left;
15
+ width: 600px;
16
+ }*/
17
+ .form-table {
18
+ margin: 0;
19
+ }
20
+ .form-table th {
21
+ width: 220px;
22
+ }
23
+ .form-table th.default-folder {
24
+ width: 100px;
25
+ }
26
+ .premio-help {
27
+ text-align: center;
28
+ }
29
+ .premio-help a {
30
+ display: inline-block;
31
+ width: 200px;
32
+ margin-top: 15px;
33
+ }
34
+ .premio-help a img {
35
+ width: 100%;
36
+ height: auto;
37
+ }
38
+ .hide-option {
39
+ display: none;
40
+ }
41
+ .accordion {
42
+ border: solid 1px #cccccc;
43
+ border-radius: 10px;
44
+ margin: 0 0 10px 0;
45
+ max-width: 1024px;
46
+ }
47
+ .accordion-header {
48
+ background: #c0c0c0;
49
+ color: #000000;
50
+ padding: 10px 15px;
51
+ font-size: 15px;
52
+ cursor: pointer;
53
+ border-radius: 10px;
54
+ }
55
+ .accordion-header.active {
56
+ border-radius: 0px;
57
+ -webkit-border-top-left-radius: 10px;
58
+ -webkit-border-top-right-radius: 10px;
59
+ -moz-border-radius-topleft: 10px;
60
+ -moz-border-radius-topright: 10px;
61
+ border-top-left-radius: 10px;
62
+ border-top-right-radius: 10px;
63
+ }
64
+ .accordion-header.active span {
65
+ transform: rotate(180deg);
66
+ }
67
+ select.hide-show-option {
68
+ width: 170px;
69
+ }
70
+ .accordion-content {
71
+ background: #f5f5f5;
72
+ padding: 15px;
73
+ -webkit-border-bottom-right-radius: 10px;
74
+ -webkit-border-bottom-left-radius: 10px;
75
+ -moz-border-radius-bottomright: 10px;
76
+ -moz-border-radius-bottomleft: 10px;
77
+ border-bottom-right-radius: 10px;
78
+ border-bottom-left-radius: 10px;
79
+ display: none;
80
+ }
81
+ .sp-replacer.sp-light {
82
+ padding: 0 !important;
83
+ margin: 0 !important;
84
+ border: none !important;
85
+ }
86
+ .sp-dd {
87
+ display: none !important;
88
+ }
89
+ .sp-preview {
90
+ width: 32px !important;
91
+ height: 32px !important;
92
+ margin: 0 !important;
93
+ padding: 0 !important;
94
+ border: none !important;
95
+ background: #fff !important;
96
+ }
97
+ .form-table select {
98
+ width: 180px
99
+ }
100
+ .accordion-header span {
101
+ float: right;
102
+ }
103
+ .form-title {
104
+ font-size: 23px;
105
+ font-weight: 400;
106
+ margin: 0;
107
+ padding: 0 0 10px 0;
108
+ line-height: 29px;
109
+ min-height: 36px;
110
+ }
111
+ .add-new-folder, button.organize-button {
112
+ text-decoration: none;
113
+ display: block;
114
+ float: right;
115
+ font-size: 14px;
116
+ padding: 4px 10px;
117
+ background: #F51366;
118
+ color: #fff;
119
+ border: solid 1px #F51366;
120
+ border-radius: 3px;
121
+ line-height: 24px;
122
+ -webkit-box-shadow: 0 3px 5px -3px #333333;
123
+ -moz-box-shadow: 0 3px 5px -3px #333333;
124
+ box-shadow: 0 3px 5px -3px #333333;
125
+ position: relative;
126
+ }
127
+ .add-new-folder span {
128
+ display: block;
129
+ float: left;
130
+ line-height: 20px;
131
+ font-size: 14px;
132
+ margin-right: 5px;
133
+ }
134
+ .add-new-folder span.folder-icon-create_new_folder {
135
+ font-size: 20px;
136
+ }
137
+ .form-options {
138
+ background: #fff;
139
+ padding: 10px 10px 0 10px;
140
+ margin: 0 0px;
141
+ }
142
+ .form-options ul {
143
+ margin: 0;
144
+ padding: 0;
145
+ }
146
+ .form-options li {
147
+ display: inline-block;
148
+ margin: 0 5px 0 0;
149
+ vertical-align: top;
150
+ }
151
+ .form-options li a {
152
+ display: inline-block;
153
+ text-decoration: none;
154
+ padding: 5px 12px;
155
+ color: #000;
156
+ background: #ccc;
157
+ box-shadow: 0 1px 0 #ccc;
158
+ vertical-align: middle;
159
+ border: solid 1px #ccc;
160
+ border-radius: 3px;
161
+ margin: 0 0 10px 0;
162
+ }
163
+ .form-options span.icon {
164
+ font-size: 18px;
165
+ display: inline-block;
166
+ vertical-align: top;
167
+ }
168
+ .form-options li.last {
169
+ margin: 0;
170
+ }
171
+ .form-options li.last a {
172
+ padding: 3px;
173
+ }
174
+ .form-options li.last a span.icon {
175
+ font-size: 28px;
176
+ line-height: 22px;
177
+ }
178
+ .header-posts a, .un-categorised-items a {
179
+ color: #444444;
180
+ padding: 7px;
181
+ border-radius: 3px;
182
+ display: block;
183
+ text-decoration: none;
184
+ font-size: 14px;
185
+ line-height: 18px;
186
+ }
187
+ .header-posts a.active-item, .un-categorised-items.active-item {
188
+ background: #008ec2;
189
+ color: #fff;
190
+ }
191
+ span.total-count {
192
+ float: right;
193
+ background: #fff;
194
+ padding: 0 5px;
195
+ border: solid 1px #cccccc;
196
+ font-size: 10px;
197
+ line-height: 16px;
198
+ border-radius: 2px;
199
+ }
200
+ .un-categorised-items.active-item a span, .header-posts a.active-item span.total-count {
201
+ color: #444444 !important;
202
+ }
203
+ .media-buttons {
204
+ margin: 10px 0 0 0;
205
+ padding: 10px;
206
+ background: #fff;
207
+ text-align: center;
208
+ }
209
+ .media-buttons select, .media-buttons button {
210
+ width: 48%;
211
+ display: inline-block;
212
+ margin: 0 2% 0 0;
213
+ }
214
+ .header-posts {
215
+ margin: 10px 0 0 0;
216
+ }
217
+ .add-new-folder:hover, .add-new-folder:focus, .organize-button:hover, .organize-button:focus {
218
+ color: #ffffff;
219
+ }
220
+ .add-new-folder:hover:after, .organize-button:hover:after {
221
+ content: "";
222
+ width: 100%;
223
+ height: 100%;
224
+ background: rgba(0,0,0,0.10);
225
+ position: absolute;
226
+ top: 0;
227
+ left: 0;
228
+ }
229
+ .folder-list li a {
230
+ color: #333;
231
+ text-decoration: none;
232
+ margin: 0 0 1px 0;
233
+ border-radius: 3px;
234
+ font-size: 20px;
235
+ display: block;
236
+ line-height: 18px;
237
+ }
238
+ .folder-list li a i {
239
+ display: inline-block;
240
+ vertical-align: middle;
241
+ }
242
+ .folder-list li a span {
243
+ font-size: 16px;
244
+ display: inline-block;
245
+ vertical-align: middle;
246
+ }
247
+ .preview-inner-box {
248
+ background: #e4e4e4;
249
+ padding: 15px;
250
+ width: 300px;
251
+ float: right;
252
+ }
253
+ .accordion-left {
254
+ width: 600px;
255
+ float: left;
256
+ }
257
+ .accordion-right {
258
+ width: calc(100% - 620px);
259
+ float: right;
260
+ }
261
+ .preview-text {
262
+ font-size: 20px;
263
+ padding: 0px 0 10px;
264
+ width: 330px;
265
+ float: right;
266
+ }
267
+ .preview-text-info {
268
+ padding: 10px 0 0;
269
+ font-size: 12px;
270
+ line-height: 12px;
271
+ }
272
+ .media-select option {
273
+ color: #000000;
274
+ }
275
+ .media-select option:first-child {
276
+ font-weight: bold;
277
+ }
assets/css/spectrum.min.css ADDED
@@ -0,0 +1 @@
 
1
+ .sp-container{position:absolute;top:0;left:0;display:inline-block;*display:inline;*zoom:1;z-index:9999994;overflow:hidden}.sp-container.sp-flat{position:relative}.sp-container,.sp-container *{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.sp-top{position:relative;width:100%;display:inline-block}.sp-top-inner{position:absolute;top:0;left:0;bottom:0;right:0}.sp-color{position:absolute;top:0;left:0;bottom:0;right:20%}.sp-hue{position:absolute;top:0;right:0;bottom:0;left:84%;height:100%}.sp-clear-enabled .sp-hue{top:33px;height:77.5%}.sp-fill{padding-top:80%}.sp-sat,.sp-val{position:absolute;top:0;left:0;right:0;bottom:0}.sp-alpha-enabled .sp-top{margin-bottom:18px}.sp-alpha-enabled .sp-alpha{display:block}.sp-alpha-handle{position:absolute;top:-4px;bottom:-4px;width:6px;left:50%;cursor:pointer;border:1px solid black;background:white;opacity:.8}.sp-alpha{display:none;position:absolute;bottom:-14px;right:0;left:0;height:8px}.sp-alpha-inner{border:solid 1px #333}.sp-clear{display:none}.sp-clear.sp-clear-display{background-position:center}.sp-clear-enabled .sp-clear{display:block;position:absolute;top:0;right:0;bottom:0;left:84%;height:28px}.sp-container,.sp-replacer,.sp-preview,.sp-dragger,.sp-slider,.sp-alpha,.sp-clear,.sp-alpha-handle,.sp-container.sp-dragging .sp-input,.sp-container button{-webkit-user-select:none;-moz-user-select:-moz-none;-o-user-select:none;user-select:none}.sp-container.sp-input-disabled .sp-input-container{display:none}.sp-container.sp-buttons-disabled .sp-button-container{display:none}.sp-container.sp-palette-buttons-disabled .sp-palette-button-container{display:none}.sp-palette-only .sp-picker-container{display:none}.sp-palette-disabled .sp-palette-container{display:none}.sp-initial-disabled .sp-initial{display:none}.sp-sat{background-image:-webkit-gradient(linear,0 0,100% 0,from(#FFF),to(rgba(204,154,129,0)));background-image:-webkit-linear-gradient(left,#FFF,rgba(204,154,129,0));background-image:-moz-linear-gradient(left,#fff,rgba(204,154,129,0));background-image:-o-linear-gradient(left,#fff,rgba(204,154,129,0));background-image:-ms-linear-gradient(left,#fff,rgba(204,154,129,0));background-image:linear-gradient(to right,#fff,rgba(204,154,129,0));-ms-filter:"progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr=#FFFFFFFF, endColorstr=#00CC9A81)";filter:progid:DXImageTransform.Microsoft.gradient(GradientType = 1,startColorstr='#FFFFFFFF',endColorstr='#00CC9A81')}.sp-val{background-image:-webkit-gradient(linear,0 100%,0 0,from(#000),to(rgba(204,154,129,0)));background-image:-webkit-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:-moz-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:-o-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:-ms-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:linear-gradient(to top,#000,rgba(204,154,129,0));-ms-filter:"progid:DXImageTransform.Microsoft.gradient(startColorstr=#00CC9A81, endColorstr=#FF000000)";filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00CC9A81',endColorstr='#FF000000')}.sp-hue{background:-moz-linear-gradient(top,#f00 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,#f00 100%);background:-ms-linear-gradient(top,#f00 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,#f00 100%);background:-o-linear-gradient(top,#f00 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,#f00 100%);background:-webkit-gradient(linear,left top,left bottom,from(#f00),color-stop(0.17,#ff0),color-stop(0.33,#0f0),color-stop(0.5,#0ff),color-stop(0.67,#00f),color-stop(0.83,#f0f),to(#f00));background:-webkit-linear-gradient(top,#f00 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,#f00 100%);background:linear-gradient(to bottom,#f00 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,#f00 100%)}.sp-1{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0000',endColorstr='#ffff00')}.sp-2{height:16%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffff00',endColorstr='#00ff00')}.sp-3{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ff00',endColorstr='#00ffff')}.sp-4{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ffff',endColorstr='#0000ff')}.sp-5{height:16%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#0000ff',endColorstr='#ff00ff')}.sp-6{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff00ff',endColorstr='#ff0000')}.sp-hidden{display:none !important}.sp-cf:before,.sp-cf:after{content:"";display:table}.sp-cf:after{clear:both}.sp-cf{*zoom:1}@media(max-device-width:480px){.sp-color{right:40%}.sp-hue{left:63%}.sp-fill{padding-top:60%}}.sp-dragger{border-radius:5px;height:5px;width:5px;border:1px solid #fff;background:#000;cursor:pointer;position:absolute;top:0;left:0}.sp-slider{position:absolute;top:0;cursor:pointer;height:3px;left:-1px;right:-1px;border:1px solid #000;background:white;opacity:.8}.sp-container{border-radius:0;background-color:#ececec;border:solid 1px #f0c49b;padding:0}.sp-container,.sp-container button,.sp-container input,.sp-color,.sp-hue,.sp-clear{font:normal 12px "Lucida Grande","Lucida Sans Unicode","Lucida Sans",Geneva,Verdana,sans-serif;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;-ms-box-sizing:border-box;box-sizing:border-box}.sp-top{margin-bottom:3px}.sp-color,.sp-hue,.sp-clear{border:solid 1px #666}.sp-input-container{float:right;width:100px;margin-bottom:4px}.sp-initial-disabled .sp-input-container{width:100%}.sp-input{font-size:12px !important;border:1px inset;padding:4px 5px;margin:0;width:100%;background:transparent;border-radius:3px;color:#222}.sp-input:focus{border:1px solid orange}.sp-input.sp-validation-error{border:1px solid red;background:#fdd}.sp-picker-container,.sp-palette-container{float:left;position:relative;padding:10px;padding-bottom:300px;margin-bottom:-290px}.sp-picker-container{width:172px;border-left:solid 1px #fff}.sp-palette-container{border-right:solid 1px #ccc}.sp-palette-only .sp-palette-container{border:0}.sp-palette .sp-thumb-el{display:block;position:relative;float:left;width:24px;height:15px;margin:3px;cursor:pointer;border:solid 2px transparent}.sp-palette .sp-thumb-el:hover,.sp-palette .sp-thumb-el.sp-thumb-active{border-color:orange}.sp-thumb-el{position:relative}.sp-initial{float:left;border:solid 1px #333}.sp-initial span{width:30px;height:25px;border:0;display:block;float:left;margin:0}.sp-initial .sp-clear-display{background-position:center}.sp-palette-button-container,.sp-button-container{float:right}.sp-replacer{margin:0;overflow:hidden;cursor:pointer;padding:4px;display:inline-block;*zoom:1;*display:inline;border:solid 1px #91765d;background:#eee;color:#333;vertical-align:middle}.sp-replacer:hover,.sp-replacer.sp-active{border-color:#f0c49b;color:#111}.sp-replacer.sp-disabled{cursor:default;border-color:silver;color:silver}.sp-dd{padding:2px 0;height:16px;line-height:16px;float:left;font-size:10px}.sp-preview{position:relative;width:25px;height:20px;border:solid 1px #222;margin-right:5px;float:left;z-index:0}.sp-palette{*width:220px;max-width:220px}.sp-palette .sp-thumb-el{width:16px;height:16px;margin:2px 1px;border:solid 1px #d0d0d0}.sp-container{padding-bottom:0}.sp-container button{background-color:#eee;background-image:-webkit-linear-gradient(top,#eee,#ccc);background-image:-moz-linear-gradient(top,#eee,#ccc);background-image:-ms-linear-gradient(top,#eee,#ccc);background-image:-o-linear-gradient(top,#eee,#ccc);background-image:linear-gradient(to bottom,#eee,#ccc);border:1px solid #ccc;border-bottom:1px solid #bbb;border-radius:3px;color:#333;font-size:14px;line-height:1;padding:5px 4px;text-align:center;text-shadow:0 1px 0 #eee;vertical-align:middle}.sp-container button:hover{background-color:#ddd;background-image:-webkit-linear-gradient(top,#ddd,#bbb);background-image:-moz-linear-gradient(top,#ddd,#bbb);background-image:-ms-linear-gradient(top,#ddd,#bbb);background-image:-o-linear-gradient(top,#ddd,#bbb);background-image:linear-gradient(to bottom,#ddd,#bbb);border:1px solid #bbb;border-bottom:1px solid #999;cursor:pointer;text-shadow:0 1px 0 #ddd}.sp-container button:active{border:1px solid #aaa;border-bottom:1px solid #888;-webkit-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee;-moz-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee;-ms-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee;-o-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee;box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee}.sp-cancel{font-size:11px;color:#d93f3f !important;margin:0;padding:2px;margin-right:5px;vertical-align:middle;text-decoration:none}.sp-cancel:hover{color:#d93f3f !important;text-decoration:underline}.sp-palette span:hover,.sp-palette span.sp-thumb-active{border-color:#000}.sp-preview,.sp-alpha,.sp-thumb-el{position:relative;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==)}.sp-preview-inner,.sp-alpha-inner,.sp-thumb-inner{display:block;position:absolute;top:0;left:0;bottom:0;right:0}.sp-palette .sp-thumb-inner{background-position:50% 50%;background-repeat:no-repeat}.sp-palette .sp-thumb-light.sp-thumb-active .sp-thumb-inner{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAIVJREFUeNpiYBhsgJFMffxAXABlN5JruT4Q3wfi/0DsT64h8UD8HmpIPCWG/KemIfOJCUB+Aoacx6EGBZyHBqI+WsDCwuQ9mhxeg2A210Ntfo8klk9sOMijaURm7yc1UP2RNCMbKE9ODK1HM6iegYLkfx8pligC9lCD7KmRof0ZhjQACDAAceovrtpVBRkAAAAASUVORK5CYII=)}.sp-palette .sp-thumb-dark.sp-thumb-active .sp-thumb-inner{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAadEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjEwMPRyoQAAAMdJREFUOE+tkgsNwzAMRMugEAahEAahEAZhEAqlEAZhEAohEAYh81X2dIm8fKpEspLGvudPOsUYpxE2BIJCroJmEW9qJ+MKaBFhEMNabSy9oIcIPwrB+afvAUFoK4H0tMaQ3XtlrggDhOVVMuT4E5MMG0FBbCEYzjYT7OxLEvIHQLY2zWwQ3D+9luyOQTfKDiFD3iUIfPk8VqrKjgAiSfGFPecrg6HN6m/iBcwiDAo7WiBeawa+Kwh7tZoSCGLMqwlSAzVDhoK+6vH4G0P5wdkAAAAASUVORK5CYII=)}.sp-clear-display{background-repeat:no-repeat;background-position:center;background-image:url(data:image/gif;base64,R0lGODlhFAAUAPcAAAAAAJmZmZ2dnZ6enqKioqOjo6SkpKWlpaampqenp6ioqKmpqaqqqqurq/Hx8fLy8vT09PX19ff39/j4+Pn5+fr6+vv7+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAP8ALAAAAAAUABQAAAihAP9FoPCvoMGDBy08+EdhQAIJCCMybCDAAYUEARBAlFiQQoMABQhKUJBxY0SPICEYHBnggEmDKAuoPMjS5cGYMxHW3IiT478JJA8M/CjTZ0GgLRekNGpwAsYABHIypcAgQMsITDtWJYBR6NSqMico9cqR6tKfY7GeBCuVwlipDNmefAtTrkSzB1RaIAoXodsABiZAEFB06gIBWC1mLVgBa0AAOw==)}
assets/js/custom.js CHANGED
@@ -34,8 +34,9 @@ jQuery(document).ready(function(){
34
  jQuery(document).on("click", ".popup-form-content", function (e) {
35
  e.stopPropagation();
36
  });
37
- jQuery(document).on("click", "#save-folder-data", function(e){
38
  e.stopPropagation();
 
39
 
40
  folderNameDynamic = jQuery("#add-update-folder-name").val();
41
 
@@ -79,9 +80,11 @@ jQuery(document).ready(function(){
79
  }
80
  });
81
  }
 
82
  });
83
- jQuery(document).on("click", "#update-folder-data", function(e){
84
  e.stopPropagation();
 
85
 
86
  folderNameDynamic = jQuery("#update-folder-item-name").val();
87
 
@@ -122,6 +125,7 @@ jQuery(document).ready(function(){
122
  }
123
  });
124
  }
 
125
  });
126
  jQuery(document).on("click", "#remove-folder-item", function (e){
127
  e.stopPropagation();
@@ -230,6 +234,7 @@ function removeFolderFromID() {
230
  jQuery(".folder-popup-form").removeClass("disabled");
231
  jQuery("#remove-folder-item").text("Yes, Delete it!");
232
  jQuery("#confirm-remove-folder").show();
 
233
  }
234
 
235
  function resetMediaAndPosts() {
@@ -286,6 +291,19 @@ function add_active_item_to_list() {
286
  });
287
  }
288
 
 
 
 
 
 
 
 
 
 
 
 
 
 
289
  function add_menu_to_list() {
290
  folderId = 0;
291
  if(jQuery(".active-term").length) {
@@ -716,10 +734,12 @@ jQuery(document).ready(function(){
716
  jQuery(this).removeClass("all-open");
717
  jQuery(".has-sub-tree").removeClass("active");
718
  statusType = 0;
 
719
  } else {
720
  jQuery(this).addClass("all-open");
721
  statusType = 1;
722
  jQuery(".has-sub-tree").addClass("active");
 
723
  }
724
  folderIDs = "";
725
  jQuery(".has-sub-tree").each(function(){
@@ -1150,17 +1170,18 @@ jQuery(document).ready(function(){
1150
  });
1151
  });
1152
  });
1153
-
1154
  checkForExpandCollapse();
1155
- })
1156
 
1157
  function checkForExpandCollapse() {
1158
  add_menu_to_list();
1159
  currentStatus = true;
1160
  if((jQuery("#custom-menu .has-sub-tree").length == jQuery("#custom-menu .has-sub-tree.active").length) && jQuery("#custom-menu .has-sub-tree").length) {
1161
  jQuery("#expand-collapse-list").addClass("all-open");
 
1162
  } else {
1163
  jQuery("#expand-collapse-list").removeClass("all-open");
 
1164
  }
1165
  }
1166
 
34
  jQuery(document).on("click", ".popup-form-content", function (e) {
35
  e.stopPropagation();
36
  });
37
+ jQuery(document).on("submit", "#save-folder-form", function(e){
38
  e.stopPropagation();
39
+ e.preventDefault();
40
 
41
  folderNameDynamic = jQuery("#add-update-folder-name").val();
42
 
80
  }
81
  });
82
  }
83
+ return false;
84
  });
85
+ jQuery(document).on("submit", "#update-folder-form", function(e){
86
  e.stopPropagation();
87
+ e.preventDefault();
88
 
89
  folderNameDynamic = jQuery("#update-folder-item-name").val();
90
 
125
  }
126
  });
127
  }
128
+ return false;
129
  });
130
  jQuery(document).on("click", "#remove-folder-item", function (e){
131
  e.stopPropagation();
234
  jQuery(".folder-popup-form").removeClass("disabled");
235
  jQuery("#remove-folder-item").text("Yes, Delete it!");
236
  jQuery("#confirm-remove-folder").show();
237
+ jQuery("#remove-folder-item").focus();
238
  }
239
 
240
  function resetMediaAndPosts() {
291
  });
292
  }
293
 
294
+ document.onkeydown = function(evt) {
295
+ evt = evt || window.event;
296
+ var isEscape = false;
297
+ if ("key" in evt) {
298
+ isEscape = (evt.key === "Escape" || evt.key === "Esc");
299
+ } else {
300
+ isEscape = (evt.keyCode === 27);
301
+ }
302
+ if (isEscape) {
303
+ jQuery(".folder-popup-form").hide();
304
+ }
305
+ };
306
+
307
  function add_menu_to_list() {
308
  folderId = 0;
309
  if(jQuery(".active-term").length) {
734
  jQuery(this).removeClass("all-open");
735
  jQuery(".has-sub-tree").removeClass("active");
736
  statusType = 0;
737
+ jQuery(this).attr("data-tooltip","Expand");
738
  } else {
739
  jQuery(this).addClass("all-open");
740
  statusType = 1;
741
  jQuery(".has-sub-tree").addClass("active");
742
+ jQuery(this).attr("data-tooltip","Collapse");
743
  }
744
  folderIDs = "";
745
  jQuery(".has-sub-tree").each(function(){
1170
  });
1171
  });
1172
  });
 
1173
  checkForExpandCollapse();
1174
+ });
1175
 
1176
  function checkForExpandCollapse() {
1177
  add_menu_to_list();
1178
  currentStatus = true;
1179
  if((jQuery("#custom-menu .has-sub-tree").length == jQuery("#custom-menu .has-sub-tree.active").length) && jQuery("#custom-menu .has-sub-tree").length) {
1180
  jQuery("#expand-collapse-list").addClass("all-open");
1181
+ jQuery("#expand-collapse-list").attr("data-tooltip","Collapse");
1182
  } else {
1183
  jQuery("#expand-collapse-list").removeClass("all-open");
1184
+ jQuery("#expand-collapse-list").attr("data-tooltip","Expand");
1185
  }
1186
  }
1187
 
assets/js/spectrum.min.js ADDED
@@ -0,0 +1,2 @@
 
 
1
+ (function(factory){"use strict";if(typeof define==="function"&&define.amd){define(["jquery"],factory)}else if(typeof exports=="object"&&typeof module=="object"){module.exports=factory(require("jquery"))}else{factory(jQuery)}})(function($,undefined){"use strict";var defaultOpts={beforeShow:noop,move:noop,change:noop,show:noop,hide:noop,color:false,flat:false,showInput:false,allowEmpty:false,showButtons:true,clickoutFiresChange:true,showInitial:false,showPalette:false,showPaletteOnly:false,hideAfterPaletteSelect:false,togglePaletteOnly:false,showSelectionPalette:true,localStorageKey:false,appendTo:"body",maxSelectionSize:7,cancelText:"cancel",chooseText:"choose",togglePaletteMoreText:"more",togglePaletteLessText:"less",clearText:"Clear Color Selection",noColorSelectedText:"No Color Selected",preferredFormat:false,className:"",containerClassName:"",replacerClassName:"",showAlpha:false,theme:"sp-light",palette:[["#ffffff","#000000","#ff0000","#ff8000","#ffff00","#008000","#0000ff","#4b0082","#9400d3"]],selectionPalette:[],disabled:false,offset:null},spectrums=[],IE=!!/msie/i.exec(window.navigator.userAgent),rgbaSupport=function(){function contains(str,substr){return!!~(""+str).indexOf(substr)}var elem=document.createElement("div");var style=elem.style;style.cssText="background-color:rgba(0,0,0,.5)";return contains(style.backgroundColor,"rgba")||contains(style.backgroundColor,"hsla")}(),replaceInput=["<div class='sp-replacer'>","<div class='sp-preview'><div class='sp-preview-inner'></div></div>","<div class='sp-dd'>&#9660;</div>","</div>"].join(""),markup=function(){var gradientFix="";if(IE){for(var i=1;i<=6;i++){gradientFix+="<div class='sp-"+i+"'></div>"}}return["<div class='sp-container sp-hidden'>","<div class='sp-palette-container'>","<div class='sp-palette sp-thumb sp-cf'></div>","<div class='sp-palette-button-container sp-cf'>","<button type='button' class='sp-palette-toggle'></button>","</div>","</div>","<div class='sp-picker-container'>","<div class='sp-top sp-cf'>","<div class='sp-fill'></div>","<div class='sp-top-inner'>","<div class='sp-color'>","<div class='sp-sat'>","<div class='sp-val'>","<div class='sp-dragger'></div>","</div>","</div>","</div>","<div class='sp-clear sp-clear-display'>","</div>","<div class='sp-hue'>","<div class='sp-slider'></div>",gradientFix,"</div>","</div>","<div class='sp-alpha'><div class='sp-alpha-inner'><div class='sp-alpha-handle'></div></div></div>","</div>","<div class='sp-input-container sp-cf'>","<input class='sp-input' type='text' spellcheck='false' />","</div>","<div class='sp-initial sp-thumb sp-cf'></div>","<div class='sp-button-container sp-cf'>","<a class='sp-cancel' href='#'></a>","<button type='button' class='sp-choose'></button>","</div>","</div>","</div>"].join("")}();function paletteTemplate(p,color,className,opts){var html=[];for(var i=0;i<p.length;i++){var current=p[i];if(current){var tiny=tinycolor(current);var c=tiny.toHsl().l<.5?"sp-thumb-el sp-thumb-dark":"sp-thumb-el sp-thumb-light";c+=tinycolor.equals(color,current)?" sp-thumb-active":"";var formattedString=tiny.toString(opts.preferredFormat||"rgb");var swatchStyle=rgbaSupport?"background-color:"+tiny.toRgbString():"filter:"+tiny.toFilter();html.push('<span title="'+formattedString+'" data-color="'+tiny.toRgbString()+'" class="'+c+'"><span class="sp-thumb-inner" style="'+swatchStyle+';" /></span>')}else{var cls="sp-clear-display";html.push($("<div />").append($('<span data-color="" style="background-color:transparent;" class="'+cls+'"></span>').attr("title",opts.noColorSelectedText)).html())}}return"<div class='sp-cf "+className+"'>"+html.join("")+"</div>"}function hideAll(){for(var i=0;i<spectrums.length;i++){if(spectrums[i]){spectrums[i].hide()}}}function instanceOptions(o,callbackContext){var opts=$.extend({},defaultOpts,o);opts.callbacks={move:bind(opts.move,callbackContext),change:bind(opts.change,callbackContext),show:bind(opts.show,callbackContext),hide:bind(opts.hide,callbackContext),beforeShow:bind(opts.beforeShow,callbackContext)};return opts}function spectrum(element,o){var opts=instanceOptions(o,element),flat=opts.flat,showSelectionPalette=opts.showSelectionPalette,localStorageKey=opts.localStorageKey,theme=opts.theme,callbacks=opts.callbacks,resize=throttle(reflow,10),visible=false,isDragging=false,dragWidth=0,dragHeight=0,dragHelperHeight=0,slideHeight=0,slideWidth=0,alphaWidth=0,alphaSlideHelperWidth=0,slideHelperHeight=0,currentHue=0,currentSaturation=0,currentValue=0,currentAlpha=1,palette=[],paletteArray=[],paletteLookup={},selectionPalette=opts.selectionPalette.slice(0),maxSelectionSize=opts.maxSelectionSize,draggingClass="sp-dragging",shiftMovementDirection=null;var doc=element.ownerDocument,body=doc.body,boundElement=$(element),disabled=false,container=$(markup,doc).addClass(theme),pickerContainer=container.find(".sp-picker-container"),dragger=container.find(".sp-color"),dragHelper=container.find(".sp-dragger"),slider=container.find(".sp-hue"),slideHelper=container.find(".sp-slider"),alphaSliderInner=container.find(".sp-alpha-inner"),alphaSlider=container.find(".sp-alpha"),alphaSlideHelper=container.find(".sp-alpha-handle"),textInput=container.find(".sp-input"),paletteContainer=container.find(".sp-palette"),initialColorContainer=container.find(".sp-initial"),cancelButton=container.find(".sp-cancel"),clearButton=container.find(".sp-clear"),chooseButton=container.find(".sp-choose"),toggleButton=container.find(".sp-palette-toggle"),isInput=boundElement.is("input"),isInputTypeColor=isInput&&boundElement.attr("type")==="color"&&inputTypeColorSupport(),shouldReplace=isInput&&!flat,replacer=shouldReplace?$(replaceInput).addClass(theme).addClass(opts.className).addClass(opts.replacerClassName):$([]),offsetElement=shouldReplace?replacer:boundElement,previewElement=replacer.find(".sp-preview-inner"),initialColor=opts.color||isInput&&boundElement.val(),colorOnShow=false,currentPreferredFormat=opts.preferredFormat,clickoutFiresChange=!opts.showButtons||opts.clickoutFiresChange,isEmpty=!initialColor,allowEmpty=opts.allowEmpty&&!isInputTypeColor;function applyOptions(){if(opts.showPaletteOnly){opts.showPalette=true}toggleButton.text(opts.showPaletteOnly?opts.togglePaletteMoreText:opts.togglePaletteLessText);if(opts.palette){palette=opts.palette.slice(0);paletteArray=$.isArray(palette[0])?palette:[palette];paletteLookup={};for(var i=0;i<paletteArray.length;i++){for(var j=0;j<paletteArray[i].length;j++){var rgb=tinycolor(paletteArray[i][j]).toRgbString();paletteLookup[rgb]=true}}}container.toggleClass("sp-flat",flat);container.toggleClass("sp-input-disabled",!opts.showInput);container.toggleClass("sp-alpha-enabled",opts.showAlpha);container.toggleClass("sp-clear-enabled",allowEmpty);container.toggleClass("sp-buttons-disabled",!opts.showButtons);container.toggleClass("sp-palette-buttons-disabled",!opts.togglePaletteOnly);container.toggleClass("sp-palette-disabled",!opts.showPalette);container.toggleClass("sp-palette-only",opts.showPaletteOnly);container.toggleClass("sp-initial-disabled",!opts.showInitial);container.addClass(opts.className).addClass(opts.containerClassName);reflow()}function initialize(){if(IE){container.find("*:not(input)").attr("unselectable","on")}applyOptions();if(shouldReplace){boundElement.after(replacer).hide()}if(!allowEmpty){clearButton.hide()}if(flat){boundElement.after(container).hide()}else{var appendTo=opts.appendTo==="parent"?boundElement.parent():$(opts.appendTo);if(appendTo.length!==1){appendTo=$("body")}appendTo.append(container)}updateSelectionPaletteFromStorage();offsetElement.bind("click.spectrum touchstart.spectrum",function(e){if(!disabled){toggle()}e.stopPropagation();if(!$(e.target).is("input")){e.preventDefault()}});if(boundElement.is(":disabled")||opts.disabled===true){disable()}container.click(stopPropagation);textInput.change(setFromTextInput);textInput.bind("paste",function(){setTimeout(setFromTextInput,1)});textInput.keydown(function(e){if(e.keyCode==13){setFromTextInput()}});cancelButton.text(opts.cancelText);cancelButton.bind("click.spectrum",function(e){e.stopPropagation();e.preventDefault();revert();hide()});clearButton.attr("title",opts.clearText);clearButton.bind("click.spectrum",function(e){e.stopPropagation();e.preventDefault();isEmpty=true;move();if(flat){updateOriginalInput(true)}});chooseButton.text(opts.chooseText);chooseButton.bind("click.spectrum",function(e){e.stopPropagation();e.preventDefault();if(IE&&textInput.is(":focus")){textInput.trigger("change")}if(isValid()){updateOriginalInput(true);hide()}});toggleButton.text(opts.showPaletteOnly?opts.togglePaletteMoreText:opts.togglePaletteLessText);toggleButton.bind("click.spectrum",function(e){e.stopPropagation();e.preventDefault();opts.showPaletteOnly=!opts.showPaletteOnly;if(!opts.showPaletteOnly&&!flat){container.css("left","-="+(pickerContainer.outerWidth(true)+5))}applyOptions()});draggable(alphaSlider,function(dragX,dragY,e){currentAlpha=dragX/alphaWidth;isEmpty=false;if(e.shiftKey){currentAlpha=Math.round(currentAlpha*10)/10}move()},dragStart,dragStop);draggable(slider,function(dragX,dragY){currentHue=parseFloat(dragY/slideHeight);isEmpty=false;if(!opts.showAlpha){currentAlpha=1}move()},dragStart,dragStop);draggable(dragger,function(dragX,dragY,e){if(!e.shiftKey){shiftMovementDirection=null}else if(!shiftMovementDirection){var oldDragX=currentSaturation*dragWidth;var oldDragY=dragHeight-currentValue*dragHeight;var furtherFromX=Math.abs(dragX-oldDragX)>Math.abs(dragY-oldDragY);shiftMovementDirection=furtherFromX?"x":"y"}var setSaturation=!shiftMovementDirection||shiftMovementDirection==="x";var setValue=!shiftMovementDirection||shiftMovementDirection==="y";if(setSaturation){currentSaturation=parseFloat(dragX/dragWidth)}if(setValue){currentValue=parseFloat((dragHeight-dragY)/dragHeight)}isEmpty=false;if(!opts.showAlpha){currentAlpha=1}move()},dragStart,dragStop);if(!!initialColor){set(initialColor);updateUI();currentPreferredFormat=opts.preferredFormat||tinycolor(initialColor).format;addColorToSelectionPalette(initialColor)}else{updateUI()}if(flat){show()}function paletteElementClick(e){if(e.data&&e.data.ignore){set($(e.target).closest(".sp-thumb-el").data("color"));move()}else{set($(e.target).closest(".sp-thumb-el").data("color"));move();updateOriginalInput(true);if(opts.hideAfterPaletteSelect){hide()}}return false}var paletteEvent=IE?"mousedown.spectrum":"click.spectrum touchstart.spectrum";paletteContainer.delegate(".sp-thumb-el",paletteEvent,paletteElementClick);initialColorContainer.delegate(".sp-thumb-el:nth-child(1)",paletteEvent,{ignore:true},paletteElementClick)}function updateSelectionPaletteFromStorage(){if(localStorageKey&&window.localStorage){try{var oldPalette=window.localStorage[localStorageKey].split(",#");if(oldPalette.length>1){delete window.localStorage[localStorageKey];$.each(oldPalette,function(i,c){addColorToSelectionPalette(c)})}}catch(e){}try{selectionPalette=window.localStorage[localStorageKey].split(";")}catch(e){}}}function addColorToSelectionPalette(color){if(showSelectionPalette){var rgb=tinycolor(color).toRgbString();if(!paletteLookup[rgb]&&$.inArray(rgb,selectionPalette)===-1){selectionPalette.push(rgb);while(selectionPalette.length>maxSelectionSize){selectionPalette.shift()}}if(localStorageKey&&window.localStorage){try{window.localStorage[localStorageKey]=selectionPalette.join(";")}catch(e){}}}}function getUniqueSelectionPalette(){var unique=[];if(opts.showPalette){for(var i=0;i<selectionPalette.length;i++){var rgb=tinycolor(selectionPalette[i]).toRgbString();if(!paletteLookup[rgb]){unique.push(selectionPalette[i])}}}return unique.reverse().slice(0,opts.maxSelectionSize)}function drawPalette(){var currentColor=get();var html=$.map(paletteArray,function(palette,i){return paletteTemplate(palette,currentColor,"sp-palette-row sp-palette-row-"+i,opts)});updateSelectionPaletteFromStorage();if(selectionPalette){html.push(paletteTemplate(getUniqueSelectionPalette(),currentColor,"sp-palette-row sp-palette-row-selection",opts))}paletteContainer.html(html.join(""))}function drawInitial(){if(opts.showInitial){var initial=colorOnShow;var current=get();initialColorContainer.html(paletteTemplate([initial,current],current,"sp-palette-row-initial",opts))}}function dragStart(){if(dragHeight<=0||dragWidth<=0||slideHeight<=0){reflow()}isDragging=true;container.addClass(draggingClass);shiftMovementDirection=null;boundElement.trigger("dragstart.spectrum",[get()])}function dragStop(){isDragging=false;container.removeClass(draggingClass);boundElement.trigger("dragstop.spectrum",[get()])}function setFromTextInput(){var value=textInput.val();if((value===null||value==="")&&allowEmpty){set(null);updateOriginalInput(true)}else{var tiny=tinycolor(value);if(tiny.isValid()){set(tiny);updateOriginalInput(true)}else{textInput.addClass("sp-validation-error")}}}function toggle(){if(visible){hide()}else{show()}}function show(){var event=$.Event("beforeShow.spectrum");if(visible){reflow();return}boundElement.trigger(event,[get()]);if(callbacks.beforeShow(get())===false||event.isDefaultPrevented()){return}hideAll();visible=true;$(doc).bind("keydown.spectrum",onkeydown);$(doc).bind("click.spectrum",clickout);$(window).bind("resize.spectrum",resize);replacer.addClass("sp-active");container.removeClass("sp-hidden");reflow();updateUI();colorOnShow=get();drawInitial();callbacks.show(colorOnShow);boundElement.trigger("show.spectrum",[colorOnShow])}function onkeydown(e){if(e.keyCode===27){hide()}}function clickout(e){if(e.button==2){return}if(isDragging){return}if(clickoutFiresChange){updateOriginalInput(true)}else{revert()}hide()}function hide(){if(!visible||flat){return}visible=false;$(doc).unbind("keydown.spectrum",onkeydown);$(doc).unbind("click.spectrum",clickout);$(window).unbind("resize.spectrum",resize);replacer.removeClass("sp-active");container.addClass("sp-hidden");callbacks.hide(get());boundElement.trigger("hide.spectrum",[get()])}function revert(){set(colorOnShow,true)}function set(color,ignoreFormatChange){if(tinycolor.equals(color,get())){updateUI();return}var newColor,newHsv;if(!color&&allowEmpty){isEmpty=true}else{isEmpty=false;newColor=tinycolor(color);newHsv=newColor.toHsv();currentHue=newHsv.h%360/360;currentSaturation=newHsv.s;currentValue=newHsv.v;currentAlpha=newHsv.a}updateUI();if(newColor&&newColor.isValid()&&!ignoreFormatChange){currentPreferredFormat=opts.preferredFormat||newColor.getFormat()}}function get(opts){opts=opts||{};if(allowEmpty&&isEmpty){return null}return tinycolor.fromRatio({h:currentHue,s:currentSaturation,v:currentValue,a:Math.round(currentAlpha*100)/100},{format:opts.format||currentPreferredFormat})}function isValid(){return!textInput.hasClass("sp-validation-error")}function move(){updateUI();callbacks.move(get());boundElement.trigger("move.spectrum",[get()])}function updateUI(){textInput.removeClass("sp-validation-error");updateHelperLocations();var flatColor=tinycolor.fromRatio({h:currentHue,s:1,v:1});dragger.css("background-color",flatColor.toHexString());var format=currentPreferredFormat;if(currentAlpha<1&&!(currentAlpha===0&&format==="name")){if(format==="hex"||format==="hex3"||format==="hex6"||format==="name"){format="rgb"}}var realColor=get({format:format}),displayColor="";previewElement.removeClass("sp-clear-display");previewElement.css("background-color","transparent");if(!realColor&&allowEmpty){previewElement.addClass("sp-clear-display")}else{var realHex=realColor.toHexString(),realRgb=realColor.toRgbString();if(rgbaSupport||realColor.alpha===1){previewElement.css("background-color",realRgb)}else{previewElement.css("background-color","transparent");previewElement.css("filter",realColor.toFilter())}if(opts.showAlpha){var rgb=realColor.toRgb();rgb.a=0;var realAlpha=tinycolor(rgb).toRgbString();var gradient="linear-gradient(left, "+realAlpha+", "+realHex+")";if(IE){alphaSliderInner.css("filter",tinycolor(realAlpha).toFilter({gradientType:1},realHex))}else{alphaSliderInner.css("background","-webkit-"+gradient);alphaSliderInner.css("background","-moz-"+gradient);alphaSliderInner.css("background","-ms-"+gradient);alphaSliderInner.css("background","linear-gradient(to right, "+realAlpha+", "+realHex+")")}}displayColor=realColor.toString(format)}if(opts.showInput){textInput.val(displayColor)}if(opts.showPalette){drawPalette()}drawInitial()}function updateHelperLocations(){var s=currentSaturation;var v=currentValue;if(allowEmpty&&isEmpty){alphaSlideHelper.hide();slideHelper.hide();dragHelper.hide()}else{alphaSlideHelper.show();slideHelper.show();dragHelper.show();var dragX=s*dragWidth;var dragY=dragHeight-v*dragHeight;dragX=Math.max(-dragHelperHeight,Math.min(dragWidth-dragHelperHeight,dragX-dragHelperHeight));dragY=Math.max(-dragHelperHeight,Math.min(dragHeight-dragHelperHeight,dragY-dragHelperHeight));dragHelper.css({top:dragY+"px",left:dragX+"px"});var alphaX=currentAlpha*alphaWidth;alphaSlideHelper.css({left:alphaX-alphaSlideHelperWidth/2+"px"});var slideY=currentHue*slideHeight;slideHelper.css({top:slideY-slideHelperHeight+"px"})}}function updateOriginalInput(fireCallback){var color=get(),displayColor="",hasChanged=!tinycolor.equals(color,colorOnShow);if(color){displayColor=color.toString(currentPreferredFormat);addColorToSelectionPalette(color)}if(isInput){boundElement.val(displayColor)}if(fireCallback&&hasChanged){callbacks.change(color);boundElement.trigger("change",[color])}}function reflow(){if(!visible){return}dragWidth=dragger.width();dragHeight=dragger.height();dragHelperHeight=dragHelper.height();slideWidth=slider.width();slideHeight=slider.height();slideHelperHeight=slideHelper.height();alphaWidth=alphaSlider.width();alphaSlideHelperWidth=alphaSlideHelper.width();if(!flat){container.css("position","absolute");if(opts.offset){container.offset(opts.offset)}else{container.offset(getOffset(container,offsetElement))}}updateHelperLocations();if(opts.showPalette){drawPalette()}boundElement.trigger("reflow.spectrum")}function destroy(){boundElement.show();offsetElement.unbind("click.spectrum touchstart.spectrum");container.remove();replacer.remove();spectrums[spect.id]=null}function option(optionName,optionValue){if(optionName===undefined){return $.extend({},opts)}if(optionValue===undefined){return opts[optionName]}opts[optionName]=optionValue;if(optionName==="preferredFormat"){currentPreferredFormat=opts.preferredFormat}applyOptions()}function enable(){disabled=false;boundElement.attr("disabled",false);offsetElement.removeClass("sp-disabled")}function disable(){hide();disabled=true;boundElement.attr("disabled",true);offsetElement.addClass("sp-disabled")}function setOffset(coord){opts.offset=coord;reflow()}initialize();var spect={show:show,hide:hide,toggle:toggle,reflow:reflow,option:option,enable:enable,disable:disable,offset:setOffset,set:function(c){set(c);updateOriginalInput()},get:get,destroy:destroy,container:container};spect.id=spectrums.push(spect)-1;return spect}function getOffset(picker,input){var extraY=0;var dpWidth=picker.outerWidth();var dpHeight=picker.outerHeight();var inputHeight=input.outerHeight();var doc=picker[0].ownerDocument;var docElem=doc.documentElement;var viewWidth=docElem.clientWidth+$(doc).scrollLeft();var viewHeight=docElem.clientHeight+$(doc).scrollTop();var offset=input.offset();offset.top+=inputHeight;offset.left-=Math.min(offset.left,offset.left+dpWidth>viewWidth&&viewWidth>dpWidth?Math.abs(offset.left+dpWidth-viewWidth):0);offset.top-=Math.min(offset.top,offset.top+dpHeight>viewHeight&&viewHeight>dpHeight?Math.abs(dpHeight+inputHeight-extraY):extraY);return offset}function noop(){}function stopPropagation(e){e.stopPropagation()}function bind(func,obj){var slice=Array.prototype.slice;var args=slice.call(arguments,2);return function(){return func.apply(obj,args.concat(slice.call(arguments)))}}function draggable(element,onmove,onstart,onstop){onmove=onmove||function(){};onstart=onstart||function(){};onstop=onstop||function(){};var doc=document;var dragging=false;var offset={};var maxHeight=0;var maxWidth=0;var hasTouch="ontouchstart"in window;var duringDragEvents={};duringDragEvents["selectstart"]=prevent;duringDragEvents["dragstart"]=prevent;duringDragEvents["touchmove mousemove"]=move;duringDragEvents["touchend mouseup"]=stop;function prevent(e){if(e.stopPropagation){e.stopPropagation()}if(e.preventDefault){e.preventDefault()}e.returnValue=false}function move(e){if(dragging){if(IE&&doc.documentMode<9&&!e.button){return stop()}var t0=e.originalEvent&&e.originalEvent.touches&&e.originalEvent.touches[0];var pageX=t0&&t0.pageX||e.pageX;var pageY=t0&&t0.pageY||e.pageY;var dragX=Math.max(0,Math.min(pageX-offset.left,maxWidth));var dragY=Math.max(0,Math.min(pageY-offset.top,maxHeight));if(hasTouch){prevent(e)}onmove.apply(element,[dragX,dragY,e])}}function start(e){var rightclick=e.which?e.which==3:e.button==2;if(!rightclick&&!dragging){if(onstart.apply(element,arguments)!==false){dragging=true;maxHeight=$(element).height();maxWidth=$(element).width();offset=$(element).offset();$(doc).bind(duringDragEvents);$(doc.body).addClass("sp-dragging");move(e);prevent(e)}}}function stop(){if(dragging){$(doc).unbind(duringDragEvents);$(doc.body).removeClass("sp-dragging");setTimeout(function(){onstop.apply(element,arguments)},0)}dragging=false}$(element).bind("touchstart mousedown",start)}function throttle(func,wait,debounce){var timeout;return function(){var context=this,args=arguments;var throttler=function(){timeout=null;func.apply(context,args)};if(debounce)clearTimeout(timeout);if(debounce||!timeout)timeout=setTimeout(throttler,wait)}}function inputTypeColorSupport(){return $.fn.spectrum.inputTypeColorSupport()}var dataID="spectrum.id";$.fn.spectrum=function(opts,extra){if(typeof opts=="string"){var returnValue=this;var args=Array.prototype.slice.call(arguments,1);this.each(function(){var spect=spectrums[$(this).data(dataID)];if(spect){var method=spect[opts];if(!method){throw new Error("Spectrum: no such method: '"+opts+"'")}if(opts=="get"){returnValue=spect.get()}else if(opts=="container"){returnValue=spect.container}else if(opts=="option"){returnValue=spect.option.apply(spect,args)}else if(opts=="destroy"){spect.destroy();$(this).removeData(dataID)}else{method.apply(spect,args)}}});return returnValue}return this.spectrum("destroy").each(function(){var options=$.extend({},opts,$(this).data());var spect=spectrum(this,options);$(this).data(dataID,spect.id)})};$.fn.spectrum.load=true;$.fn.spectrum.loadOpts={};$.fn.spectrum.draggable=draggable;$.fn.spectrum.defaults=defaultOpts;$.fn.spectrum.inputTypeColorSupport=function inputTypeColorSupport(){if(typeof inputTypeColorSupport._cachedResult==="undefined"){var colorInput=$("<input type='color'/>")[0];inputTypeColorSupport._cachedResult=colorInput.type==="color"&&colorInput.value!==""}return inputTypeColorSupport._cachedResult};$.spectrum={};$.spectrum.localization={};$.spectrum.palettes={};$.fn.spectrum.processNativeColorInputs=function(){var colorInputs=$("input[type=color]");if(colorInputs.length&&!inputTypeColorSupport()){colorInputs.spectrum({preferredFormat:"hex6"})}};(function(){var trimLeft=/^[\s,#]+/,trimRight=/\s+$/,tinyCounter=0,math=Math,mathRound=math.round,mathMin=math.min,mathMax=math.max,mathRandom=math.random;var tinycolor=function(color,opts){color=color?color:"";opts=opts||{};if(color instanceof tinycolor){return color}if(!(this instanceof tinycolor)){return new tinycolor(color,opts)}var rgb=inputToRGB(color);this._originalInput=color,this._r=rgb.r,this._g=rgb.g,this._b=rgb.b,this._a=rgb.a,this._roundA=mathRound(100*this._a)/100,this._format=opts.format||rgb.format;this._gradientType=opts.gradientType;if(this._r<1){this._r=mathRound(this._r)}if(this._g<1){this._g=mathRound(this._g)}if(this._b<1){this._b=mathRound(this._b)}this._ok=rgb.ok;this._tc_id=tinyCounter++};tinycolor.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var rgb=this.toRgb();return(rgb.r*299+rgb.g*587+rgb.b*114)/1e3},setAlpha:function(value){this._a=boundAlpha(value);this._roundA=mathRound(100*this._a)/100;return this},toHsv:function(){var hsv=rgbToHsv(this._r,this._g,this._b);return{h:hsv.h*360,s:hsv.s,v:hsv.v,a:this._a}},toHsvString:function(){var hsv=rgbToHsv(this._r,this._g,this._b);var h=mathRound(hsv.h*360),s=mathRound(hsv.s*100),v=mathRound(hsv.v*100);return this._a==1?"hsv("+h+", "+s+"%, "+v+"%)":"hsva("+h+", "+s+"%, "+v+"%, "+this._roundA+")"},toHsl:function(){var hsl=rgbToHsl(this._r,this._g,this._b);return{h:hsl.h*360,s:hsl.s,l:hsl.l,a:this._a}},toHslString:function(){var hsl=rgbToHsl(this._r,this._g,this._b);var h=mathRound(hsl.h*360),s=mathRound(hsl.s*100),l=mathRound(hsl.l*100);return this._a==1?"hsl("+h+", "+s+"%, "+l+"%)":"hsla("+h+", "+s+"%, "+l+"%, "+this._roundA+")"},toHex:function(allow3Char){return rgbToHex(this._r,this._g,this._b,allow3Char)},toHexString:function(allow3Char){return"#"+this.toHex(allow3Char)},toHex8:function(){return rgbaToHex(this._r,this._g,this._b,this._a)},toHex8String:function(){return"#"+this.toHex8()},toRgb:function(){return{r:mathRound(this._r),g:mathRound(this._g),b:mathRound(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+mathRound(this._r)+", "+mathRound(this._g)+", "+mathRound(this._b)+")":"rgba("+mathRound(this._r)+", "+mathRound(this._g)+", "+mathRound(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:mathRound(bound01(this._r,255)*100)+"%",g:mathRound(bound01(this._g,255)*100)+"%",b:mathRound(bound01(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+mathRound(bound01(this._r,255)*100)+"%, "+mathRound(bound01(this._g,255)*100)+"%, "+mathRound(bound01(this._b,255)*100)+"%)":"rgba("+mathRound(bound01(this._r,255)*100)+"%, "+mathRound(bound01(this._g,255)*100)+"%, "+mathRound(bound01(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){if(this._a===0){return"transparent"}if(this._a<1){return false}return hexNames[rgbToHex(this._r,this._g,this._b,true)]||false},toFilter:function(secondColor){var hex8String="#"+rgbaToHex(this._r,this._g,this._b,this._a);var secondHex8String=hex8String;var gradientType=this._gradientType?"GradientType = 1, ":"";if(secondColor){var s=tinycolor(secondColor);secondHex8String=s.toHex8String()}return"progid:DXImageTransform.Microsoft.gradient("+gradientType+"startColorstr="+hex8String+",endColorstr="+secondHex8String+")"},toString:function(format){var formatSet=!!format;format=format||this._format;var formattedString=false;var hasAlpha=this._a<1&&this._a>=0;var needsAlphaFormat=!formatSet&&hasAlpha&&(format==="hex"||format==="hex6"||format==="hex3"||format==="name");if(needsAlphaFormat){if(format==="name"&&this._a===0){return this.toName()}return this.toRgbString()}if(format==="rgb"){formattedString=this.toRgbString()}if(format==="prgb"){formattedString=this.toPercentageRgbString()}if(format==="hex"||format==="hex6"){formattedString=this.toHexString()}if(format==="hex3"){formattedString=this.toHexString(true)}if(format==="hex8"){formattedString=this.toHex8String()}if(format==="name"){formattedString=this.toName()}if(format==="hsl"){formattedString=this.toHslString()}if(format==="hsv"){formattedString=this.toHsvString()}return formattedString||this.toHexString()},_applyModification:function(fn,args){var color=fn.apply(null,[this].concat([].slice.call(args)));this._r=color._r;this._g=color._g;this._b=color._b;this.setAlpha(color._a);return this},lighten:function(){return this._applyModification(lighten,arguments)},brighten:function(){return this._applyModification(brighten,arguments)},darken:function(){return this._applyModification(darken,arguments)},desaturate:function(){return this._applyModification(desaturate,arguments)},saturate:function(){return this._applyModification(saturate,arguments)},greyscale:function(){return this._applyModification(greyscale,arguments)},spin:function(){return this._applyModification(spin,arguments)},_applyCombination:function(fn,args){return fn.apply(null,[this].concat([].slice.call(args)))},analogous:function(){return this._applyCombination(analogous,arguments)},complement:function(){return this._applyCombination(complement,arguments)},monochromatic:function(){return this._applyCombination(monochromatic,arguments)},splitcomplement:function(){return this._applyCombination(splitcomplement,arguments)},triad:function(){return this._applyCombination(triad,arguments)},tetrad:function(){return this._applyCombination(tetrad,arguments)}};tinycolor.fromRatio=function(color,opts){if(typeof color=="object"){var newColor={};for(var i in color){if(color.hasOwnProperty(i)){if(i==="a"){newColor[i]=color[i]}else{newColor[i]=convertToPercentage(color[i])}}}color=newColor}return tinycolor(color,opts)};function inputToRGB(color){var rgb={r:0,g:0,b:0};var a=1;var ok=false;var format=false;if(typeof color=="string"){color=stringInputToObject(color)}if(typeof color=="object"){if(color.hasOwnProperty("r")&&color.hasOwnProperty("g")&&color.hasOwnProperty("b")){rgb=rgbToRgb(color.r,color.g,color.b);ok=true;format=String(color.r).substr(-1)==="%"?"prgb":"rgb"}else if(color.hasOwnProperty("h")&&color.hasOwnProperty("s")&&color.hasOwnProperty("v")){color.s=convertToPercentage(color.s);color.v=convertToPercentage(color.v);rgb=hsvToRgb(color.h,color.s,color.v);ok=true;format="hsv"}else if(color.hasOwnProperty("h")&&color.hasOwnProperty("s")&&color.hasOwnProperty("l")){color.s=convertToPercentage(color.s);color.l=convertToPercentage(color.l);rgb=hslToRgb(color.h,color.s,color.l);ok=true;format="hsl"}if(color.hasOwnProperty("a")){a=color.a}}a=boundAlpha(a);return{ok:ok,format:color.format||format,r:mathMin(255,mathMax(rgb.r,0)),g:mathMin(255,mathMax(rgb.g,0)),b:mathMin(255,mathMax(rgb.b,0)),a:a}}function rgbToRgb(r,g,b){return{r:bound01(r,255)*255,g:bound01(g,255)*255,b:bound01(b,255)*255}}function rgbToHsl(r,g,b){r=bound01(r,255);g=bound01(g,255);b=bound01(b,255);var max=mathMax(r,g,b),min=mathMin(r,g,b);var h,s,l=(max+min)/2;if(max==min){h=s=0}else{var d=max-min;s=l>.5?d/(2-max-min):d/(max+min);switch(max){case r:h=(g-b)/d+(g<b?6:0);break;case g:h=(b-r)/d+2;break;case b:h=(r-g)/d+4;break}h/=6}return{h:h,s:s,l:l}}function hslToRgb(h,s,l){var r,g,b;h=bound01(h,360);s=bound01(s,100);l=bound01(l,100);function hue2rgb(p,q,t){if(t<0)t+=1;if(t>1)t-=1;if(t<1/6)return p+(q-p)*6*t;if(t<1/2)return q;if(t<2/3)return p+(q-p)*(2/3-t)*6;return p}if(s===0){r=g=b=l}else{var q=l<.5?l*(1+s):l+s-l*s;var p=2*l-q;r=hue2rgb(p,q,h+1/3);g=hue2rgb(p,q,h);b=hue2rgb(p,q,h-1/3)}return{r:r*255,g:g*255,b:b*255}}function rgbToHsv(r,g,b){r=bound01(r,255);g=bound01(g,255);b=bound01(b,255);var max=mathMax(r,g,b),min=mathMin(r,g,b);var h,s,v=max;var d=max-min;s=max===0?0:d/max;if(max==min){h=0}else{switch(max){case r:h=(g-b)/d+(g<b?6:0);break;case g:h=(b-r)/d+2;break;case b:h=(r-g)/d+4;break}h/=6}return{h:h,s:s,v:v}}function hsvToRgb(h,s,v){h=bound01(h,360)*6;s=bound01(s,100);v=bound01(v,100);var i=math.floor(h),f=h-i,p=v*(1-s),q=v*(1-f*s),t=v*(1-(1-f)*s),mod=i%6,r=[v,q,p,p,t,v][mod],g=[t,v,v,q,p,p][mod],b=[p,p,t,v,v,q][mod];return{r:r*255,g:g*255,b:b*255}}function rgbToHex(r,g,b,allow3Char){var hex=[pad2(mathRound(r).toString(16)),pad2(mathRound(g).toString(16)),pad2(mathRound(b).toString(16))];if(allow3Char&&hex[0].charAt(0)==hex[0].charAt(1)&&hex[1].charAt(0)==hex[1].charAt(1)&&hex[2].charAt(0)==hex[2].charAt(1)){return hex[0].charAt(0)+hex[1].charAt(0)+hex[2].charAt(0)}return hex.join("")}function rgbaToHex(r,g,b,a){var hex=[pad2(convertDecimalToHex(a)),pad2(mathRound(r).toString(16)),pad2(mathRound(g).toString(16)),pad2(mathRound(b).toString(16))];return hex.join("")}tinycolor.equals=function(color1,color2){if(!color1||!color2){return false}return tinycolor(color1).toRgbString()==tinycolor(color2).toRgbString()};tinycolor.random=function(){return tinycolor.fromRatio({r:mathRandom(),g:mathRandom(),
2
+ b:mathRandom()})};function desaturate(color,amount){amount=amount===0?0:amount||10;var hsl=tinycolor(color).toHsl();hsl.s-=amount/100;hsl.s=clamp01(hsl.s);return tinycolor(hsl)}function saturate(color,amount){amount=amount===0?0:amount||10;var hsl=tinycolor(color).toHsl();hsl.s+=amount/100;hsl.s=clamp01(hsl.s);return tinycolor(hsl)}function greyscale(color){return tinycolor(color).desaturate(100)}function lighten(color,amount){amount=amount===0?0:amount||10;var hsl=tinycolor(color).toHsl();hsl.l+=amount/100;hsl.l=clamp01(hsl.l);return tinycolor(hsl)}function brighten(color,amount){amount=amount===0?0:amount||10;var rgb=tinycolor(color).toRgb();rgb.r=mathMax(0,mathMin(255,rgb.r-mathRound(255*-(amount/100))));rgb.g=mathMax(0,mathMin(255,rgb.g-mathRound(255*-(amount/100))));rgb.b=mathMax(0,mathMin(255,rgb.b-mathRound(255*-(amount/100))));return tinycolor(rgb)}function darken(color,amount){amount=amount===0?0:amount||10;var hsl=tinycolor(color).toHsl();hsl.l-=amount/100;hsl.l=clamp01(hsl.l);return tinycolor(hsl)}function spin(color,amount){var hsl=tinycolor(color).toHsl();var hue=(mathRound(hsl.h)+amount)%360;hsl.h=hue<0?360+hue:hue;return tinycolor(hsl)}function complement(color){var hsl=tinycolor(color).toHsl();hsl.h=(hsl.h+180)%360;return tinycolor(hsl)}function triad(color){var hsl=tinycolor(color).toHsl();var h=hsl.h;return[tinycolor(color),tinycolor({h:(h+120)%360,s:hsl.s,l:hsl.l}),tinycolor({h:(h+240)%360,s:hsl.s,l:hsl.l})]}function tetrad(color){var hsl=tinycolor(color).toHsl();var h=hsl.h;return[tinycolor(color),tinycolor({h:(h+90)%360,s:hsl.s,l:hsl.l}),tinycolor({h:(h+180)%360,s:hsl.s,l:hsl.l}),tinycolor({h:(h+270)%360,s:hsl.s,l:hsl.l})]}function splitcomplement(color){var hsl=tinycolor(color).toHsl();var h=hsl.h;return[tinycolor(color),tinycolor({h:(h+72)%360,s:hsl.s,l:hsl.l}),tinycolor({h:(h+216)%360,s:hsl.s,l:hsl.l})]}function analogous(color,results,slices){results=results||6;slices=slices||30;var hsl=tinycolor(color).toHsl();var part=360/slices;var ret=[tinycolor(color)];for(hsl.h=(hsl.h-(part*results>>1)+720)%360;--results;){hsl.h=(hsl.h+part)%360;ret.push(tinycolor(hsl))}return ret}function monochromatic(color,results){results=results||6;var hsv=tinycolor(color).toHsv();var h=hsv.h,s=hsv.s,v=hsv.v;var ret=[];var modification=1/results;while(results--){ret.push(tinycolor({h:h,s:s,v:v}));v=(v+modification)%1}return ret}tinycolor.mix=function(color1,color2,amount){amount=amount===0?0:amount||50;var rgb1=tinycolor(color1).toRgb();var rgb2=tinycolor(color2).toRgb();var p=amount/100;var w=p*2-1;var a=rgb2.a-rgb1.a;var w1;if(w*a==-1){w1=w}else{w1=(w+a)/(1+w*a)}w1=(w1+1)/2;var w2=1-w1;var rgba={r:rgb2.r*w1+rgb1.r*w2,g:rgb2.g*w1+rgb1.g*w2,b:rgb2.b*w1+rgb1.b*w2,a:rgb2.a*p+rgb1.a*(1-p)};return tinycolor(rgba)};tinycolor.readability=function(color1,color2){var c1=tinycolor(color1);var c2=tinycolor(color2);var rgb1=c1.toRgb();var rgb2=c2.toRgb();var brightnessA=c1.getBrightness();var brightnessB=c2.getBrightness();var colorDiff=Math.max(rgb1.r,rgb2.r)-Math.min(rgb1.r,rgb2.r)+Math.max(rgb1.g,rgb2.g)-Math.min(rgb1.g,rgb2.g)+Math.max(rgb1.b,rgb2.b)-Math.min(rgb1.b,rgb2.b);return{brightness:Math.abs(brightnessA-brightnessB),color:colorDiff}};tinycolor.isReadable=function(color1,color2){var readability=tinycolor.readability(color1,color2);return readability.brightness>125&&readability.color>500};tinycolor.mostReadable=function(baseColor,colorList){var bestColor=null;var bestScore=0;var bestIsReadable=false;for(var i=0;i<colorList.length;i++){var readability=tinycolor.readability(baseColor,colorList[i]);var readable=readability.brightness>125&&readability.color>500;var score=3*(readability.brightness/125)+readability.color/500;if(readable&&!bestIsReadable||readable&&bestIsReadable&&score>bestScore||!readable&&!bestIsReadable&&score>bestScore){bestIsReadable=readable;bestScore=score;bestColor=tinycolor(colorList[i])}}return bestColor};var names=tinycolor.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};var hexNames=tinycolor.hexNames=flip(names);function flip(o){var flipped={};for(var i in o){if(o.hasOwnProperty(i)){flipped[o[i]]=i}}return flipped}function boundAlpha(a){a=parseFloat(a);if(isNaN(a)||a<0||a>1){a=1}return a}function bound01(n,max){if(isOnePointZero(n)){n="100%"}var processPercent=isPercentage(n);n=mathMin(max,mathMax(0,parseFloat(n)));if(processPercent){n=parseInt(n*max,10)/100}if(math.abs(n-max)<1e-6){return 1}return n%max/parseFloat(max)}function clamp01(val){return mathMin(1,mathMax(0,val))}function parseIntFromHex(val){return parseInt(val,16)}function isOnePointZero(n){return typeof n=="string"&&n.indexOf(".")!=-1&&parseFloat(n)===1}function isPercentage(n){return typeof n==="string"&&n.indexOf("%")!=-1}function pad2(c){return c.length==1?"0"+c:""+c}function convertToPercentage(n){if(n<=1){n=n*100+"%"}return n}function convertDecimalToHex(d){return Math.round(parseFloat(d)*255).toString(16)}function convertHexToDecimal(h){return parseIntFromHex(h)/255}var matchers=function(){var CSS_INTEGER="[-\\+]?\\d+%?";var CSS_NUMBER="[-\\+]?\\d*\\.\\d+%?";var CSS_UNIT="(?:"+CSS_NUMBER+")|(?:"+CSS_INTEGER+")";var PERMISSIVE_MATCH3="[\\s|\\(]+("+CSS_UNIT+")[,|\\s]+("+CSS_UNIT+")[,|\\s]+("+CSS_UNIT+")\\s*\\)?";var PERMISSIVE_MATCH4="[\\s|\\(]+("+CSS_UNIT+")[,|\\s]+("+CSS_UNIT+")[,|\\s]+("+CSS_UNIT+")[,|\\s]+("+CSS_UNIT+")\\s*\\)?";return{rgb:new RegExp("rgb"+PERMISSIVE_MATCH3),rgba:new RegExp("rgba"+PERMISSIVE_MATCH4),hsl:new RegExp("hsl"+PERMISSIVE_MATCH3),hsla:new RegExp("hsla"+PERMISSIVE_MATCH4),hsv:new RegExp("hsv"+PERMISSIVE_MATCH3),hsva:new RegExp("hsva"+PERMISSIVE_MATCH4),hex3:/^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex8:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function stringInputToObject(color){color=color.replace(trimLeft,"").replace(trimRight,"").toLowerCase();var named=false;if(names[color]){color=names[color];named=true}else if(color=="transparent"){return{r:0,g:0,b:0,a:0,format:"name"}}var match;if(match=matchers.rgb.exec(color)){return{r:match[1],g:match[2],b:match[3]}}if(match=matchers.rgba.exec(color)){return{r:match[1],g:match[2],b:match[3],a:match[4]}}if(match=matchers.hsl.exec(color)){return{h:match[1],s:match[2],l:match[3]}}if(match=matchers.hsla.exec(color)){return{h:match[1],s:match[2],l:match[3],a:match[4]}}if(match=matchers.hsv.exec(color)){return{h:match[1],s:match[2],v:match[3]}}if(match=matchers.hsva.exec(color)){return{h:match[1],s:match[2],v:match[3],a:match[4]}}if(match=matchers.hex8.exec(color)){return{a:convertHexToDecimal(match[1]),r:parseIntFromHex(match[2]),g:parseIntFromHex(match[3]),b:parseIntFromHex(match[4]),format:named?"name":"hex8"}}if(match=matchers.hex6.exec(color)){return{r:parseIntFromHex(match[1]),g:parseIntFromHex(match[2]),b:parseIntFromHex(match[3]),format:named?"name":"hex"}}if(match=matchers.hex3.exec(color)){return{r:parseIntFromHex(match[1]+""+match[1]),g:parseIntFromHex(match[2]+""+match[2]),b:parseIntFromHex(match[3]+""+match[3]),format:named?"name":"hex"}}return false}window.tinycolor=tinycolor})();$(function(){if($.fn.spectrum.load){$.fn.spectrum.processNativeColorInputs()}})});
folders.php CHANGED
@@ -2,7 +2,7 @@
2
  /**
3
  * Plugin Name: Folders
4
  * Description: Arrange media, pages, custom post types and posts into folders
5
- * Version: 2.3.1
6
  * Author: Premio
7
  * Author URI: https://premio.io/downloads/folders/
8
  */
@@ -15,7 +15,7 @@ define('WCP_FOLDER', 'folders');
15
  define('WCP_FOLDER_VAR', 'folders_settings');
16
  define("WCP_DS", DIRECTORY_SEPARATOR);
17
  define('WCP_FOLDER_URL',plugin_dir_url(__FILE__));
18
- define('WCP_FOLDER_VERSION',"2.3.1");
19
 
20
  include_once plugin_dir_path(__FILE__)."includes/folders.class.php";
21
  register_activation_hook( __FILE__, array( 'WCP_Folders', 'activate' ) );
2
  /**
3
  * Plugin Name: Folders
4
  * Description: Arrange media, pages, custom post types and posts into folders
5
+ * Version: 2.3.2
6
  * Author: Premio
7
  * Author URI: https://premio.io/downloads/folders/
8
  */
15
  define('WCP_FOLDER_VAR', 'folders_settings');
16
  define("WCP_DS", DIRECTORY_SEPARATOR);
17
  define('WCP_FOLDER_URL',plugin_dir_url(__FILE__));
18
+ define('WCP_FOLDER_VERSION',"2.3.2");
19
 
20
  include_once plugin_dir_path(__FILE__)."includes/folders.class.php";
21
  register_activation_hook( __FILE__, array( 'WCP_Folders', 'activate' ) );
includes/class-affiliate.php CHANGED
@@ -126,7 +126,7 @@ class Folder_affiliate_program {
126
  }
127
  </style>
128
  <div class="notice notice-info chaty-notice <?php echo $this->plugin_slug ?>-premio-affiliate <?php echo $this->plugin_slug ?>-premio-affiliate">
129
- <p>Hi there, you've been using <?php echo $this->plugin_name ?> for a while now. Do you know that <b><?php echo $this->plugin_name ?></b> has an affiliate program? Join now and get 25% lifetime commission <a href="javascript:;" class="dismiss-btn"><span class="dashicons dashicons-no-alt"></span> Dismiss</a></p>
130
  <div class="clear clearfix"></div>
131
  <a class="button button-primary <?php echo $this->plugin_slug ?>-affiliate-btn" target="_blank" href="https://premio.io/affiliates/?utm_source=inapp&plugin=folders&domain=<?php echo $_SERVER['HTTP_HOST'] ?>">Tell me more <span class="dashicons dashicons-arrow-right-alt"></span></a>
132
  </div>
126
  }
127
  </style>
128
  <div class="notice notice-info chaty-notice <?php echo $this->plugin_slug ?>-premio-affiliate <?php echo $this->plugin_slug ?>-premio-affiliate">
129
+ <p>Hi there, you've been using <?php echo $this->plugin_name ?> for a while now. Do you know that <b><?php echo $this->plugin_name ?></b> has an affiliate program? Join now and get <b>25% lifetime commission</b> <a href="javascript:;" class="dismiss-btn"><span class="dashicons dashicons-no-alt"></span> Dismiss</a></p>
130
  <div class="clear clearfix"></div>
131
  <a class="button button-primary <?php echo $this->plugin_slug ?>-affiliate-btn" target="_blank" href="https://premio.io/affiliates/?utm_source=inapp&plugin=folders&domain=<?php echo $_SERVER['HTTP_HOST'] ?>">Tell me more <span class="dashicons dashicons-arrow-right-alt"></span></a>
132
  </div>
includes/folders.class.php CHANGED
@@ -25,6 +25,7 @@ class WCP_Folders
25
  add_filter('plugin_action_links_' . WCP_FOLDERS_PLUGIN_BASE, [$this, 'plugin_action_links']);
26
  add_action('admin_footer', array($this, 'admin_footer'));
27
  add_action('parse_tax_query', array($this, 'taxonomy_archive_exclude_children'));
 
28
 
29
  /* Save Data */
30
  add_action('wp_ajax_wcp_add_new_folder', array($this, 'wcp_add_new_folder'));
@@ -109,6 +110,21 @@ class WCP_Folders
109
  add_action("wp_ajax_folder_update_status", array($this, 'folder_update_status'));
110
  }
111
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
112
  public function check_for_default_folders() {
113
  global $typenow, $current_screen;
114
  $isAjax = (defined('DOING_AJAX') && DOING_AJAX)?1:0;
@@ -1677,9 +1693,14 @@ class WCP_Folders
1677
  'operator' => 'NOT EXISTS',
1678
  ),
1679
  );
 
1680
  $result = get_posts($args);
1681
 
1682
- return (count($result));
 
 
 
 
1683
  }
1684
 
1685
  public function autoload()
@@ -2122,6 +2143,7 @@ class WCP_Folders
2122
  {
2123
  register_setting('folders_settings', 'folders_settings1', 'folders_settings_validate');
2124
  register_setting('default_folders', 'default_folders');
 
2125
 
2126
  self::check_and_set_post_type();
2127
 
@@ -2135,6 +2157,930 @@ class WCP_Folders
2135
  }
2136
  }
2137
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2138
  function wcp_manage_columns_head($defaults, $d = "")
2139
  {
2140
  global $typenow;
@@ -2259,7 +3205,7 @@ class WCP_Folders
2259
  $terms_data[$post_type->name] = array();
2260
  }
2261
  }
2262
-
2263
  include_once dirname(dirname(__FILE__)) . "/templates/admin/general-settings.php";
2264
  }
2265
 
25
  add_filter('plugin_action_links_' . WCP_FOLDERS_PLUGIN_BASE, [$this, 'plugin_action_links']);
26
  add_action('admin_footer', array($this, 'admin_footer'));
27
  add_action('parse_tax_query', array($this, 'taxonomy_archive_exclude_children'));
28
+ add_action('admin_footer', array($this, 'admin_footer_for_media'));
29
 
30
  /* Save Data */
31
  add_action('wp_ajax_wcp_add_new_folder', array($this, 'wcp_add_new_folder'));
110
  add_action("wp_ajax_folder_update_status", array($this, 'folder_update_status'));
111
  }
112
 
113
+ public function admin_footer_for_media(){
114
+ echo "<style>";
115
+ $customize_folders = get_option('customize_folders');
116
+ if(isset($customize_folders['dropdown_color']) && !empty($customize_folders['dropdown_color'])) {
117
+ ?>
118
+ #media-attachment-taxonomy-filter, .post-upload-ui .folder_for_media { border-color: <?php echo esc_attr($customize_folders['dropdown_color']) ?>; color: <?php echo esc_attr($customize_folders['dropdown_color']) ?> }
119
+ .folder_for_media option {color:#000000;}
120
+ .folder_for_media option:first-child {
121
+ font-weight: bold;
122
+ }
123
+ <?php
124
+ }
125
+ echo "</style>";
126
+ }
127
+
128
  public function check_for_default_folders() {
129
  global $typenow, $current_screen;
130
  $isAjax = (defined('DOING_AJAX') && DOING_AJAX)?1:0;
1693
  'operator' => 'NOT EXISTS',
1694
  ),
1695
  );
1696
+
1697
  $result = get_posts($args);
1698
 
1699
+ if(!empty($result)) {
1700
+ return (count($result));
1701
+ } else {
1702
+ return 0;
1703
+ }
1704
  }
1705
 
1706
  public function autoload()
2143
  {
2144
  register_setting('folders_settings', 'folders_settings1', 'folders_settings_validate');
2145
  register_setting('default_folders', 'default_folders');
2146
+ register_setting('customize_folders', 'customize_folders');
2147
 
2148
  self::check_and_set_post_type();
2149
 
2157
  }
2158
  }
2159
 
2160
+ public static function get_font_list(){
2161
+ return array(
2162
+ // System fonts.
2163
+ '-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif;' => 'Default',
2164
+ 'Arial' => 'Default',
2165
+ 'Tahoma' => 'Default',
2166
+ 'Verdana' => 'Default',
2167
+ 'Helvetica' => 'Default',
2168
+ 'Times New Roman' => 'Default',
2169
+ 'Trebuchet MS' => 'Default',
2170
+ 'Georgia' => 'Default',
2171
+
2172
+ // Google Fonts (last update: 23/10/2018).
2173
+ 'ABeeZee' => 'Google Fonts',
2174
+ 'Abel' => 'Google Fonts',
2175
+ 'Abhaya Libre' => 'Google Fonts',
2176
+ 'Abril Fatface' => 'Google Fonts',
2177
+ 'Aclonica' => 'Google Fonts',
2178
+ 'Acme' => 'Google Fonts',
2179
+ 'Actor' => 'Google Fonts',
2180
+ 'Adamina' => 'Google Fonts',
2181
+ 'Advent Pro' => 'Google Fonts',
2182
+ 'Aguafina Script' => 'Google Fonts',
2183
+ 'Akronim' => 'Google Fonts',
2184
+ 'Aladin' => 'Google Fonts',
2185
+ 'Aldrich' => 'Google Fonts',
2186
+ 'Alef' => 'Google Fonts',
2187
+ 'Alef Hebrew' => 'Google Fonts', // Hack for Google Early Access.
2188
+ 'Alegreya' => 'Google Fonts',
2189
+ 'Alegreya SC' => 'Google Fonts',
2190
+ 'Alegreya Sans' => 'Google Fonts',
2191
+ 'Alegreya Sans SC' => 'Google Fonts',
2192
+ 'Alex Brush' => 'Google Fonts',
2193
+ 'Alfa Slab One' => 'Google Fonts',
2194
+ 'Alice' => 'Google Fonts',
2195
+ 'Alike' => 'Google Fonts',
2196
+ 'Alike Angular' => 'Google Fonts',
2197
+ 'Allan' => 'Google Fonts',
2198
+ 'Allerta' => 'Google Fonts',
2199
+ 'Allerta Stencil' => 'Google Fonts',
2200
+ 'Allura' => 'Google Fonts',
2201
+ 'Almendra' => 'Google Fonts',
2202
+ 'Almendra Display' => 'Google Fonts',
2203
+ 'Almendra SC' => 'Google Fonts',
2204
+ 'Amarante' => 'Google Fonts',
2205
+ 'Amaranth' => 'Google Fonts',
2206
+ 'Amatic SC' => 'Google Fonts',
2207
+ 'Amethysta' => 'Google Fonts',
2208
+ 'Amiko' => 'Google Fonts',
2209
+ 'Amiri' => 'Google Fonts',
2210
+ 'Amita' => 'Google Fonts',
2211
+ 'Anaheim' => 'Google Fonts',
2212
+ 'Andada' => 'Google Fonts',
2213
+ 'Andika' => 'Google Fonts',
2214
+ 'Angkor' => 'Google Fonts',
2215
+ 'Annie Use Your Telescope' => 'Google Fonts',
2216
+ 'Anonymous Pro' => 'Google Fonts',
2217
+ 'Antic' => 'Google Fonts',
2218
+ 'Antic Didone' => 'Google Fonts',
2219
+ 'Antic Slab' => 'Google Fonts',
2220
+ 'Anton' => 'Google Fonts',
2221
+ 'Arapey' => 'Google Fonts',
2222
+ 'Arbutus' => 'Google Fonts',
2223
+ 'Arbutus Slab' => 'Google Fonts',
2224
+ 'Architects Daughter' => 'Google Fonts',
2225
+ 'Archivo' => 'Google Fonts',
2226
+ 'Archivo Black' => 'Google Fonts',
2227
+ 'Archivo Narrow' => 'Google Fonts',
2228
+ 'Aref Ruqaa' => 'Google Fonts',
2229
+ 'Arima Madurai' => 'Google Fonts',
2230
+ 'Arimo' => 'Google Fonts',
2231
+ 'Arizonia' => 'Google Fonts',
2232
+ 'Armata' => 'Google Fonts',
2233
+ 'Arsenal' => 'Google Fonts',
2234
+ 'Artifika' => 'Google Fonts',
2235
+ 'Arvo' => 'Google Fonts',
2236
+ 'Arya' => 'Google Fonts',
2237
+ 'Asap' => 'Google Fonts',
2238
+ 'Asap Condensed' => 'Google Fonts',
2239
+ 'Asar' => 'Google Fonts',
2240
+ 'Asset' => 'Google Fonts',
2241
+ 'Assistant' => 'Google Fonts',
2242
+ 'Astloch' => 'Google Fonts',
2243
+ 'Asul' => 'Google Fonts',
2244
+ 'Athiti' => 'Google Fonts',
2245
+ 'Atma' => 'Google Fonts',
2246
+ 'Atomic Age' => 'Google Fonts',
2247
+ 'Aubrey' => 'Google Fonts',
2248
+ 'Audiowide' => 'Google Fonts',
2249
+ 'Autour One' => 'Google Fonts',
2250
+ 'Average' => 'Google Fonts',
2251
+ 'Average Sans' => 'Google Fonts',
2252
+ 'Averia Gruesa Libre' => 'Google Fonts',
2253
+ 'Averia Libre' => 'Google Fonts',
2254
+ 'Averia Sans Libre' => 'Google Fonts',
2255
+ 'Averia Serif Libre' => 'Google Fonts',
2256
+ 'Bad Script' => 'Google Fonts',
2257
+ 'Bahiana' => 'Google Fonts',
2258
+ 'Bai Jamjuree' => 'Google Fonts',
2259
+ 'Baloo' => 'Google Fonts',
2260
+ 'Baloo Bhai' => 'Google Fonts',
2261
+ 'Baloo Bhaijaan' => 'Google Fonts',
2262
+ 'Baloo Bhaina' => 'Google Fonts',
2263
+ 'Baloo Chettan' => 'Google Fonts',
2264
+ 'Baloo Da' => 'Google Fonts',
2265
+ 'Baloo Paaji' => 'Google Fonts',
2266
+ 'Baloo Tamma' => 'Google Fonts',
2267
+ 'Baloo Tammudu' => 'Google Fonts',
2268
+ 'Baloo Thambi' => 'Google Fonts',
2269
+ 'Balthazar' => 'Google Fonts',
2270
+ 'Bangers' => 'Google Fonts',
2271
+ 'Barlow' => 'Google Fonts',
2272
+ 'Barlow Condensed' => 'Google Fonts',
2273
+ 'Barlow Semi Condensed' => 'Google Fonts',
2274
+ 'Barrio' => 'Google Fonts',
2275
+ 'Basic' => 'Google Fonts',
2276
+ 'Battambang' => 'Google Fonts',
2277
+ 'Baumans' => 'Google Fonts',
2278
+ 'Bayon' => 'Google Fonts',
2279
+ 'Belgrano' => 'Google Fonts',
2280
+ 'Bellefair' => 'Google Fonts',
2281
+ 'Belleza' => 'Google Fonts',
2282
+ 'BenchNine' => 'Google Fonts',
2283
+ 'Bentham' => 'Google Fonts',
2284
+ 'Berkshire Swash' => 'Google Fonts',
2285
+ 'Bevan' => 'Google Fonts',
2286
+ 'Bigelow Rules' => 'Google Fonts',
2287
+ 'Bigshot One' => 'Google Fonts',
2288
+ 'Bilbo' => 'Google Fonts',
2289
+ 'Bilbo Swash Caps' => 'Google Fonts',
2290
+ 'BioRhyme' => 'Google Fonts',
2291
+ 'BioRhyme Expanded' => 'Google Fonts',
2292
+ 'Biryani' => 'Google Fonts',
2293
+ 'Bitter' => 'Google Fonts',
2294
+ 'Black And White Picture' => 'Google Fonts',
2295
+ 'Black Han Sans' => 'Google Fonts',
2296
+ 'Black Ops One' => 'Google Fonts',
2297
+ 'Bokor' => 'Google Fonts',
2298
+ 'Bonbon' => 'Google Fonts',
2299
+ 'Boogaloo' => 'Google Fonts',
2300
+ 'Bowlby One' => 'Google Fonts',
2301
+ 'Bowlby One SC' => 'Google Fonts',
2302
+ 'Brawler' => 'Google Fonts',
2303
+ 'Bree Serif' => 'Google Fonts',
2304
+ 'Bubblegum Sans' => 'Google Fonts',
2305
+ 'Bubbler One' => 'Google Fonts',
2306
+ 'Buda' => 'Google Fonts',
2307
+ 'Buenard' => 'Google Fonts',
2308
+ 'Bungee' => 'Google Fonts',
2309
+ 'Bungee Hairline' => 'Google Fonts',
2310
+ 'Bungee Inline' => 'Google Fonts',
2311
+ 'Bungee Outline' => 'Google Fonts',
2312
+ 'Bungee Shade' => 'Google Fonts',
2313
+ 'Butcherman' => 'Google Fonts',
2314
+ 'Butterfly Kids' => 'Google Fonts',
2315
+ 'Cabin' => 'Google Fonts',
2316
+ 'Cabin Condensed' => 'Google Fonts',
2317
+ 'Cabin Sketch' => 'Google Fonts',
2318
+ 'Caesar Dressing' => 'Google Fonts',
2319
+ 'Cagliostro' => 'Google Fonts',
2320
+ 'Cairo' => 'Google Fonts',
2321
+ 'Calligraffitti' => 'Google Fonts',
2322
+ 'Cambay' => 'Google Fonts',
2323
+ 'Cambo' => 'Google Fonts',
2324
+ 'Candal' => 'Google Fonts',
2325
+ 'Cantarell' => 'Google Fonts',
2326
+ 'Cantata One' => 'Google Fonts',
2327
+ 'Cantora One' => 'Google Fonts',
2328
+ 'Capriola' => 'Google Fonts',
2329
+ 'Cardo' => 'Google Fonts',
2330
+ 'Carme' => 'Google Fonts',
2331
+ 'Carrois Gothic' => 'Google Fonts',
2332
+ 'Carrois Gothic SC' => 'Google Fonts',
2333
+ 'Carter One' => 'Google Fonts',
2334
+ 'Catamaran' => 'Google Fonts',
2335
+ 'Caudex' => 'Google Fonts',
2336
+ 'Caveat' => 'Google Fonts',
2337
+ 'Caveat Brush' => 'Google Fonts',
2338
+ 'Cedarville Cursive' => 'Google Fonts',
2339
+ 'Ceviche One' => 'Google Fonts',
2340
+ 'Chakra Petch' => 'Google Fonts',
2341
+ 'Changa' => 'Google Fonts',
2342
+ 'Changa One' => 'Google Fonts',
2343
+ 'Chango' => 'Google Fonts',
2344
+ 'Charmonman' => 'Google Fonts',
2345
+ 'Chathura' => 'Google Fonts',
2346
+ 'Chau Philomene One' => 'Google Fonts',
2347
+ 'Chela One' => 'Google Fonts',
2348
+ 'Chelsea Market' => 'Google Fonts',
2349
+ 'Chenla' => 'Google Fonts',
2350
+ 'Cherry Cream Soda' => 'Google Fonts',
2351
+ 'Cherry Swash' => 'Google Fonts',
2352
+ 'Chewy' => 'Google Fonts',
2353
+ 'Chicle' => 'Google Fonts',
2354
+ 'Chivo' => 'Google Fonts',
2355
+ 'Chonburi' => 'Google Fonts',
2356
+ 'Cinzel' => 'Google Fonts',
2357
+ 'Cinzel Decorative' => 'Google Fonts',
2358
+ 'Clicker Script' => 'Google Fonts',
2359
+ 'Coda' => 'Google Fonts',
2360
+ 'Coda Caption' => 'Google Fonts',
2361
+ 'Codystar' => 'Google Fonts',
2362
+ 'Coiny' => 'Google Fonts',
2363
+ 'Combo' => 'Google Fonts',
2364
+ 'Comfortaa' => 'Google Fonts',
2365
+ 'Coming Soon' => 'Google Fonts',
2366
+ 'Concert One' => 'Google Fonts',
2367
+ 'Condiment' => 'Google Fonts',
2368
+ 'Content' => 'Google Fonts',
2369
+ 'Contrail One' => 'Google Fonts',
2370
+ 'Convergence' => 'Google Fonts',
2371
+ 'Cookie' => 'Google Fonts',
2372
+ 'Copse' => 'Google Fonts',
2373
+ 'Corben' => 'Google Fonts',
2374
+ 'Cormorant' => 'Google Fonts',
2375
+ 'Cormorant Garamond' => 'Google Fonts',
2376
+ 'Cormorant Infant' => 'Google Fonts',
2377
+ 'Cormorant SC' => 'Google Fonts',
2378
+ 'Cormorant Unicase' => 'Google Fonts',
2379
+ 'Cormorant Upright' => 'Google Fonts',
2380
+ 'Courgette' => 'Google Fonts',
2381
+ 'Cousine' => 'Google Fonts',
2382
+ 'Coustard' => 'Google Fonts',
2383
+ 'Covered By Your Grace' => 'Google Fonts',
2384
+ 'Crafty Girls' => 'Google Fonts',
2385
+ 'Creepster' => 'Google Fonts',
2386
+ 'Crete Round' => 'Google Fonts',
2387
+ 'Crimson Text' => 'Google Fonts',
2388
+ 'Croissant One' => 'Google Fonts',
2389
+ 'Crushed' => 'Google Fonts',
2390
+ 'Cuprum' => 'Google Fonts',
2391
+ 'Cute Font' => 'Google Fonts',
2392
+ 'Cutive' => 'Google Fonts',
2393
+ 'Cutive Mono' => 'Google Fonts',
2394
+ 'Damion' => 'Google Fonts',
2395
+ 'Dancing Script' => 'Google Fonts',
2396
+ 'Dangrek' => 'Google Fonts',
2397
+ 'David Libre' => 'Google Fonts',
2398
+ 'Dawning of a New Day' => 'Google Fonts',
2399
+ 'Days One' => 'Google Fonts',
2400
+ 'Dekko' => 'Google Fonts',
2401
+ 'Delius' => 'Google Fonts',
2402
+ 'Delius Swash Caps' => 'Google Fonts',
2403
+ 'Delius Unicase' => 'Google Fonts',
2404
+ 'Della Respira' => 'Google Fonts',
2405
+ 'Denk One' => 'Google Fonts',
2406
+ 'Devonshire' => 'Google Fonts',
2407
+ 'Dhurjati' => 'Google Fonts',
2408
+ 'Didact Gothic' => 'Google Fonts',
2409
+ 'Diplomata' => 'Google Fonts',
2410
+ 'Diplomata SC' => 'Google Fonts',
2411
+ 'Do Hyeon' => 'Google Fonts',
2412
+ 'Dokdo' => 'Google Fonts',
2413
+ 'Domine' => 'Google Fonts',
2414
+ 'Donegal One' => 'Google Fonts',
2415
+ 'Doppio One' => 'Google Fonts',
2416
+ 'Dorsa' => 'Google Fonts',
2417
+ 'Dosis' => 'Google Fonts',
2418
+ 'Dr Sugiyama' => 'Google Fonts',
2419
+ 'Droid Arabic Kufi' => 'Google Fonts', // Hack for Google Early Access.
2420
+ 'Droid Arabic Naskh' => 'Google Fonts', // Hack for Google Early Access.
2421
+ 'Duru Sans' => 'Google Fonts',
2422
+ 'Dynalight' => 'Google Fonts',
2423
+ 'EB Garamond' => 'Google Fonts',
2424
+ 'Eagle Lake' => 'Google Fonts',
2425
+ 'East Sea Dokdo' => 'Google Fonts',
2426
+ 'Eater' => 'Google Fonts',
2427
+ 'Economica' => 'Google Fonts',
2428
+ 'Eczar' => 'Google Fonts',
2429
+ 'El Messiri' => 'Google Fonts',
2430
+ 'Electrolize' => 'Google Fonts',
2431
+ 'Elsie' => 'Google Fonts',
2432
+ 'Elsie Swash Caps' => 'Google Fonts',
2433
+ 'Emblema One' => 'Google Fonts',
2434
+ 'Emilys Candy' => 'Google Fonts',
2435
+ 'Encode Sans' => 'Google Fonts',
2436
+ 'Encode Sans Condensed' => 'Google Fonts',
2437
+ 'Encode Sans Expanded' => 'Google Fonts',
2438
+ 'Encode Sans Semi Condensed' => 'Google Fonts',
2439
+ 'Encode Sans Semi Expanded' => 'Google Fonts',
2440
+ 'Engagement' => 'Google Fonts',
2441
+ 'Englebert' => 'Google Fonts',
2442
+ 'Enriqueta' => 'Google Fonts',
2443
+ 'Erica One' => 'Google Fonts',
2444
+ 'Esteban' => 'Google Fonts',
2445
+ 'Euphoria Script' => 'Google Fonts',
2446
+ 'Ewert' => 'Google Fonts',
2447
+ 'Exo' => 'Google Fonts',
2448
+ 'Exo 2' => 'Google Fonts',
2449
+ 'Expletus Sans' => 'Google Fonts',
2450
+ 'Fahkwang' => 'Google Fonts',
2451
+ 'Fanwood Text' => 'Google Fonts',
2452
+ 'Farsan' => 'Google Fonts',
2453
+ 'Fascinate' => 'Google Fonts',
2454
+ 'Fascinate Inline' => 'Google Fonts',
2455
+ 'Faster One' => 'Google Fonts',
2456
+ 'Fasthand' => 'Google Fonts',
2457
+ 'Fauna One' => 'Google Fonts',
2458
+ 'Faustina' => 'Google Fonts',
2459
+ 'Federant' => 'Google Fonts',
2460
+ 'Federo' => 'Google Fonts',
2461
+ 'Felipa' => 'Google Fonts',
2462
+ 'Fenix' => 'Google Fonts',
2463
+ 'Finger Paint' => 'Google Fonts',
2464
+ 'Fira Mono' => 'Google Fonts',
2465
+ 'Fira Sans' => 'Google Fonts',
2466
+ 'Fira Sans Condensed' => 'Google Fonts',
2467
+ 'Fira Sans Extra Condensed' => 'Google Fonts',
2468
+ 'Fjalla One' => 'Google Fonts',
2469
+ 'Fjord One' => 'Google Fonts',
2470
+ 'Flamenco' => 'Google Fonts',
2471
+ 'Flavors' => 'Google Fonts',
2472
+ 'Fondamento' => 'Google Fonts',
2473
+ 'Fontdiner Swanky' => 'Google Fonts',
2474
+ 'Forum' => 'Google Fonts',
2475
+ 'Francois One' => 'Google Fonts',
2476
+ 'Frank Ruhl Libre' => 'Google Fonts',
2477
+ 'Freckle Face' => 'Google Fonts',
2478
+ 'Fredericka the Great' => 'Google Fonts',
2479
+ 'Fredoka One' => 'Google Fonts',
2480
+ 'Freehand' => 'Google Fonts',
2481
+ 'Fresca' => 'Google Fonts',
2482
+ 'Frijole' => 'Google Fonts',
2483
+ 'Fruktur' => 'Google Fonts',
2484
+ 'Fugaz One' => 'Google Fonts',
2485
+ 'GFS Didot' => 'Google Fonts',
2486
+ 'GFS Neohellenic' => 'Google Fonts',
2487
+ 'Gabriela' => 'Google Fonts',
2488
+ 'Gaegu' => 'Google Fonts',
2489
+ 'Gafata' => 'Google Fonts',
2490
+ 'Galada' => 'Google Fonts',
2491
+ 'Galdeano' => 'Google Fonts',
2492
+ 'Galindo' => 'Google Fonts',
2493
+ 'Gamja Flower' => 'Google Fonts',
2494
+ 'Gentium Basic' => 'Google Fonts',
2495
+ 'Gentium Book Basic' => 'Google Fonts',
2496
+ 'Geo' => 'Google Fonts',
2497
+ 'Geostar' => 'Google Fonts',
2498
+ 'Geostar Fill' => 'Google Fonts',
2499
+ 'Germania One' => 'Google Fonts',
2500
+ 'Gidugu' => 'Google Fonts',
2501
+ 'Gilda Display' => 'Google Fonts',
2502
+ 'Give You Glory' => 'Google Fonts',
2503
+ 'Glass Antiqua' => 'Google Fonts',
2504
+ 'Glegoo' => 'Google Fonts',
2505
+ 'Gloria Hallelujah' => 'Google Fonts',
2506
+ 'Goblin One' => 'Google Fonts',
2507
+ 'Gochi Hand' => 'Google Fonts',
2508
+ 'Gorditas' => 'Google Fonts',
2509
+ 'Gothic A1' => 'Google Fonts',
2510
+ 'Goudy Bookletter 1911' => 'Google Fonts',
2511
+ 'Graduate' => 'Google Fonts',
2512
+ 'Grand Hotel' => 'Google Fonts',
2513
+ 'Gravitas One' => 'Google Fonts',
2514
+ 'Great Vibes' => 'Google Fonts',
2515
+ 'Griffy' => 'Google Fonts',
2516
+ 'Gruppo' => 'Google Fonts',
2517
+ 'Gudea' => 'Google Fonts',
2518
+ 'Gugi' => 'Google Fonts',
2519
+ 'Gurajada' => 'Google Fonts',
2520
+ 'Habibi' => 'Google Fonts',
2521
+ 'Halant' => 'Google Fonts',
2522
+ 'Hammersmith One' => 'Google Fonts',
2523
+ 'Hanalei' => 'Google Fonts',
2524
+ 'Hanalei Fill' => 'Google Fonts',
2525
+ 'Handlee' => 'Google Fonts',
2526
+ 'Hanuman' => 'Google Fonts',
2527
+ 'Happy Monkey' => 'Google Fonts',
2528
+ 'Harmattan' => 'Google Fonts',
2529
+ 'Headland One' => 'Google Fonts',
2530
+ 'Heebo' => 'Google Fonts',
2531
+ 'Henny Penny' => 'Google Fonts',
2532
+ 'Herr Von Muellerhoff' => 'Google Fonts',
2533
+ 'Hi Melody' => 'Google Fonts',
2534
+ 'Hind' => 'Google Fonts',
2535
+ 'Hind Guntur' => 'Google Fonts',
2536
+ 'Hind Madurai' => 'Google Fonts',
2537
+ 'Hind Siliguri' => 'Google Fonts',
2538
+ 'Hind Vadodara' => 'Google Fonts',
2539
+ 'Holtwood One SC' => 'Google Fonts',
2540
+ 'Homemade Apple' => 'Google Fonts',
2541
+ 'Homenaje' => 'Google Fonts',
2542
+ 'IBM Plex Mono' => 'Google Fonts',
2543
+ 'IBM Plex Sans' => 'Google Fonts',
2544
+ 'IBM Plex Sans Condensed' => 'Google Fonts',
2545
+ 'IBM Plex Serif' => 'Google Fonts',
2546
+ 'IM Fell DW Pica' => 'Google Fonts',
2547
+ 'IM Fell DW Pica SC' => 'Google Fonts',
2548
+ 'IM Fell Double Pica' => 'Google Fonts',
2549
+ 'IM Fell Double Pica SC' => 'Google Fonts',
2550
+ 'IM Fell English' => 'Google Fonts',
2551
+ 'IM Fell English SC' => 'Google Fonts',
2552
+ 'IM Fell French Canon' => 'Google Fonts',
2553
+ 'IM Fell French Canon SC' => 'Google Fonts',
2554
+ 'IM Fell Great Primer' => 'Google Fonts',
2555
+ 'IM Fell Great Primer SC' => 'Google Fonts',
2556
+ 'Iceberg' => 'Google Fonts',
2557
+ 'Iceland' => 'Google Fonts',
2558
+ 'Imprima' => 'Google Fonts',
2559
+ 'Inconsolata' => 'Google Fonts',
2560
+ 'Inder' => 'Google Fonts',
2561
+ 'Indie Flower' => 'Google Fonts',
2562
+ 'Inika' => 'Google Fonts',
2563
+ 'Inknut Antiqua' => 'Google Fonts',
2564
+ 'Irish Grover' => 'Google Fonts',
2565
+ 'Istok Web' => 'Google Fonts',
2566
+ 'Italiana' => 'Google Fonts',
2567
+ 'Italianno' => 'Google Fonts',
2568
+ 'Itim' => 'Google Fonts',
2569
+ 'Jacques Francois' => 'Google Fonts',
2570
+ 'Jacques Francois Shadow' => 'Google Fonts',
2571
+ 'Jaldi' => 'Google Fonts',
2572
+ 'Jim Nightshade' => 'Google Fonts',
2573
+ 'Jockey One' => 'Google Fonts',
2574
+ 'Jolly Lodger' => 'Google Fonts',
2575
+ 'Jomhuria' => 'Google Fonts',
2576
+ 'Josefin Sans' => 'Google Fonts',
2577
+ 'Josefin Slab' => 'Google Fonts',
2578
+ 'Joti One' => 'Google Fonts',
2579
+ 'Jua' => 'Google Fonts',
2580
+ 'Judson' => 'Google Fonts',
2581
+ 'Julee' => 'Google Fonts',
2582
+ 'Julius Sans One' => 'Google Fonts',
2583
+ 'Junge' => 'Google Fonts',
2584
+ 'Jura' => 'Google Fonts',
2585
+ 'Just Another Hand' => 'Google Fonts',
2586
+ 'Just Me Again Down Here' => 'Google Fonts',
2587
+ 'K2D' => 'Google Fonts',
2588
+ 'Kadwa' => 'Google Fonts',
2589
+ 'Kalam' => 'Google Fonts',
2590
+ 'Kameron' => 'Google Fonts',
2591
+ 'Kanit' => 'Google Fonts',
2592
+ 'Kantumruy' => 'Google Fonts',
2593
+ 'Karla' => 'Google Fonts',
2594
+ 'Karma' => 'Google Fonts',
2595
+ 'Katibeh' => 'Google Fonts',
2596
+ 'Kaushan Script' => 'Google Fonts',
2597
+ 'Kavivanar' => 'Google Fonts',
2598
+ 'Kavoon' => 'Google Fonts',
2599
+ 'Kdam Thmor' => 'Google Fonts',
2600
+ 'Keania One' => 'Google Fonts',
2601
+ 'Kelly Slab' => 'Google Fonts',
2602
+ 'Kenia' => 'Google Fonts',
2603
+ 'Khand' => 'Google Fonts',
2604
+ 'Khmer' => 'Google Fonts',
2605
+ 'Khula' => 'Google Fonts',
2606
+ 'Kirang Haerang' => 'Google Fonts',
2607
+ 'Kite One' => 'Google Fonts',
2608
+ 'Knewave' => 'Google Fonts',
2609
+ 'KoHo' => 'Google Fonts',
2610
+ 'Kodchasan' => 'Google Fonts',
2611
+ 'Kosugi' => 'Google Fonts',
2612
+ 'Kosugi Maru' => 'Google Fonts',
2613
+ 'Kotta One' => 'Google Fonts',
2614
+ 'Koulen' => 'Google Fonts',
2615
+ 'Kranky' => 'Google Fonts',
2616
+ 'Kreon' => 'Google Fonts',
2617
+ 'Kristi' => 'Google Fonts',
2618
+ 'Krona One' => 'Google Fonts',
2619
+ 'Krub' => 'Google Fonts',
2620
+ 'Kumar One' => 'Google Fonts',
2621
+ 'Kumar One Outline' => 'Google Fonts',
2622
+ 'Kurale' => 'Google Fonts',
2623
+ 'La Belle Aurore' => 'Google Fonts',
2624
+ 'Laila' => 'Google Fonts',
2625
+ 'Lakki Reddy' => 'Google Fonts',
2626
+ 'Lalezar' => 'Google Fonts',
2627
+ 'Lancelot' => 'Google Fonts',
2628
+ 'Lateef' => 'Google Fonts',
2629
+ 'Lato' => 'Google Fonts',
2630
+ 'League Script' => 'Google Fonts',
2631
+ 'Leckerli One' => 'Google Fonts',
2632
+ 'Ledger' => 'Google Fonts',
2633
+ 'Lekton' => 'Google Fonts',
2634
+ 'Lemon' => 'Google Fonts',
2635
+ 'Lemonada' => 'Google Fonts',
2636
+ 'Libre Barcode 128' => 'Google Fonts',
2637
+ 'Libre Barcode 128 Text' => 'Google Fonts',
2638
+ 'Libre Barcode 39' => 'Google Fonts',
2639
+ 'Libre Barcode 39 Extended' => 'Google Fonts',
2640
+ 'Libre Barcode 39 Extended Text' => 'Google Fonts',
2641
+ 'Libre Barcode 39 Text' => 'Google Fonts',
2642
+ 'Libre Baskerville' => 'Google Fonts',
2643
+ 'Libre Franklin' => 'Google Fonts',
2644
+ 'Life Savers' => 'Google Fonts',
2645
+ 'Lilita One' => 'Google Fonts',
2646
+ 'Lily Script One' => 'Google Fonts',
2647
+ 'Limelight' => 'Google Fonts',
2648
+ 'Linden Hill' => 'Google Fonts',
2649
+ 'Lobster' => 'Google Fonts',
2650
+ 'Lobster Two' => 'Google Fonts',
2651
+ 'Londrina Outline' => 'Google Fonts',
2652
+ 'Londrina Shadow' => 'Google Fonts',
2653
+ 'Londrina Sketch' => 'Google Fonts',
2654
+ 'Londrina Solid' => 'Google Fonts',
2655
+ 'Lora' => 'Google Fonts',
2656
+ 'Love Ya Like A Sister' => 'Google Fonts',
2657
+ 'Loved by the King' => 'Google Fonts',
2658
+ 'Lovers Quarrel' => 'Google Fonts',
2659
+ 'Luckiest Guy' => 'Google Fonts',
2660
+ 'Lusitana' => 'Google Fonts',
2661
+ 'Lustria' => 'Google Fonts',
2662
+ 'M PLUS 1p' => 'Google Fonts',
2663
+ 'M PLUS Rounded 1c' => 'Google Fonts',
2664
+ 'Macondo' => 'Google Fonts',
2665
+ 'Macondo Swash Caps' => 'Google Fonts',
2666
+ 'Mada' => 'Google Fonts',
2667
+ 'Magra' => 'Google Fonts',
2668
+ 'Maiden Orange' => 'Google Fonts',
2669
+ 'Maitree' => 'Google Fonts',
2670
+ 'Mako' => 'Google Fonts',
2671
+ 'Mali' => 'Google Fonts',
2672
+ 'Mallanna' => 'Google Fonts',
2673
+ 'Mandali' => 'Google Fonts',
2674
+ 'Manuale' => 'Google Fonts',
2675
+ 'Marcellus' => 'Google Fonts',
2676
+ 'Marcellus SC' => 'Google Fonts',
2677
+ 'Marck Script' => 'Google Fonts',
2678
+ 'Margarine' => 'Google Fonts',
2679
+ 'Markazi Text' => 'Google Fonts',
2680
+ 'Marko One' => 'Google Fonts',
2681
+ 'Marmelad' => 'Google Fonts',
2682
+ 'Martel' => 'Google Fonts',
2683
+ 'Martel Sans' => 'Google Fonts',
2684
+ 'Marvel' => 'Google Fonts',
2685
+ 'Mate' => 'Google Fonts',
2686
+ 'Mate SC' => 'Google Fonts',
2687
+ 'Maven Pro' => 'Google Fonts',
2688
+ 'McLaren' => 'Google Fonts',
2689
+ 'Meddon' => 'Google Fonts',
2690
+ 'MedievalSharp' => 'Google Fonts',
2691
+ 'Medula One' => 'Google Fonts',
2692
+ 'Meera Inimai' => 'Google Fonts',
2693
+ 'Megrim' => 'Google Fonts',
2694
+ 'Meie Script' => 'Google Fonts',
2695
+ 'Merienda' => 'Google Fonts',
2696
+ 'Merienda One' => 'Google Fonts',
2697
+ 'Merriweather' => 'Google Fonts',
2698
+ 'Merriweather Sans' => 'Google Fonts',
2699
+ 'Metal' => 'Google Fonts',
2700
+ 'Metal Mania' => 'Google Fonts',
2701
+ 'Metamorphous' => 'Google Fonts',
2702
+ 'Metrophobic' => 'Google Fonts',
2703
+ 'Michroma' => 'Google Fonts',
2704
+ 'Milonga' => 'Google Fonts',
2705
+ 'Miltonian' => 'Google Fonts',
2706
+ 'Miltonian Tattoo' => 'Google Fonts',
2707
+ 'Mina' => 'Google Fonts',
2708
+ 'Miniver' => 'Google Fonts',
2709
+ 'Miriam Libre' => 'Google Fonts',
2710
+ 'Mirza' => 'Google Fonts',
2711
+ 'Miss Fajardose' => 'Google Fonts',
2712
+ 'Mitr' => 'Google Fonts',
2713
+ 'Modak' => 'Google Fonts',
2714
+ 'Modern Antiqua' => 'Google Fonts',
2715
+ 'Mogra' => 'Google Fonts',
2716
+ 'Molengo' => 'Google Fonts',
2717
+ 'Molle' => 'Google Fonts',
2718
+ 'Monda' => 'Google Fonts',
2719
+ 'Monofett' => 'Google Fonts',
2720
+ 'Monoton' => 'Google Fonts',
2721
+ 'Monsieur La Doulaise' => 'Google Fonts',
2722
+ 'Montaga' => 'Google Fonts',
2723
+ 'Montez' => 'Google Fonts',
2724
+ 'Montserrat' => 'Google Fonts',
2725
+ 'Montserrat Alternates' => 'Google Fonts',
2726
+ 'Montserrat Subrayada' => 'Google Fonts',
2727
+ 'Moul' => 'Google Fonts',
2728
+ 'Moulpali' => 'Google Fonts',
2729
+ 'Mountains of Christmas' => 'Google Fonts',
2730
+ 'Mouse Memoirs' => 'Google Fonts',
2731
+ 'Mr Bedfort' => 'Google Fonts',
2732
+ 'Mr Dafoe' => 'Google Fonts',
2733
+ 'Mr De Haviland' => 'Google Fonts',
2734
+ 'Mrs Saint Delafield' => 'Google Fonts',
2735
+ 'Mrs Sheppards' => 'Google Fonts',
2736
+ 'Mukta' => 'Google Fonts',
2737
+ 'Mukta Mahee' => 'Google Fonts',
2738
+ 'Mukta Malar' => 'Google Fonts',
2739
+ 'Mukta Vaani' => 'Google Fonts',
2740
+ 'Muli' => 'Google Fonts',
2741
+ 'Mystery Quest' => 'Google Fonts',
2742
+ 'NTR' => 'Google Fonts',
2743
+ 'Nanum Brush Script' => 'Google Fonts',
2744
+ 'Nanum Gothic' => 'Google Fonts',
2745
+ 'Nanum Gothic Coding' => 'Google Fonts',
2746
+ 'Nanum Myeongjo' => 'Google Fonts',
2747
+ 'Nanum Pen Script' => 'Google Fonts',
2748
+ 'Neucha' => 'Google Fonts',
2749
+ 'Neuton' => 'Google Fonts',
2750
+ 'New Rocker' => 'Google Fonts',
2751
+ 'News Cycle' => 'Google Fonts',
2752
+ 'Niconne' => 'Google Fonts',
2753
+ 'Niramit' => 'Google Fonts',
2754
+ 'Nixie One' => 'Google Fonts',
2755
+ 'Nobile' => 'Google Fonts',
2756
+ 'Nokora' => 'Google Fonts',
2757
+ 'Norican' => 'Google Fonts',
2758
+ 'Nosifer' => 'Google Fonts',
2759
+ 'Notable' => 'Google Fonts',
2760
+ 'Nothing You Could Do' => 'Google Fonts',
2761
+ 'Noticia Text' => 'Google Fonts',
2762
+ 'Noto Kufi Arabic' => 'Google Fonts', // Hack for Google Early Access.
2763
+ 'Noto Naskh Arabic' => 'Google Fonts', // Hack for Google Early Access.
2764
+ 'Noto Sans' => 'Google Fonts',
2765
+ 'Noto Sans Hebrew' => 'Google Fonts', // Hack for Google Early Access.
2766
+ 'Noto Sans JP' => 'Google Fonts',
2767
+ 'Noto Sans KR' => 'Google Fonts',
2768
+ 'Noto Serif' => 'Google Fonts',
2769
+ 'Noto Serif JP' => 'Google Fonts',
2770
+ 'Noto Serif KR' => 'Google Fonts',
2771
+ 'Nova Cut' => 'Google Fonts',
2772
+ 'Nova Flat' => 'Google Fonts',
2773
+ 'Nova Mono' => 'Google Fonts',
2774
+ 'Nova Oval' => 'Google Fonts',
2775
+ 'Nova Round' => 'Google Fonts',
2776
+ 'Nova Script' => 'Google Fonts',
2777
+ 'Nova Slim' => 'Google Fonts',
2778
+ 'Nova Square' => 'Google Fonts',
2779
+ 'Numans' => 'Google Fonts',
2780
+ 'Nunito' => 'Google Fonts',
2781
+ 'Nunito Sans' => 'Google Fonts',
2782
+ 'Odor Mean Chey' => 'Google Fonts',
2783
+ 'Offside' => 'Google Fonts',
2784
+ 'Old Standard TT' => 'Google Fonts',
2785
+ 'Oldenburg' => 'Google Fonts',
2786
+ 'Oleo Script' => 'Google Fonts',
2787
+ 'Oleo Script Swash Caps' => 'Google Fonts',
2788
+ 'Open Sans' => 'Google Fonts',
2789
+ 'Open Sans Condensed' => 'Google Fonts',
2790
+ 'Open Sans Hebrew' => 'Google Fonts', // Hack for Google Early Access.
2791
+ 'Open Sans Hebrew Condensed' => 'Google Fonts', // Hack for Google Early Access.
2792
+ 'Oranienbaum' => 'Google Fonts',
2793
+ 'Orbitron' => 'Google Fonts',
2794
+ 'Oregano' => 'Google Fonts',
2795
+ 'Orienta' => 'Google Fonts',
2796
+ 'Original Surfer' => 'Google Fonts',
2797
+ 'Oswald' => 'Google Fonts',
2798
+ 'Over the Rainbow' => 'Google Fonts',
2799
+ 'Overlock' => 'Google Fonts',
2800
+ 'Overlock SC' => 'Google Fonts',
2801
+ 'Overpass' => 'Google Fonts',
2802
+ 'Overpass Mono' => 'Google Fonts',
2803
+ 'Ovo' => 'Google Fonts',
2804
+ 'Oxygen' => 'Google Fonts',
2805
+ 'Oxygen Mono' => 'Google Fonts',
2806
+ 'PT Mono' => 'Google Fonts',
2807
+ 'PT Sans' => 'Google Fonts',
2808
+ 'PT Sans Caption' => 'Google Fonts',
2809
+ 'PT Sans Narrow' => 'Google Fonts',
2810
+ 'PT Serif' => 'Google Fonts',
2811
+ 'PT Serif Caption' => 'Google Fonts',
2812
+ 'Pacifico' => 'Google Fonts',
2813
+ 'Padauk' => 'Google Fonts',
2814
+ 'Palanquin' => 'Google Fonts',
2815
+ 'Palanquin Dark' => 'Google Fonts',
2816
+ 'Pangolin' => 'Google Fonts',
2817
+ 'Paprika' => 'Google Fonts',
2818
+ 'Parisienne' => 'Google Fonts',
2819
+ 'Passero One' => 'Google Fonts',
2820
+ 'Passion One' => 'Google Fonts',
2821
+ 'Pathway Gothic One' => 'Google Fonts',
2822
+ 'Patrick Hand' => 'Google Fonts',
2823
+ 'Patrick Hand SC' => 'Google Fonts',
2824
+ 'Pattaya' => 'Google Fonts',
2825
+ 'Patua One' => 'Google Fonts',
2826
+ 'Pavanam' => 'Google Fonts',
2827
+ 'Paytone One' => 'Google Fonts',
2828
+ 'Peddana' => 'Google Fonts',
2829
+ 'Peralta' => 'Google Fonts',
2830
+ 'Permanent Marker' => 'Google Fonts',
2831
+ 'Petit Formal Script' => 'Google Fonts',
2832
+ 'Petrona' => 'Google Fonts',
2833
+ 'Philosopher' => 'Google Fonts',
2834
+ 'Piedra' => 'Google Fonts',
2835
+ 'Pinyon Script' => 'Google Fonts',
2836
+ 'Pirata One' => 'Google Fonts',
2837
+ 'Plaster' => 'Google Fonts',
2838
+ 'Play' => 'Google Fonts',
2839
+ 'Playball' => 'Google Fonts',
2840
+ 'Playfair Display' => 'Google Fonts',
2841
+ 'Playfair Display SC' => 'Google Fonts',
2842
+ 'Podkova' => 'Google Fonts',
2843
+ 'Poiret One' => 'Google Fonts',
2844
+ 'Poller One' => 'Google Fonts',
2845
+ 'Poly' => 'Google Fonts',
2846
+ 'Pompiere' => 'Google Fonts',
2847
+ 'Pontano Sans' => 'Google Fonts',
2848
+ 'Poor Story' => 'Google Fonts',
2849
+ 'Poppins' => 'Google Fonts',
2850
+ 'Port Lligat Sans' => 'Google Fonts',
2851
+ 'Port Lligat Slab' => 'Google Fonts',
2852
+ 'Pragati Narrow' => 'Google Fonts',
2853
+ 'Prata' => 'Google Fonts',
2854
+ 'Preahvihear' => 'Google Fonts',
2855
+ 'Press Start 2P' => 'Google Fonts',
2856
+ 'Pridi' => 'Google Fonts',
2857
+ 'Princess Sofia' => 'Google Fonts',
2858
+ 'Prociono' => 'Google Fonts',
2859
+ 'Prompt' => 'Google Fonts',
2860
+ 'Prosto One' => 'Google Fonts',
2861
+ 'Proza Libre' => 'Google Fonts',
2862
+ 'Puritan' => 'Google Fonts',
2863
+ 'Purple Purse' => 'Google Fonts',
2864
+ 'Quando' => 'Google Fonts',
2865
+ 'Quantico' => 'Google Fonts',
2866
+ 'Quattrocento' => 'Google Fonts',
2867
+ 'Quattrocento Sans' => 'Google Fonts',
2868
+ 'Questrial' => 'Google Fonts',
2869
+ 'Quicksand' => 'Google Fonts',
2870
+ 'Quintessential' => 'Google Fonts',
2871
+ 'Qwigley' => 'Google Fonts',
2872
+ 'Racing Sans One' => 'Google Fonts',
2873
+ 'Radley' => 'Google Fonts',
2874
+ 'Rajdhani' => 'Google Fonts',
2875
+ 'Rakkas' => 'Google Fonts',
2876
+ 'Raleway' => 'Google Fonts',
2877
+ 'Raleway Dots' => 'Google Fonts',
2878
+ 'Ramabhadra' => 'Google Fonts',
2879
+ 'Ramaraja' => 'Google Fonts',
2880
+ 'Rambla' => 'Google Fonts',
2881
+ 'Rammetto One' => 'Google Fonts',
2882
+ 'Ranchers' => 'Google Fonts',
2883
+ 'Rancho' => 'Google Fonts',
2884
+ 'Ranga' => 'Google Fonts',
2885
+ 'Rasa' => 'Google Fonts',
2886
+ 'Rationale' => 'Google Fonts',
2887
+ 'Ravi Prakash' => 'Google Fonts',
2888
+ 'Redressed' => 'Google Fonts',
2889
+ 'Reem Kufi' => 'Google Fonts',
2890
+ 'Reenie Beanie' => 'Google Fonts',
2891
+ 'Revalia' => 'Google Fonts',
2892
+ 'Rhodium Libre' => 'Google Fonts',
2893
+ 'Ribeye' => 'Google Fonts',
2894
+ 'Ribeye Marrow' => 'Google Fonts',
2895
+ 'Righteous' => 'Google Fonts',
2896
+ 'Risque' => 'Google Fonts',
2897
+ 'Roboto' => 'Google Fonts',
2898
+ 'Roboto Condensed' => 'Google Fonts',
2899
+ 'Roboto Mono' => 'Google Fonts',
2900
+ 'Roboto Slab' => 'Google Fonts',
2901
+ 'Rochester' => 'Google Fonts',
2902
+ 'Rock Salt' => 'Google Fonts',
2903
+ 'Rokkitt' => 'Google Fonts',
2904
+ 'Romanesco' => 'Google Fonts',
2905
+ 'Ropa Sans' => 'Google Fonts',
2906
+ 'Rosario' => 'Google Fonts',
2907
+ 'Rosarivo' => 'Google Fonts',
2908
+ 'Rouge Script' => 'Google Fonts',
2909
+ 'Rozha One' => 'Google Fonts',
2910
+ 'Rubik' => 'Google Fonts',
2911
+ 'Rubik Mono One' => 'Google Fonts',
2912
+ 'Ruda' => 'Google Fonts',
2913
+ 'Rufina' => 'Google Fonts',
2914
+ 'Ruge Boogie' => 'Google Fonts',
2915
+ 'Ruluko' => 'Google Fonts',
2916
+ 'Rum Raisin' => 'Google Fonts',
2917
+ 'Ruslan Display' => 'Google Fonts',
2918
+ 'Russo One' => 'Google Fonts',
2919
+ 'Ruthie' => 'Google Fonts',
2920
+ 'Rye' => 'Google Fonts',
2921
+ 'Sacramento' => 'Google Fonts',
2922
+ 'Sahitya' => 'Google Fonts',
2923
+ 'Sail' => 'Google Fonts',
2924
+ 'Saira' => 'Google Fonts',
2925
+ 'Saira Condensed' => 'Google Fonts',
2926
+ 'Saira Extra Condensed' => 'Google Fonts',
2927
+ 'Saira Semi Condensed' => 'Google Fonts',
2928
+ 'Salsa' => 'Google Fonts',
2929
+ 'Sanchez' => 'Google Fonts',
2930
+ 'Sancreek' => 'Google Fonts',
2931
+ 'Sansita' => 'Google Fonts',
2932
+ 'Sarala' => 'Google Fonts',
2933
+ 'Sarina' => 'Google Fonts',
2934
+ 'Sarpanch' => 'Google Fonts',
2935
+ 'Satisfy' => 'Google Fonts',
2936
+ 'Sawarabi Gothic' => 'Google Fonts',
2937
+ 'Sawarabi Mincho' => 'Google Fonts',
2938
+ 'Scada' => 'Google Fonts',
2939
+ 'Scheherazade' => 'Google Fonts',
2940
+ 'Schoolbell' => 'Google Fonts',
2941
+ 'Scope One' => 'Google Fonts',
2942
+ 'Seaweed Script' => 'Google Fonts',
2943
+ 'Secular One' => 'Google Fonts',
2944
+ 'Sedgwick Ave' => 'Google Fonts',
2945
+ 'Sedgwick Ave Display' => 'Google Fonts',
2946
+ 'Sevillana' => 'Google Fonts',
2947
+ 'Seymour One' => 'Google Fonts',
2948
+ 'Shadows Into Light' => 'Google Fonts',
2949
+ 'Shadows Into Light Two' => 'Google Fonts',
2950
+ 'Shanti' => 'Google Fonts',
2951
+ 'Share' => 'Google Fonts',
2952
+ 'Share Tech' => 'Google Fonts',
2953
+ 'Share Tech Mono' => 'Google Fonts',
2954
+ 'Shojumaru' => 'Google Fonts',
2955
+ 'Short Stack' => 'Google Fonts',
2956
+ 'Shrikhand' => 'Google Fonts',
2957
+ 'Siemreap' => 'Google Fonts',
2958
+ 'Sigmar One' => 'Google Fonts',
2959
+ 'Signika' => 'Google Fonts',
2960
+ 'Signika Negative' => 'Google Fonts',
2961
+ 'Simonetta' => 'Google Fonts',
2962
+ 'Sintony' => 'Google Fonts',
2963
+ 'Sirin Stencil' => 'Google Fonts',
2964
+ 'Six Caps' => 'Google Fonts',
2965
+ 'Skranji' => 'Google Fonts',
2966
+ 'Slabo 13px' => 'Google Fonts',
2967
+ 'Slabo 27px' => 'Google Fonts',
2968
+ 'Slackey' => 'Google Fonts',
2969
+ 'Smokum' => 'Google Fonts',
2970
+ 'Smythe' => 'Google Fonts',
2971
+ 'Sniglet' => 'Google Fonts',
2972
+ 'Snippet' => 'Google Fonts',
2973
+ 'Snowburst One' => 'Google Fonts',
2974
+ 'Sofadi One' => 'Google Fonts',
2975
+ 'Sofia' => 'Google Fonts',
2976
+ 'Song Myung' => 'Google Fonts',
2977
+ 'Sonsie One' => 'Google Fonts',
2978
+ 'Sorts Mill Goudy' => 'Google Fonts',
2979
+ 'Source Code Pro' => 'Google Fonts',
2980
+ 'Source Sans Pro' => 'Google Fonts',
2981
+ 'Source Serif Pro' => 'Google Fonts',
2982
+ 'Space Mono' => 'Google Fonts',
2983
+ 'Special Elite' => 'Google Fonts',
2984
+ 'Spectral' => 'Google Fonts',
2985
+ 'Spectral SC' => 'Google Fonts',
2986
+ 'Spicy Rice' => 'Google Fonts',
2987
+ 'Spinnaker' => 'Google Fonts',
2988
+ 'Spirax' => 'Google Fonts',
2989
+ 'Squada One' => 'Google Fonts',
2990
+ 'Sree Krushnadevaraya' => 'Google Fonts',
2991
+ 'Sriracha' => 'Google Fonts',
2992
+ 'Srisakdi' => 'Google Fonts',
2993
+ 'Stalemate' => 'Google Fonts',
2994
+ 'Stalinist One' => 'Google Fonts',
2995
+ 'Stardos Stencil' => 'Google Fonts',
2996
+ 'Stint Ultra Condensed' => 'Google Fonts',
2997
+ 'Stint Ultra Expanded' => 'Google Fonts',
2998
+ 'Stoke' => 'Google Fonts',
2999
+ 'Strait' => 'Google Fonts',
3000
+ 'Stylish' => 'Google Fonts',
3001
+ 'Sue Ellen Francisco' => 'Google Fonts',
3002
+ 'Suez One' => 'Google Fonts',
3003
+ 'Sumana' => 'Google Fonts',
3004
+ 'Sunflower' => 'Google Fonts',
3005
+ 'Sunshiney' => 'Google Fonts',
3006
+ 'Supermercado One' => 'Google Fonts',
3007
+ 'Sura' => 'Google Fonts',
3008
+ 'Suranna' => 'Google Fonts',
3009
+ 'Suravaram' => 'Google Fonts',
3010
+ 'Suwannaphum' => 'Google Fonts',
3011
+ 'Swanky and Moo Moo' => 'Google Fonts',
3012
+ 'Syncopate' => 'Google Fonts',
3013
+ 'Tajawal' => 'Google Fonts',
3014
+ 'Tangerine' => 'Google Fonts',
3015
+ 'Taprom' => 'Google Fonts',
3016
+ 'Tauri' => 'Google Fonts',
3017
+ 'Taviraj' => 'Google Fonts',
3018
+ 'Teko' => 'Google Fonts',
3019
+ 'Telex' => 'Google Fonts',
3020
+ 'Tenali Ramakrishna' => 'Google Fonts',
3021
+ 'Tenor Sans' => 'Google Fonts',
3022
+ 'Text Me One' => 'Google Fonts',
3023
+ 'The Girl Next Door' => 'Google Fonts',
3024
+ 'Tienne' => 'Google Fonts',
3025
+ 'Tillana' => 'Google Fonts',
3026
+ 'Timmana' => 'Google Fonts',
3027
+ 'Tinos' => 'Google Fonts',
3028
+ 'Titan One' => 'Google Fonts',
3029
+ 'Titillium Web' => 'Google Fonts',
3030
+ 'Trade Winds' => 'Google Fonts',
3031
+ 'Trirong' => 'Google Fonts',
3032
+ 'Trocchi' => 'Google Fonts',
3033
+ 'Trochut' => 'Google Fonts',
3034
+ 'Trykker' => 'Google Fonts',
3035
+ 'Tulpen One' => 'Google Fonts',
3036
+ 'Ubuntu' => 'Google Fonts',
3037
+ 'Ubuntu Condensed' => 'Google Fonts',
3038
+ 'Ubuntu Mono' => 'Google Fonts',
3039
+ 'Ultra' => 'Google Fonts',
3040
+ 'Uncial Antiqua' => 'Google Fonts',
3041
+ 'Underdog' => 'Google Fonts',
3042
+ 'Unica One' => 'Google Fonts',
3043
+ 'UnifrakturCook' => 'Google Fonts',
3044
+ 'UnifrakturMaguntia' => 'Google Fonts',
3045
+ 'Unkempt' => 'Google Fonts',
3046
+ 'Unlock' => 'Google Fonts',
3047
+ 'Unna' => 'Google Fonts',
3048
+ 'VT323' => 'Google Fonts',
3049
+ 'Vampiro One' => 'Google Fonts',
3050
+ 'Varela' => 'Google Fonts',
3051
+ 'Varela Round' => 'Google Fonts',
3052
+ 'Vast Shadow' => 'Google Fonts',
3053
+ 'Vesper Libre' => 'Google Fonts',
3054
+ 'Vibur' => 'Google Fonts',
3055
+ 'Vidaloka' => 'Google Fonts',
3056
+ 'Viga' => 'Google Fonts',
3057
+ 'Voces' => 'Google Fonts',
3058
+ 'Volkhov' => 'Google Fonts',
3059
+ 'Vollkorn' => 'Google Fonts',
3060
+ 'Vollkorn SC' => 'Google Fonts',
3061
+ 'Voltaire' => 'Google Fonts',
3062
+ 'Waiting for the Sunrise' => 'Google Fonts',
3063
+ 'Wallpoet' => 'Google Fonts',
3064
+ 'Walter Turncoat' => 'Google Fonts',
3065
+ 'Warnes' => 'Google Fonts',
3066
+ 'Wellfleet' => 'Google Fonts',
3067
+ 'Wendy One' => 'Google Fonts',
3068
+ 'Wire One' => 'Google Fonts',
3069
+ 'Work Sans' => 'Google Fonts',
3070
+ 'Yanone Kaffeesatz' => 'Google Fonts',
3071
+ 'Yantramanav' => 'Google Fonts',
3072
+ 'Yatra One' => 'Google Fonts',
3073
+ 'Yellowtail' => 'Google Fonts',
3074
+ 'Yeon Sung' => 'Google Fonts',
3075
+ 'Yeseva One' => 'Google Fonts',
3076
+ 'Yesteryear' => 'Google Fonts',
3077
+ 'Yrsa' => 'Google Fonts',
3078
+ 'Zeyada' => 'Google Fonts',
3079
+ 'Zilla Slab' => 'Google Fonts',
3080
+ 'Zilla Slab Highlight' => 'Google Fonts',
3081
+ );
3082
+ }
3083
+
3084
  function wcp_manage_columns_head($defaults, $d = "")
3085
  {
3086
  global $typenow;
3205
  $terms_data[$post_type->name] = array();
3206
  }
3207
  }
3208
+ $fonts = self::get_font_list();
3209
  include_once dirname(dirname(__FILE__)) . "/templates/admin/general-settings.php";
3210
  }
3211
 
includes/form.class.php CHANGED
@@ -35,7 +35,7 @@ class WCP_Forms {
35
  <a href="javascript:;" id="inline-remove"><span class="icon folder-icon-delete"></span> <span class="text"><?php esc_html_e("Delete", WCP_FOLDER) ?></span> </a>
36
  </li>
37
  <li class="last">
38
- <a href="javascript:;" id="expand-collapse-list"><span class="icon folder-icon-expand_more"></span></span> </a>
39
  </li>
40
  </ul>
41
  <div class="upgrade-message">
35
  <a href="javascript:;" id="inline-remove"><span class="icon folder-icon-delete"></span> <span class="text"><?php esc_html_e("Delete", WCP_FOLDER) ?></span> </a>
36
  </li>
37
  <li class="last">
38
+ <a href="javascript:;" id="expand-collapse-list" class="folder-tooltip" data-tooltip=""><span class="icon folder-icon-expand_more"></span></a>
39
  </li>
40
  </ul>
41
  <div class="upgrade-message">
readme.txt CHANGED
@@ -2,8 +2,8 @@
2
  Contributors: galdub, tomeraharon, premio
3
  Tags: folder, folders, organize, pages folders, media library, posts folders, media folders, subfolders, file manager, directories
4
  Requires at least: 3.0.0
5
- Tested up to: 5.2
6
- Stable tag: 2.3.1
7
  Plugin URI: https://premio.io/downloads/folders/
8
 
9
  Folders is a WordPress plugin that will help you quickly organize and manage all of your Pages, Posts and Media library files in folders.
@@ -65,6 +65,7 @@ Digital Agencies: You're creating all sorts of content for your clients daily -
65
  * Monitor all the unassigned media library files, posts, pages, and custom posts so you can organize them easily to your folders
66
  * Sticky toolbar for the media library so you can navigate and organize your folders with ease
67
  * Add stars to important directories
 
68
  * Simultaneously assign and organize media, pages, posts, templates and custom posts while adding them to directories
69
  * Place content in multiple folders at once
70
  * Easily see subfolders within each file
@@ -134,6 +135,9 @@ A live demo for the Folders plugin is available at <a href="https://demo.premio.
134
 
135
  == Changelog ==
136
 
 
 
 
137
  = 2.3.1 =
138
  We've added an indication for succesful actions (like moving elements into a folder, changing folders names etc)
139
 
2
  Contributors: galdub, tomeraharon, premio
3
  Tags: folder, folders, organize, pages folders, media library, posts folders, media folders, subfolders, file manager, directories
4
  Requires at least: 3.0.0
5
+ Tested up to: 5.3
6
+ Stable tag: 2.3.2
7
  Plugin URI: https://premio.io/downloads/folders/
8
 
9
  Folders is a WordPress plugin that will help you quickly organize and manage all of your Pages, Posts and Media library files in folders.
65
  * Monitor all the unassigned media library files, posts, pages, and custom posts so you can organize them easily to your folders
66
  * Sticky toolbar for the media library so you can navigate and organize your folders with ease
67
  * Add stars to important directories
68
+ * New! Customize the look and feel of your folders. Change the colors, font, and size of your media folder, pages, posts, and custom posts folders
69
  * Simultaneously assign and organize media, pages, posts, templates and custom posts while adding them to directories
70
  * Place content in multiple folders at once
71
  * Easily see subfolders within each file
135
 
136
  == Changelog ==
137
 
138
+ = 2.3.2 =
139
+ You can customize the folders look and feel now: change colors, font, and size of folders. We've also added some features to improve the easy-of-use like Enter key to create a new folder and more.
140
+
141
  = 2.3.1 =
142
  We've added an indication for succesful actions (like moving elements into a folder, changing folders names etc)
143
 
templates/admin/admin-content.php CHANGED
@@ -16,6 +16,7 @@ defined('ABSPATH') or wp_die('Nope, not accessing this');
16
  $width = 292;
17
  }
18
  $width = $width - 40;
 
19
  ?>
20
  </style>
21
  <div id="wcp-custom-style">
@@ -29,9 +30,52 @@ defined('ABSPATH') or wp_die('Nope, not accessing this');
29
  #custom-menu > <?php echo $string ?> .title { width: <?php echo esc_attr($new_width) ?>px !important; }
30
  <?php
31
  }
32
- ?>
33
  </style>
34
  </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
  <div id="media-css">
36
 
37
  </div>
@@ -61,6 +105,7 @@ if(!empty($post_type)) {
61
  $active_all_class = "active-item";
62
  }
63
  }
 
64
  ?>
65
  <div id="wcp-content" class="<?php echo esc_attr(isset($display_status) && $display_status == "hide"?"hide-folders-area":"") ?>" >
66
  <div id="wcp-content-resize">
@@ -89,37 +134,41 @@ if(!empty($post_type)) {
89
  </div>
90
  <div class="folder-popup-form" id="add-update-folder">
91
  <div class="popup-form-content">
92
- <div id="add-update-folder-title" class="add-update-folder-title">
93
- Add Folder
94
- </div>
95
- <div class="folder-form-input">
96
- <input id="add-update-folder-name" autocomplete="off" placeholder="Folder name">
97
- </div>
98
- <div class="folder-form-errors">
99
- <span class="dashicons dashicons-info"></span> Please enter folder name
100
- </div>
101
- <div class="folder-form-buttons">
102
- <a href="javascript:;" class="form-submit-btn" id="save-folder-data" style="width: 56px">Submit</a>
103
- <a href="javascript:;" class="form-cancel-btn">Cancel</a>
104
- </div>
 
 
105
  </div>
106
  </div>
107
 
108
  <div class="folder-popup-form" id="update-folder-item">
109
  <div class="popup-form-content">
110
- <div id="update-folder-title" class="add-update-folder-title">
111
- Rename Folder
112
- </div>
113
- <div class="folder-form-input">
114
- <input id="update-folder-item-name" autocomplete="off" placeholder="Folder name">
115
- </div>
116
- <div class="folder-form-errors">
117
- <span class="dashicons dashicons-info"></span> Please enter folder name
118
- </div>
119
- <div class="folder-form-buttons">
120
- <a href="javascript:;" class="form-submit-btn" id="update-folder-data" style="width: 56px">Submit</a>
121
- <a href="javascript:;" class="form-cancel-btn">Cancel</a>
122
- </div>
 
 
123
  </div>
124
  </div>
125
 
@@ -133,7 +182,7 @@ if(!empty($post_type)) {
133
  </div>
134
  <div class="folder-form-buttons">
135
  <a href="javascript:;" class="form-cancel-btn">No, Keep it</a>
136
- <a href="javascript:;" class="form-submit-btn" id="remove-folder-item">Yes, Delete it!</a>
137
  </div>
138
  </div>
139
  </div>
16
  $width = 292;
17
  }
18
  $width = $width - 40;
19
+ $customize_folders = get_option('customize_folders');
20
  ?>
21
  </style>
22
  <div id="wcp-custom-style">
30
  #custom-menu > <?php echo $string ?> .title { width: <?php echo esc_attr($new_width) ?>px !important; }
31
  <?php
32
  }
33
+ ?>
34
  </style>
35
  </div>
36
+ <div id="style-css">
37
+
38
+ </div>
39
+ <style>
40
+ <?php
41
+ if(isset($customize_folders['new_folder_color']) && !empty($customize_folders['new_folder_color'])) {
42
+ ?>
43
+ .add-new-folder { background-color: <?php echo esc_attr($customize_folders['new_folder_color']) ?>; border-color: <?php echo esc_attr($customize_folders['new_folder_color']) ?> }
44
+ <?php
45
+ }
46
+ if(isset($customize_folders['dropdown_color']) && !empty($customize_folders['dropdown_color'])) {
47
+ ?>
48
+ #media-attachment-taxonomy-filter { border-color: <?php echo esc_attr($customize_folders['dropdown_color']) ?>; color: <?php echo esc_attr($customize_folders['dropdown_color']) ?> }
49
+ <?php
50
+ }
51
+ if(isset($customize_folders['folder_bg_color']) && !empty($customize_folders['folder_bg_color'])) {
52
+ ?>
53
+ .wcp-container .route.active-item > h3.title, .header-posts a.active-item, .un-categorised-items.active-item { background-color: <?php echo esc_attr($customize_folders['folder_bg_color']) ?> !important; color: #ffffff; }
54
+ <?php
55
+ }
56
+ if(isset($customize_folders['bulk_organize_button_color']) && !empty($customize_folders['bulk_organize_button_color'])) {
57
+ ?>
58
+ button.button.organize-button { background-color: <?php echo esc_attr($customize_folders['bulk_organize_button_color']) ?>; border-color: <?php echo esc_attr($customize_folders['bulk_organize_button_color']) ?>; }
59
+ button.button.organize-button:hover { background-color: <?php echo esc_attr($customize_folders['bulk_organize_button_color']) ?>; border-color: <?php echo esc_attr($customize_folders['bulk_organize_button_color']) ?>; }
60
+ <?php
61
+ }
62
+ $font_family = "";
63
+ if(isset($customize_folders['folder_font']) && !empty($customize_folders['folder_font'])) {
64
+ $font_family = $customize_folders['folder_font'];
65
+ ?>
66
+ .wcp-container, .folder-popup-form { font-family: "<?php echo esc_attr($font_family) ?>"; }
67
+ <?php
68
+ }
69
+ if(isset($customize_folders['folder_size']) && !empty($customize_folders['folder_size'])) {
70
+ ?>
71
+ .wcp-container .route span.title-text, .header-posts a, .un-categorised-items a { font-size: <?php echo esc_attr($customize_folders['folder_size']) ?>px; }
72
+ <?php
73
+ }
74
+ ?>
75
+ </style>
76
+ <?php if(!empty($font_family)) {
77
+ wp_enqueue_style( 'custom-google-fonts', 'https://fonts.googleapis.com/css?family='.urlencode($font_family), false );
78
+ } ?>
79
  <div id="media-css">
80
 
81
  </div>
105
  $active_all_class = "active-item";
106
  }
107
  }
108
+
109
  ?>
110
  <div id="wcp-content" class="<?php echo esc_attr(isset($display_status) && $display_status == "hide"?"hide-folders-area":"") ?>" >
111
  <div id="wcp-content-resize">
134
  </div>
135
  <div class="folder-popup-form" id="add-update-folder">
136
  <div class="popup-form-content">
137
+ <form action="" method="post" id="save-folder-form">
138
+ <div id="add-update-folder-title" class="add-update-folder-title">
139
+ Add Folder
140
+ </div>
141
+ <div class="folder-form-input">
142
+ <input id="add-update-folder-name" autocomplete="off" placeholder="Folder name">
143
+ </div>
144
+ <div class="folder-form-errors">
145
+ <span class="dashicons dashicons-info"></span> Please enter folder name
146
+ </div>
147
+ <div class="folder-form-buttons">
148
+ <button type="submit" class="form-submit-btn" id="save-folder-data" style="width: 106px">Submit</button>
149
+ <a href="javascript:;" class="form-cancel-btn">Cancel</a>
150
+ </div>
151
+ </form>
152
  </div>
153
  </div>
154
 
155
  <div class="folder-popup-form" id="update-folder-item">
156
  <div class="popup-form-content">
157
+ <form action="" method="post" id="update-folder-form">
158
+ <div id="update-folder-title" class="add-update-folder-title">
159
+ Rename Folder
160
+ </div>
161
+ <div class="folder-form-input">
162
+ <input id="update-folder-item-name" autocomplete="off" placeholder="Folder name">
163
+ </div>
164
+ <div class="folder-form-errors">
165
+ <span class="dashicons dashicons-info"></span> Please enter folder name
166
+ </div>
167
+ <div class="folder-form-buttons">
168
+ <button type="submit" class="form-submit-btn" id="update-folder-data" style="width: 106px">Submit</button>
169
+ <a href="javascript:;" class="form-cancel-btn">Cancel</a>
170
+ </div>
171
+ </form>
172
  </div>
173
  </div>
174
 
182
  </div>
183
  <div class="folder-form-buttons">
184
  <a href="javascript:;" class="form-cancel-btn">No, Keep it</a>
185
+ <a href="javascript:;" class="form-submit-btn" id="remove-folder-item" style="width: 116px">Yes, Delete it!</a>
186
  </div>
187
  </div>
188
  </div>
templates/admin/general-settings.php CHANGED
@@ -1,46 +1,11 @@
1
  <?php
2
  defined('ABSPATH') or wp_die('Nope, not accessing this');
3
  ?>
 
 
 
 
4
  <style>
5
- span.upgrade-message {
6
- padding: 5px 10px;
7
- background: #fff;
8
- display: inline-block;
9
- font-size: 14px;
10
- color: #000;
11
- }
12
- a.pink, span.pink {
13
- color: #FF5983;
14
- text-decoration: none;
15
- font-weight: bold;
16
- }
17
- #setting-form {
18
- float: left;
19
- width: 580px;
20
- }
21
- .form-table th.default-folder {
22
- width: 100px;
23
- }
24
- .premio-help {
25
- width: calc(100% - 600px);
26
- float: left;
27
- text-align: center;
28
- }
29
- .premio-help a {
30
- display: inline-block;
31
- width: 200px;
32
- margin-top: 15px;
33
- }
34
- .premio-help a img {
35
- width: 100%;
36
- height: auto;
37
- }
38
- .hide-option {
39
- display: none;
40
- }
41
- select.hide-show-option {
42
- width: 170px;
43
- }
44
  <?php if ( function_exists( 'is_rtl' ) && is_rtl() ) { ?>
45
  #setting-form {
46
  float: right;
@@ -56,113 +21,357 @@ defined('ABSPATH') or wp_die('Nope, not accessing this');
56
  jQuery(this).closest("tr").find(".hide-show-option").addClass("hide-option");
57
  }
58
  });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
59
  });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
60
  </script>
 
 
 
61
  <div class="wrap">
62
  <h1><?php esc_attr_e( 'Folders Settings', WCP_FOLDER ); ?></h1>
63
  <form action="options.php" method="post" id="setting-form">
64
  <?php
65
  settings_fields('folders_settings');
66
  settings_fields('default_folders');
 
67
  $options = get_option('folders_settings');
68
  $default_folders = get_option('default_folders');
 
69
  $default_folders = (empty($default_folders) || !is_array($default_folders))?array():$default_folders;
70
  do_settings_sections( __FILE__ );
71
  ?>
72
- <table class="form-table">
73
- <?php
74
- $post_types = get_post_types( array( 'public' => true ), 'objects' );
75
- $post_array = array("page", "post", "attachment");
76
- foreach ( $post_types as $post_type ) : ?>
77
- <?php
78
- if ( ! $post_type->show_ui) continue;
79
- $is_checked = !in_array( $post_type->name, $options )?"hide-option":"";
80
- $selected_id = (isset($default_folders[$post_type->name]))?$default_folders[$post_type->name]:"all";
81
- if(in_array($post_type->name, $post_array)){
82
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
83
  <tr>
84
  <th>
85
- <label for="folders_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Use folders with: ', WCP_FOLDER )." ".esc_html_e($post_type->label); ?></label>
86
  </th>
87
  <td>
88
- <input type="checkbox" class="folder-select" id="folders_<?php echo esc_attr($post_type->name); ?>" name="folders_settings[]" value="<?php echo esc_attr($post_type->name); ?>"<?php if ( in_array( $post_type->name, $options ) ) echo ' checked="checked"'; ?>/>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
89
  </td>
90
- <th class="default-folder">
91
- <label class="hide-show-option <?php echo esc_attr($is_checked) ?>" for="folders_for_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Default folder: ', WCP_FOLDER ) ?></label>
 
 
 
 
 
 
 
 
92
  </th>
93
  <td>
94
- <select class="hide-show-option <?php echo esc_attr($is_checked) ?>" id="folders_for_<?php echo esc_attr($post_type->name); ?>" name="default_folders[<?php echo esc_attr($post_type->name); ?>]" ?>">
95
- <option value="">All <?php echo esc_attr($post_type->label) ?> Folder</option>
96
- <option value="-1" <?php echo ($selected_id == -1)?"selected":"" ?>>Unassigned <?php echo esc_attr($post_type->label) ?></option>
97
- <?php
98
- if(isset($terms_data[$post_type->name]) && !empty($terms_data[$post_type->name])) {
99
- foreach ($terms_data[$post_type->name] as $term) {
100
- $selected = ($selected_id == $term->slug)?"selected":"";
101
- echo "<option ".esc_attr($selected)." value='".esc_attr($term->slug)."'>".esc_attr($term->name)."</option>";
102
- }
103
- } ?>
104
- </select>
105
  </td>
106
  </tr>
107
- <?php
108
- } else { ?>
 
109
  <tr>
110
  <th>
111
- <label for="folders_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Use folders with: ', WCP_FOLDER )." ".esc_html_e($post_type->label); ?></label>
112
  </th>
113
  <td>
114
- <input type="checkbox" class="folder-select" id="folders_<?php echo esc_attr($post_type->name); ?>" name="folders_settings[]" value="<?php echo esc_attr($post_type->name); ?>"<?php if ( in_array( $post_type->name, $options ) ) echo ' checked="checked"'; ?>/>
115
  </td>
116
- <th class="default-folder">
117
- <label class="hide-show-option <?php echo esc_attr($is_checked) ?>" for="folders_for_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Default folder: ', WCP_FOLDER ) ?></label>
 
 
 
 
 
118
  </th>
119
  <td>
120
- <select class="hide-show-option <?php echo esc_attr($is_checked) ?>" id="folders_for_<?php echo esc_attr($post_type->name); ?>" name="default_folders[<?php echo esc_attr($post_type->name); ?>]" ?>">
121
- <option value="">All <?php echo esc_attr($post_type->label) ?> Folder</option>
122
- <option value="-1" <?php echo ($selected_id == -1)?"selected":"" ?>>Unassigned <?php echo esc_attr($post_type->label) ?></option>
123
- <?php
124
- if(isset($terms_data[$post_type->name]) && !empty($terms_data[$post_type->name])) {
125
- foreach ($terms_data[$post_type->name] as $term) {
126
- $selected = ($selected_id == $term->slug)?"selected":"";
127
- echo "<option ".esc_attr($selected)." value='".esc_attr($term->slug)."'>".esc_attr($term->name)."</option>";
 
 
 
 
 
 
 
 
 
 
128
  }
129
- } ?>
 
 
 
 
 
 
 
130
  </select>
131
  </td>
132
  </tr>
133
- <?php } endforeach; ?>
134
- <tr>
135
- <th>
136
- <label for="folders_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Show Folders in Menu:', WCP_FOLDER ); ?></label>
137
- </th>
138
- <td>
139
- <?php $val = get_option("folders_show_in_menu"); ?>
140
- <input type="hidden" name="folders_show_in_menu" value="off" />
141
- <input type="checkbox" name="folders_show_in_menu" value="on" <?php echo ($val == "on")?"checked='checked'":"" ?>/>
142
- </td>
143
- </tr>
144
- <tr>
145
- <td colspan="2" style="padding: 10px 0">
146
- <?php
147
- $total_folders = get_option("folder_old_plugin_folder_status");
148
- if($total_folders == false || $total_folders < 10) {
149
- $total_folders = 10;
150
- }
151
- $total = WCP_Folders::get_total_term_folders();
152
- if($total > $total_folders) {
153
- $total_folders = $total;
154
- }
155
- ?>
156
- <span class="upgrade-message">You have used <span class='pink'><?php echo esc_attr($total) ?></span>/<?php echo esc_attr($total_folders) ?> Folders. <a class="pink" href="<?php echo esc_url(admin_url("admin.php?page=wcp_folders_upgrade")) ?>"><?php esc_html_e("Upgrade", WCP_FOLDER) ?></a></span>
157
- </td>
158
- </tr>
159
- </table>
160
- <input type="hidden" name="folders_settings1[premio_folder_option]" value="yes" />
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
161
  <?php submit_button(); ?>
162
  </form>
163
- <div class="premio-help">
164
- <a href="https://premio.io/help/folders/?utm_source=pluginspage" target="_blank">
165
- <img src="<?php echo esc_url(WCP_FOLDER_URL."assets/images/premio-help.png") ?>" alt="Premio Help" class="Premio Help" />
166
- </a>
167
- </div>
168
- </div>
1
  <?php
2
  defined('ABSPATH') or wp_die('Nope, not accessing this');
3
  ?>
4
+ <link rel='stylesheet' href='<?php echo WCP_FOLDER_URL ?>assets/css/settings.css' type='text/css' media='all' />
5
+ <link rel='stylesheet' href='<?php echo WCP_FOLDER_URL ?>assets/css/folder-icon.css' type='text/css' media='all' />
6
+ <link rel='stylesheet' href='<?php echo WCP_FOLDER_URL ?>assets/css/spectrum.min.css' type='text/css' media='all' />
7
+ <script src="<?php echo WCP_FOLDER_URL ?>assets/js/spectrum.min.js"></script>
8
  <style>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9
  <?php if ( function_exists( 'is_rtl' ) && is_rtl() ) { ?>
10
  #setting-form {
11
  float: right;
21
  jQuery(this).closest("tr").find(".hide-show-option").addClass("hide-option");
22
  }
23
  });
24
+ jQuery(document).on("click", ".accordion-header", function(){
25
+ if(jQuery(this).hasClass("active")) {
26
+ jQuery(this).closest(".accordion").find(".accordion-content").slideUp();
27
+ jQuery(this).removeClass("active");
28
+ } else {
29
+ jQuery(this).closest(".accordion").find(".accordion-content").slideDown();
30
+ jQuery(this).addClass("active");
31
+ }
32
+ });
33
+ jQuery(".accordion-header:first").trigger("click");
34
+ jQuery("#folder_font, #folder_size").change(function(){
35
+ setCSSProperties();
36
+ });
37
+ setCSSProperties();
38
+ jQuery('.color-field').spectrum({
39
+ chooseText: "Submit",
40
+ preferredFormat: "hex",
41
+ showInput: true,
42
+ cancelText: "Cancel",
43
+ move: function (color) {
44
+ jQuery(this).val(color.toHexString());
45
+ setCSSProperties();
46
+ },
47
+ change: function (color) {
48
+ jQuery(this).val(color.toHexString());
49
+ setCSSProperties();
50
+ }
51
+ });
52
  });
53
+
54
+ function setCSSProperties() {
55
+ if(jQuery("#new_folder_color").val() != "") {
56
+ jQuery("#add-new-folder").css("border-color", jQuery("#new_folder_color").val());
57
+ jQuery("#add-new-folder").css("background-color", jQuery("#new_folder_color").val());
58
+ }
59
+ if(jQuery("#bulk_organize_button_color").val() != "") {
60
+ jQuery(".organize-button").css("border-color", jQuery("#bulk_organize_button_color").val());
61
+ jQuery(".organize-button").css("background-color", jQuery("#bulk_organize_button_color").val());
62
+ jQuery(".organize-button").css("color", "#ffffff");
63
+ }
64
+ if(jQuery("#dropdown_color").val() != "") {
65
+ jQuery(".media-select").css("border-color", jQuery("#dropdown_color").val());
66
+ jQuery(".media-select").css("color", jQuery("#dropdown_color").val());
67
+ }
68
+ if(jQuery("#folder_bg_color").val() != "") {
69
+ jQuery(".all-posts.active-item").css("border-color", jQuery("#folder_bg_color").val());
70
+ jQuery(".all-posts.active-item").css("background-color", jQuery("#folder_bg_color").val());
71
+ jQuery(".all-posts.active-item").css("color", "#ffffff");
72
+ }
73
+ jQuery("#custom-css").html("");
74
+ if(jQuery("#folder_font").val() != "") {
75
+ font_val = jQuery("#folder_font").val();
76
+ jQuery('head').append('<link href="https://fonts.googleapis.com/css?family=' + font_val + ':400,600,700" rel="stylesheet" type="text/css" class="chaty-google-font">');
77
+ jQuery('.preview-box').css('font-family', font_val);
78
+ } else {
79
+ jQuery('.preview-box').css('style', "");
80
+ }
81
+ if(jQuery("#folder_size").val() != "") {
82
+ jQuery(".folder-list li a span, .header-posts a, .un-categorised-items a").css("font-size", jQuery("#folder_size").val()+"px");
83
+ } else {
84
+ jQuery(".folder-list li a span, .header-posts a, .un-categorised-items a").css("font-size", "14px");
85
+ }
86
+ }
87
  </script>
88
+ <div id="custom-css">
89
+
90
+ </div>
91
  <div class="wrap">
92
  <h1><?php esc_attr_e( 'Folders Settings', WCP_FOLDER ); ?></h1>
93
  <form action="options.php" method="post" id="setting-form">
94
  <?php
95
  settings_fields('folders_settings');
96
  settings_fields('default_folders');
97
+ settings_fields('customize_folders');
98
  $options = get_option('folders_settings');
99
  $default_folders = get_option('default_folders');
100
+ $customize_folders = get_option('customize_folders');
101
  $default_folders = (empty($default_folders) || !is_array($default_folders))?array():$default_folders;
102
  do_settings_sections( __FILE__ );
103
  ?>
104
+ <div class="accordion">
105
+ <div class="accordion-header">Folders Settings <span class="dashicons dashicons-arrow-down-alt2"></span></div>
106
+ <div class="accordion-content" style="display: block">
107
+ <div class="accordion-left">
108
+ <table class="form-table">
109
+ <?php
110
+ $post_types = get_post_types( array( 'public' => true ), 'objects' );
111
+ $post_array = array("page", "post", "attachment");
112
+ foreach ( $post_types as $post_type ) : ?>
113
+ <?php
114
+ if ( ! $post_type->show_ui) continue;
115
+ $is_checked = !in_array( $post_type->name, $options )?"hide-option":"";
116
+ $selected_id = (isset($default_folders[$post_type->name]))?$default_folders[$post_type->name]:"all";
117
+ if(in_array($post_type->name, $post_array)){
118
+ ?>
119
+ <tr>
120
+ <th width="220px">
121
+ <label for="folders_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Use folders with: ', WCP_FOLDER )." ".esc_html_e($post_type->label); ?></label>
122
+ </th>
123
+ <td>
124
+ <input type="checkbox" class="folder-select" id="folders_<?php echo esc_attr($post_type->name); ?>" name="folders_settings[]" value="<?php echo esc_attr($post_type->name); ?>"<?php if ( in_array( $post_type->name, $options ) ) echo ' checked="checked"'; ?>/>
125
+ </td>
126
+ <th class="default-folder">
127
+ <label class="hide-show-option <?php echo esc_attr($is_checked) ?>" for="folders_for_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Default folder: ', WCP_FOLDER ) ?></label>
128
+ </th>
129
+ <td>
130
+ <select class="hide-show-option <?php echo esc_attr($is_checked) ?>" id="folders_for_<?php echo esc_attr($post_type->name); ?>" name="default_folders[<?php echo esc_attr($post_type->name); ?>]" ?>">
131
+ <option value="">All <?php echo esc_attr($post_type->label) ?> Folder</option>
132
+ <option value="-1" <?php echo ($selected_id == -1)?"selected":"" ?>>Unassigned <?php echo esc_attr($post_type->label) ?></option>
133
+ <?php
134
+ if(isset($terms_data[$post_type->name]) && !empty($terms_data[$post_type->name])) {
135
+ foreach ($terms_data[$post_type->name] as $term) {
136
+ $selected = ($selected_id == $term->slug)?"selected":"";
137
+ echo "<option ".esc_attr($selected)." value='".esc_attr($term->slug)."'>".esc_attr($term->name)."</option>";
138
+ }
139
+ } ?>
140
+ </select>
141
+ </td>
142
+ </tr>
143
+ <?php
144
+ } else { ?>
145
+ <tr>
146
+ <th>
147
+ <label for="folders_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Use folders with: ', WCP_FOLDER )." ".esc_html_e($post_type->label); ?></label>
148
+ </th>
149
+ <td>
150
+ <input type="checkbox" class="folder-select" id="folders_<?php echo esc_attr($post_type->name); ?>" name="folders_settings[]" value="<?php echo esc_attr($post_type->name); ?>"<?php if ( in_array( $post_type->name, $options ) ) echo ' checked="checked"'; ?>/>
151
+ </td>
152
+ <th class="default-folder">
153
+ <label class="hide-show-option <?php echo esc_attr($is_checked) ?>" for="folders_for_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Default folder: ', WCP_FOLDER ) ?></label>
154
+ </th>
155
+ <td>
156
+ <select class="hide-show-option <?php echo esc_attr($is_checked) ?>" id="folders_for_<?php echo esc_attr($post_type->name); ?>" name="default_folders[<?php echo esc_attr($post_type->name); ?>]" ?>">
157
+ <option value="">All <?php echo esc_attr($post_type->label) ?> Folder</option>
158
+ <option value="-1" <?php echo ($selected_id == -1)?"selected":"" ?>>Unassigned <?php echo esc_attr($post_type->label) ?></option>
159
+ <?php
160
+ if(isset($terms_data[$post_type->name]) && !empty($terms_data[$post_type->name])) {
161
+ foreach ($terms_data[$post_type->name] as $term) {
162
+ $selected = ($selected_id == $term->slug)?"selected":"";
163
+ echo "<option ".esc_attr($selected)." value='".esc_attr($term->slug)."'>".esc_attr($term->name)."</option>";
164
+ }
165
+ } ?>
166
+ </select>
167
+ </td>
168
+ </tr>
169
+ <?php } endforeach; ?>
170
  <tr>
171
  <th>
172
+ <label for="folders_<?php echo esc_attr($post_type->name); ?>" ><?php esc_html_e( 'Show Folders in Menu:', WCP_FOLDER ); ?></label>
173
  </th>
174
  <td>
175
+ <?php $val = get_option("folders_show_in_menu"); ?>
176
+ <input type="hidden" name="folders_show_in_menu" value="off" />
177
+ <input type="checkbox" name="folders_show_in_menu" value="on" <?php echo ($val == "on")?"checked='checked'":"" ?>/>
178
+ </td>
179
+ </tr>
180
+ <tr>
181
+ <td colspan="2" style="padding: 10px 0">
182
+ <?php
183
+ $total_folders = get_option("folder_old_plugin_folder_status");
184
+ if($total_folders == false || $total_folders < 10) {
185
+ $total_folders = 10;
186
+ }
187
+ $total = WCP_Folders::get_total_term_folders();
188
+ if($total > $total_folders) {
189
+ $total_folders = $total;
190
+ }
191
+ ?>
192
+ <span class="upgrade-message">You have used <span class='pink'><?php echo esc_attr($total) ?></span>/<?php echo esc_attr($total_folders) ?> Folders. <a class="pink" href="<?php echo esc_url(admin_url("admin.php?page=wcp_folders_upgrade")) ?>"><?php esc_html_e("Upgrade", WCP_FOLDER) ?></a></span>
193
+ </td>
194
+ </tr>
195
+ </table>
196
+ <input type="hidden" name="folders_settings1[premio_folder_option]" value="yes" />
197
+ </div>
198
+ <div class="accordion-right">
199
+ <div class="premio-help">
200
+ <a href="https://premio.io/help/folders/?utm_source=pluginspage" target="_blank">
201
+ <img src="<?php echo esc_url(WCP_FOLDER_URL."assets/images/premio-help.png") ?>" alt="Premio Help" class="Premio Help" />
202
+ </a>
203
+ </div>
204
+ </div>
205
+ <div class="clear"></div>
206
+ </div>
207
+ </div>
208
+ <div class="accordion">
209
+ <div class="accordion-header">Customize Folders <span class="dashicons dashicons-arrow-down-alt2"></span></div>
210
+ <div class="accordion-content">
211
+ <div class="accordion-left">
212
+ <table class="form-table">
213
+ <?php
214
+ $color = !isset($customize_folders['new_folder_color'])||empty($customize_folders['new_folder_color'])?"#F51366":$customize_folders['new_folder_color'];
215
+ ?>
216
+ <tr>
217
+ <th width="220px">
218
+ <label for="new_folder_color" >New Folder button color</label>
219
+ </th>
220
+ <td width="32px">
221
+ <input type="text" class="color-field" name="customize_folders[new_folder_color]" id="new_folder_color" value="<?php echo esc_attr($color) ?>" />
222
  </td>
223
+ <td rowspan="4" >
224
+
225
+ </td>
226
+ </tr>
227
+ <?php
228
+ $color = !isset($customize_folders['bulk_organize_button_color'])||empty($customize_folders['bulk_organize_button_color'])?"#F51366":$customize_folders['bulk_organize_button_color'];
229
+ ?>
230
+ <tr>
231
+ <th>
232
+ <label for="bulk_organize_button_color" >Bulk Organize button color</label>
233
  </th>
234
  <td>
235
+ <input type="text" class="color-field" name="customize_folders[bulk_organize_button_color]" id="bulk_organize_button_color" value="<?php echo esc_attr($color) ?>" />
 
 
 
 
 
 
 
 
 
 
236
  </td>
237
  </tr>
238
+ <?php
239
+ $color = !isset($customize_folders['dropdown_color'])||empty($customize_folders['dropdown_color'])?"#F51366":$customize_folders['dropdown_color'];
240
+ ?>
241
  <tr>
242
  <th>
243
+ <label for="dropdown_color" >Dropdown color</label>
244
  </th>
245
  <td>
246
+ <input type="text" class="color-field" name="customize_folders[dropdown_color]" id="dropdown_color" value="<?php echo esc_attr($color) ?>" />
247
  </td>
248
+ </tr>
249
+ <?php
250
+ $color = !isset($customize_folders['folder_bg_color'])||empty($customize_folders['folder_bg_color'])?"#008ec2":$customize_folders['folder_bg_color'];
251
+ ?>
252
+ <tr>
253
+ <th>
254
+ <label for="folder_bg_color" >Folders background color</label>
255
  </th>
256
  <td>
257
+ <input type="text" class="color-field" name="customize_folders[folder_bg_color]" id="folder_bg_color" value="<?php echo esc_attr($color) ?>" />
258
+ </td>
259
+ </tr>
260
+ <tr>
261
+ <th>
262
+ <label for="folder_font" >Folders font</label>
263
+ </th>
264
+ <td colspan="2">
265
+ <?php
266
+ $font = !isset($customize_folders['folder_font'])||empty($customize_folders['folder_font'])?"":$customize_folders['folder_font'];
267
+ $index = 0;
268
+ ?>
269
+ <select name="customize_folders[folder_font]" id="folder_font" >
270
+ <?php $group = '';
271
+ foreach ($fonts as $key => $value):
272
+ $title = $key;
273
+ if($index == 0) {
274
+ $key = "";
275
  }
276
+ $index++;
277
+ if ($value != $group) {
278
+ echo '<optgroup label="' . $value . '">';
279
+ $group = $value;
280
+ }
281
+ ?>
282
+ <option value="<?php echo $key; ?>" <?php selected($font, $key); ?>><?php echo $title; ?></option>
283
+ <?php endforeach; ?>
284
  </select>
285
  </td>
286
  </tr>
287
+ <tr>
288
+ <th>
289
+ <label for="folder_size" >Folders size</label>
290
+ </th>
291
+ <td colspan="2">
292
+ <?php
293
+ $sizes = array(
294
+ "12" => "Small",
295
+ "16" => "Medium",
296
+ "20" => "Large"
297
+ );
298
+ $size = !isset($customize_folders['folder_size'])||empty($customize_folders['folder_size'])?"16":$customize_folders['folder_size'];
299
+
300
+ ?>
301
+ <select name="customize_folders[folder_size]" id="folder_size" >
302
+ <?php
303
+ foreach ($sizes as $key=>$value) {
304
+ $selected = ($key == $size)?"selected":"";
305
+ echo "<option ".$selected." value='".$key."'>".$value."</option>";
306
+ }
307
+ ?>
308
+ </select>
309
+ </td>
310
+ </tr>
311
+ </table>
312
+ </div>
313
+ <div class="accordion-right">
314
+ <div class="preview-text">
315
+ Preview
316
+ <div class="preview-text-info">See the full functionality on your media library, posts, pages, and custom posts</div>
317
+ </div>
318
+ <div class="preview-inner-box">
319
+ <div class="preview-box">
320
+ <div class="wcp-custom-form">
321
+ <div class="form-title">
322
+ Folders
323
+ <a href="javascript:;" class="add-new-folder" id="add-new-folder">
324
+ <span class="folder-icon-create_new_folder"></span>
325
+ <span>New Folder</span>
326
+ </a>
327
+ <div class="clear"></div>
328
+ </div>
329
+ <div class="form-options">
330
+ <ul>
331
+ <li>
332
+ <a href="javascript:;" id="inline-update"><span class="icon folder-icon-border_color"><span class="path1"></span><span class="path2"></span></span> <span class="text">Rename</span> </a>
333
+ </li>
334
+ <li>
335
+ <a href="javascript:;" id="inline-remove"><span class="icon folder-icon-delete"></span> <span class="text">Delete</span> </a>
336
+ </li>
337
+ <li class="last">
338
+ <a href="javascript:;" id="expand-collapse-list" class="folder-tooltip" data-tooltip="Expand"><span class="icon folder-icon-expand_more"></span></a>
339
+ </li>
340
+ </ul>
341
+ </div>
342
+ </div>
343
+ <div class="header-posts">
344
+ <a href="javascript:;" class="all-posts active-item"><span class="wcp-icon folder-icon-insert_drive_file"></span> All Files <span class="total-count">0</span></a>
345
+ </div>
346
+ <div class="un-categorised-items ui-droppable">
347
+ <a href="javascript:;" class="un-categorized-posts">Unassigned Files <span class="total-count total-empty">0</span> </a>
348
+ </div>
349
+
350
+ <ul class="folder-list">
351
+ <li><a href="javascript:;"><i class="wcp-icon folder-icon-folder"></i> <span>Folder 1</span></a></li>
352
+ <li><a href="javascript:;"><i class="wcp-icon folder-icon-folder"></i> <span>Folder 2</span></a></li>
353
+ <li><a href="javascript:;"><i class="wcp-icon folder-icon-folder"></i> <span>Folder 3</span></a></li>
354
+ </ul>
355
+ </div>
356
+ <div class="media-buttons">
357
+ <select class="media-select">
358
+ <option>All Files</option>
359
+ <option>Folder 1</option>
360
+ <option>Folder 2</option>
361
+ <option>Folder 3</option>
362
+ </select>
363
+ <button type="button" class="button organize-button">Bulk Organize</button>
364
+ <div style="clear: both;"></div>
365
+ </div>
366
+ </div>
367
+ </div>
368
+ <div class="clear"></div>
369
+ </div>
370
+ </div>
371
  <?php submit_button(); ?>
372
  </form>
373
+ </div>
374
+ <script>
375
+ jQuery(document).ready(function(){
376
+ });
377
+ </script>
 
templates/admin/upgrade-to-pro.php CHANGED
@@ -104,7 +104,7 @@ $pro_url = "https://go.premio.io/?edd_action=add_to_cart&download_id=687&edd_opt
104
  <div style="clear:both;"></div>
105
  </div>
106
  <div class="rpt_features rpt_features_2">
107
- <div class="rpt_feature rpt_feature_2-0"><a href="javascript:void(0)" class="rpt_tooltip"><span class="intool"><b></b><?php esc_html_e('Use Folders on 20 domains', WCP_FOLDER); ?></span><?php esc_html_e('20 website', WCP_FOLDER); ?> <span class="rpt_tooltip_plus"> +</span></a> </div>
108
  <div class="rpt_feature rpt_feature_1-1">
109
  <?php esc_html_e('Organize Pages, Posts and Media files', WCP_FOLDER); ?>
110
  </div>
@@ -113,20 +113,20 @@ $pro_url = "https://go.premio.io/?edd_action=add_to_cart&download_id=687&edd_opt
113
  <div class="rpt_feature rpt_feature_0-4"><a href="javascript:void(0)" class="rpt_tooltip"><span class="intool"><b></b>You can create unlimited folders and sub-folders. On the Free plan it is limited to 10 folders in total</span>Unlimited folders<span class="rpt_tooltip_plus"> +</span></a></div>
114
  <div class="rpt_feature rpt_feature_0-5">
115
  <select data-key="0" class="multiple-options">
116
- <option data-header="Renewals for 25% off" data-price="79" value="<?php echo esc_url($pro_url."3") ?>">
117
  <?php esc_html_e("Updates & support for 1 year") ?>
118
  </option>
119
- <option data-header="For 3 years" data-price="139" value="<?php echo esc_url($pro_url."8") ?>">
120
  <?php esc_html_e("Updates & support for 3 years") ?>
121
  </option>
122
- <option data-header="For lifetime" data-price="199" value="<?php echo esc_url($pro_url."9") ?>">
123
  <?php esc_html_e("Updates & support for lifetime") ?>
124
  </option>
125
  </select>
126
  </div>
127
  </div>
128
  <div style="clear:both;"></div>
129
- <a target="_blank" href="https://go.premio.io/?edd_action=add_to_cart&amp;download_id=687&amp;edd_options[price_id]=3" class="rpt_foot rpt_foot_2">
130
  <?php esc_html_e('Buy now', WCP_FOLDER); ?>
131
  </a>
132
  </div>
104
  <div style="clear:both;"></div>
105
  </div>
106
  <div class="rpt_features rpt_features_2">
107
+ <div class="rpt_feature rpt_feature_2-0"><a href="javascript:void(0)" class="rpt_tooltip"><span class="intool"><b></b><?php esc_html_e('Use Folders on 50 domains', WCP_FOLDER); ?></span><?php esc_html_e('50 website', WCP_FOLDER); ?><span class="rpt_tooltip_plus"> +</span></a> </div>
108
  <div class="rpt_feature rpt_feature_1-1">
109
  <?php esc_html_e('Organize Pages, Posts and Media files', WCP_FOLDER); ?>
110
  </div>
113
  <div class="rpt_feature rpt_feature_0-4"><a href="javascript:void(0)" class="rpt_tooltip"><span class="intool"><b></b>You can create unlimited folders and sub-folders. On the Free plan it is limited to 10 folders in total</span>Unlimited folders<span class="rpt_tooltip_plus"> +</span></a></div>
114
  <div class="rpt_feature rpt_feature_0-5">
115
  <select data-key="0" class="multiple-options">
116
+ <option data-header="Renewals for 25% off" data-price="79" value="<?php echo esc_url($pro_url."10") ?>">
117
  <?php esc_html_e("Updates & support for 1 year") ?>
118
  </option>
119
+ <option data-header="For 3 years" data-price="139" value="<?php echo esc_url($pro_url."11") ?>">
120
  <?php esc_html_e("Updates & support for 3 years") ?>
121
  </option>
122
+ <option data-header="For lifetime" data-price="199" value="<?php echo esc_url($pro_url."12") ?>">
123
  <?php esc_html_e("Updates & support for lifetime") ?>
124
  </option>
125
  </select>
126
  </div>
127
  </div>
128
  <div style="clear:both;"></div>
129
+ <a target="_blank" href="https://go.premio.io/?edd_action=add_to_cart&amp;download_id=687&amp;edd_options[price_id]=10" class="rpt_foot rpt_foot_2">
130
  <?php esc_html_e('Buy now', WCP_FOLDER); ?>
131
  </a>
132
  </div>