@silexlabs/silex 3.6.4 → 3.6.5-canary.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client/client/grapesjs/settings-sections.d.ts +4 -1
- package/dist/client/client/grapesjs/settings.d.ts +1 -0
- package/dist/client/css/admin.css +287 -0
- package/dist/client/index.html +2 -2
- package/dist/client/js/main.js +233 -103
- package/dist/client/types.d.ts +27 -0
- package/dist/plugins/client/types.d.ts +27 -0
- package/dist/plugins/client/types.js.map +1 -1
- package/dist/plugins/server/plugins/server/GitlabConnector.js +74 -1
- package/dist/plugins/server/plugins/server/GitlabConnector.js.map +1 -1
- package/dist/plugins/server/types.d.ts +27 -0
- package/dist/plugins/server/types.js.map +1 -1
- package/package.json +1 -1
- package/src/css/silex.scss +343 -0
- package/src/ts/client/grapesjs/settings-sections.ts +170 -12
- package/src/ts/client/grapesjs/settings.ts +6 -1
- package/src/ts/plugins/server/GitlabConnector.ts +76 -1
- package/src/ts/types.ts +35 -0
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import { TemplateResult } from 'lit-html';
|
|
2
|
-
import { WebsiteSettings } from '../../types';
|
|
2
|
+
import { WebsiteMeta, WebsiteSettings } from '../../types';
|
|
3
3
|
export declare const idCodeWrapper = "settings-head-wrapper";
|
|
4
|
+
export declare let websiteMeta: WebsiteMeta | null;
|
|
5
|
+
export declare function updateInfo(): Promise<void>;
|
|
4
6
|
export declare function isSite(model: any): boolean;
|
|
7
|
+
export declare function siteOrPage(model: any): "page" | "website";
|
|
5
8
|
export interface SettingsSection {
|
|
6
9
|
id: string;
|
|
7
10
|
label: string;
|
|
@@ -3,6 +3,7 @@ import { Editor } from 'grapesjs';
|
|
|
3
3
|
export declare const cmdOpenSettings = "open-settings";
|
|
4
4
|
export declare const cmdAddSection = "settings:add-section";
|
|
5
5
|
export declare const cmdRemoveSection = "settings:remove-section";
|
|
6
|
+
export declare const cmdRenderSection = "settings:render-section";
|
|
6
7
|
export interface AddSectionOption {
|
|
7
8
|
section: SettingsSection;
|
|
8
9
|
siteOrPage: 'site' | 'page';
|
|
@@ -4186,6 +4186,28 @@ textarea:focus {
|
|
|
4186
4186
|
}
|
|
4187
4187
|
|
|
4188
4188
|
/* Silex styles imports */
|
|
4189
|
+
.silex-link-action {
|
|
4190
|
+
margin-left: 0.5em;
|
|
4191
|
+
color: var(--silex-accent-primary);
|
|
4192
|
+
font-size: 0.93em;
|
|
4193
|
+
font-weight: 600;
|
|
4194
|
+
text-decoration: underline;
|
|
4195
|
+
border: none;
|
|
4196
|
+
background: none;
|
|
4197
|
+
cursor: pointer;
|
|
4198
|
+
padding: 0;
|
|
4199
|
+
display: inline;
|
|
4200
|
+
}
|
|
4201
|
+
|
|
4202
|
+
.silex-mono-json {
|
|
4203
|
+
background: var(--silex-bg-lighter);
|
|
4204
|
+
color: var(--silex-text-secondary);
|
|
4205
|
+
border-radius: 4px;
|
|
4206
|
+
padding: 5px 8px;
|
|
4207
|
+
font-size: 13px;
|
|
4208
|
+
font-family: monospace;
|
|
4209
|
+
}
|
|
4210
|
+
|
|
4189
4211
|
.silex-workspace {
|
|
4190
4212
|
position: absolute;
|
|
4191
4213
|
top: 0;
|
|
@@ -4256,6 +4278,10 @@ textarea:focus {
|
|
|
4256
4278
|
overflow: hidden;
|
|
4257
4279
|
}
|
|
4258
4280
|
|
|
4281
|
+
.silex-capitalize {
|
|
4282
|
+
text-transform: capitalize;
|
|
4283
|
+
}
|
|
4284
|
+
|
|
4259
4285
|
.settings-dialog {
|
|
4260
4286
|
position: fixed;
|
|
4261
4287
|
top: 0;
|
|
@@ -4318,6 +4344,267 @@ textarea:focus {
|
|
|
4318
4344
|
.settings-dialog .settings-body .silex-sidebar-dialog {
|
|
4319
4345
|
flex-direction: column;
|
|
4320
4346
|
}
|
|
4347
|
+
.settings-dialog .settings-body .silex-info-fork {
|
|
4348
|
+
margin-top: 10px;
|
|
4349
|
+
color: var(--silex-status-warning);
|
|
4350
|
+
background: var(--silex-bg-lighter);
|
|
4351
|
+
border-radius: 4px;
|
|
4352
|
+
padding: 6px 10px;
|
|
4353
|
+
font-weight: 500;
|
|
4354
|
+
display: inline-block;
|
|
4355
|
+
}
|
|
4356
|
+
.settings-dialog .silex-repo-section {
|
|
4357
|
+
margin-top: 24px;
|
|
4358
|
+
padding: 16px;
|
|
4359
|
+
background: var(--silex-bg-lighter);
|
|
4360
|
+
border-radius: 8px;
|
|
4361
|
+
border: 1px solid var(--silex-border-color);
|
|
4362
|
+
}
|
|
4363
|
+
.settings-dialog .silex-repo-section__title {
|
|
4364
|
+
margin: 0 0 8px 0;
|
|
4365
|
+
font-size: 16px;
|
|
4366
|
+
font-weight: 600;
|
|
4367
|
+
color: var(--silex-text-primary);
|
|
4368
|
+
}
|
|
4369
|
+
.settings-dialog .silex-repo-section__help {
|
|
4370
|
+
margin: 0 0 16px 0;
|
|
4371
|
+
font-size: 13px;
|
|
4372
|
+
line-height: 1.5;
|
|
4373
|
+
color: var(--silex-text-secondary);
|
|
4374
|
+
}
|
|
4375
|
+
.settings-dialog .silex-repo-section__help a {
|
|
4376
|
+
color: var(--silex-accent-primary);
|
|
4377
|
+
text-decoration: underline;
|
|
4378
|
+
}
|
|
4379
|
+
.settings-dialog .silex-repo-section__content {
|
|
4380
|
+
display: flex;
|
|
4381
|
+
flex-direction: column;
|
|
4382
|
+
gap: 16px;
|
|
4383
|
+
}
|
|
4384
|
+
.settings-dialog .silex-repo-section__empty {
|
|
4385
|
+
color: var(--silex-text-secondary);
|
|
4386
|
+
font-style: italic;
|
|
4387
|
+
margin: 0;
|
|
4388
|
+
}
|
|
4389
|
+
.settings-dialog .silex-repo-field {
|
|
4390
|
+
display: flex;
|
|
4391
|
+
flex-direction: column;
|
|
4392
|
+
gap: 6px;
|
|
4393
|
+
}
|
|
4394
|
+
.settings-dialog .silex-repo-field__label {
|
|
4395
|
+
display: flex;
|
|
4396
|
+
align-items: center;
|
|
4397
|
+
gap: 8px;
|
|
4398
|
+
font-size: 12px;
|
|
4399
|
+
font-weight: 600;
|
|
4400
|
+
color: var(--silex-text-secondary);
|
|
4401
|
+
text-transform: uppercase;
|
|
4402
|
+
letter-spacing: 0.5px;
|
|
4403
|
+
}
|
|
4404
|
+
.settings-dialog .silex-repo-field__status {
|
|
4405
|
+
font-size: 11px;
|
|
4406
|
+
font-weight: 600;
|
|
4407
|
+
padding: 2px 6px;
|
|
4408
|
+
border-radius: 4px;
|
|
4409
|
+
text-transform: none;
|
|
4410
|
+
}
|
|
4411
|
+
.settings-dialog .silex-repo-field__status--success {
|
|
4412
|
+
background: rgba(34, 197, 94, 0.2);
|
|
4413
|
+
color: #22c55e;
|
|
4414
|
+
}
|
|
4415
|
+
.settings-dialog .silex-repo-field__status--failed, .settings-dialog .silex-repo-field__status--error {
|
|
4416
|
+
background: rgba(239, 68, 68, 0.2);
|
|
4417
|
+
color: #ef4444;
|
|
4418
|
+
}
|
|
4419
|
+
.settings-dialog .silex-repo-field__status--running, .settings-dialog .silex-repo-field__status--pending {
|
|
4420
|
+
background: rgba(59, 130, 246, 0.2);
|
|
4421
|
+
color: #3b82f6;
|
|
4422
|
+
}
|
|
4423
|
+
.settings-dialog .silex-repo-field__status--unknown {
|
|
4424
|
+
background: var(--silex-bg-lighter);
|
|
4425
|
+
color: var(--silex-text-secondary);
|
|
4426
|
+
}
|
|
4427
|
+
.settings-dialog .silex-repo-field__meta {
|
|
4428
|
+
font-size: 11px;
|
|
4429
|
+
color: var(--silex-text-secondary);
|
|
4430
|
+
margin-top: 4px;
|
|
4431
|
+
}
|
|
4432
|
+
.settings-dialog .silex-repo-field__meta a {
|
|
4433
|
+
color: var(--silex-accent-primary);
|
|
4434
|
+
}
|
|
4435
|
+
.settings-dialog .silex-repo-field__input-wrapper {
|
|
4436
|
+
display: flex;
|
|
4437
|
+
align-items: stretch;
|
|
4438
|
+
background: var(--silex-input-bg);
|
|
4439
|
+
border-radius: 6px;
|
|
4440
|
+
overflow: hidden;
|
|
4441
|
+
border: 1px solid var(--silex-border-color);
|
|
4442
|
+
}
|
|
4443
|
+
.settings-dialog .silex-repo-field__input {
|
|
4444
|
+
flex: 1;
|
|
4445
|
+
padding: 10px 12px;
|
|
4446
|
+
border: none !important;
|
|
4447
|
+
background: transparent !important;
|
|
4448
|
+
font-family: monospace;
|
|
4449
|
+
font-size: 13px;
|
|
4450
|
+
color: var(--silex-text-primary);
|
|
4451
|
+
min-width: 0;
|
|
4452
|
+
}
|
|
4453
|
+
.settings-dialog .silex-repo-field__input:focus {
|
|
4454
|
+
outline: none;
|
|
4455
|
+
}
|
|
4456
|
+
.settings-dialog .silex-repo-field__btn {
|
|
4457
|
+
display: flex;
|
|
4458
|
+
align-items: center;
|
|
4459
|
+
justify-content: center;
|
|
4460
|
+
padding: 0 12px;
|
|
4461
|
+
background: transparent;
|
|
4462
|
+
border: none;
|
|
4463
|
+
border-left: 1px solid var(--silex-border-color);
|
|
4464
|
+
color: var(--silex-text-secondary);
|
|
4465
|
+
cursor: pointer;
|
|
4466
|
+
transition: background-color 0.15s, color 0.15s;
|
|
4467
|
+
text-decoration: none;
|
|
4468
|
+
}
|
|
4469
|
+
.settings-dialog .silex-repo-field__btn:hover {
|
|
4470
|
+
background: var(--silex-hover-bg);
|
|
4471
|
+
color: var(--silex-accent-primary);
|
|
4472
|
+
}
|
|
4473
|
+
.settings-dialog .silex-repo-field__btn--copied {
|
|
4474
|
+
background: var(--silex-status-success, #22c55e) !important;
|
|
4475
|
+
color: white !important;
|
|
4476
|
+
}
|
|
4477
|
+
.settings-dialog .silex-repo-field__btn svg {
|
|
4478
|
+
flex-shrink: 0;
|
|
4479
|
+
}
|
|
4480
|
+
.settings-dialog .silex-repo-info-grid {
|
|
4481
|
+
display: grid;
|
|
4482
|
+
grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
|
|
4483
|
+
gap: 12px;
|
|
4484
|
+
}
|
|
4485
|
+
.settings-dialog .silex-repo-info-item {
|
|
4486
|
+
display: flex;
|
|
4487
|
+
flex-direction: column;
|
|
4488
|
+
gap: 4px;
|
|
4489
|
+
padding: 10px 12px;
|
|
4490
|
+
background: var(--silex-bg-main);
|
|
4491
|
+
border-radius: 6px;
|
|
4492
|
+
border: 1px solid var(--silex-border-color);
|
|
4493
|
+
}
|
|
4494
|
+
.settings-dialog .silex-repo-info-item__label {
|
|
4495
|
+
font-size: 11px;
|
|
4496
|
+
font-weight: 600;
|
|
4497
|
+
color: var(--silex-text-secondary);
|
|
4498
|
+
text-transform: uppercase;
|
|
4499
|
+
letter-spacing: 0.5px;
|
|
4500
|
+
}
|
|
4501
|
+
.settings-dialog .silex-repo-info-item__value {
|
|
4502
|
+
font-size: 14px;
|
|
4503
|
+
font-weight: 500;
|
|
4504
|
+
color: var(--silex-text-primary);
|
|
4505
|
+
}
|
|
4506
|
+
.settings-dialog .silex-repo-info-item__action {
|
|
4507
|
+
font-size: 12px;
|
|
4508
|
+
color: var(--silex-accent-primary);
|
|
4509
|
+
text-decoration: underline;
|
|
4510
|
+
cursor: pointer;
|
|
4511
|
+
}
|
|
4512
|
+
.settings-dialog .silex-repo-info-item__action:hover {
|
|
4513
|
+
text-decoration: none;
|
|
4514
|
+
}
|
|
4515
|
+
.settings-dialog .silex-repo-info-item__links {
|
|
4516
|
+
display: flex;
|
|
4517
|
+
gap: 8px;
|
|
4518
|
+
}
|
|
4519
|
+
.settings-dialog .silex-repo-fork-notice {
|
|
4520
|
+
padding: 16px;
|
|
4521
|
+
background: var(--silex-bg-main);
|
|
4522
|
+
border: 1px solid var(--silex-border-color);
|
|
4523
|
+
border-radius: 8px;
|
|
4524
|
+
font-size: 13px;
|
|
4525
|
+
color: var(--silex-text-primary);
|
|
4526
|
+
}
|
|
4527
|
+
.settings-dialog .silex-repo-fork-notice__header {
|
|
4528
|
+
display: flex;
|
|
4529
|
+
align-items: center;
|
|
4530
|
+
gap: 8px;
|
|
4531
|
+
margin-bottom: 8px;
|
|
4532
|
+
color: var(--silex-accent-primary);
|
|
4533
|
+
}
|
|
4534
|
+
.settings-dialog .silex-repo-fork-notice__header strong {
|
|
4535
|
+
font-size: 14px;
|
|
4536
|
+
}
|
|
4537
|
+
.settings-dialog .silex-repo-fork-notice__header svg {
|
|
4538
|
+
flex-shrink: 0;
|
|
4539
|
+
}
|
|
4540
|
+
.settings-dialog .silex-repo-fork-notice__text {
|
|
4541
|
+
margin: 0 0 12px 0;
|
|
4542
|
+
line-height: 1.5;
|
|
4543
|
+
color: var(--silex-text-secondary);
|
|
4544
|
+
}
|
|
4545
|
+
.settings-dialog .silex-repo-fork-notice__text a {
|
|
4546
|
+
color: var(--silex-accent-primary);
|
|
4547
|
+
font-weight: 500;
|
|
4548
|
+
}
|
|
4549
|
+
.settings-dialog .silex-repo-fork-notice__actions {
|
|
4550
|
+
display: flex;
|
|
4551
|
+
gap: 16px;
|
|
4552
|
+
}
|
|
4553
|
+
.settings-dialog .silex-repo-fork-notice__link {
|
|
4554
|
+
color: var(--silex-accent-primary);
|
|
4555
|
+
text-decoration: none;
|
|
4556
|
+
font-weight: 500;
|
|
4557
|
+
font-size: 13px;
|
|
4558
|
+
}
|
|
4559
|
+
.settings-dialog .silex-repo-fork-notice__link:hover {
|
|
4560
|
+
text-decoration: underline;
|
|
4561
|
+
}
|
|
4562
|
+
.settings-dialog .silex-repo-fork-notice__contribute {
|
|
4563
|
+
margin: 12px 0 0 0;
|
|
4564
|
+
padding-top: 12px;
|
|
4565
|
+
border-top: 1px solid var(--silex-border-color);
|
|
4566
|
+
font-size: 12px;
|
|
4567
|
+
color: var(--silex-text-secondary);
|
|
4568
|
+
font-style: italic;
|
|
4569
|
+
}
|
|
4570
|
+
.settings-dialog .silex-repo-job {
|
|
4571
|
+
display: flex;
|
|
4572
|
+
align-items: center;
|
|
4573
|
+
flex-wrap: wrap;
|
|
4574
|
+
gap: 8px;
|
|
4575
|
+
padding: 10px 14px;
|
|
4576
|
+
background: var(--silex-bg-main);
|
|
4577
|
+
border-radius: 6px;
|
|
4578
|
+
border: 1px solid var(--silex-border-color);
|
|
4579
|
+
font-size: 13px;
|
|
4580
|
+
}
|
|
4581
|
+
.settings-dialog .silex-repo-job__label {
|
|
4582
|
+
color: var(--silex-text-secondary);
|
|
4583
|
+
}
|
|
4584
|
+
.settings-dialog .silex-repo-job__status {
|
|
4585
|
+
font-weight: 600;
|
|
4586
|
+
padding: 2px 8px;
|
|
4587
|
+
border-radius: 4px;
|
|
4588
|
+
}
|
|
4589
|
+
.settings-dialog .silex-repo-job__status--success {
|
|
4590
|
+
background: rgba(34, 197, 94, 0.2);
|
|
4591
|
+
color: #22c55e;
|
|
4592
|
+
}
|
|
4593
|
+
.settings-dialog .silex-repo-job__status--failed, .settings-dialog .silex-repo-job__status--error {
|
|
4594
|
+
background: rgba(239, 68, 68, 0.2);
|
|
4595
|
+
color: #ef4444;
|
|
4596
|
+
}
|
|
4597
|
+
.settings-dialog .silex-repo-job__status--running, .settings-dialog .silex-repo-job__status--pending {
|
|
4598
|
+
background: rgba(59, 130, 246, 0.2);
|
|
4599
|
+
color: #3b82f6;
|
|
4600
|
+
}
|
|
4601
|
+
.settings-dialog .silex-repo-job__status--unknown {
|
|
4602
|
+
background: var(--silex-bg-lighter);
|
|
4603
|
+
color: var(--silex-text-secondary);
|
|
4604
|
+
}
|
|
4605
|
+
.settings-dialog .silex-repo-job__date {
|
|
4606
|
+
color: var(--silex-text-secondary);
|
|
4607
|
+
}
|
|
4321
4608
|
.settings-dialog form.silex-form textarea {
|
|
4322
4609
|
min-height: 250px;
|
|
4323
4610
|
}
|
package/dist/client/index.html
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<!DOCTYPE html><html lang="en" translate="no"><head><title>Silex</title><meta name="description" content="This is a public instance of Silex website builder. Build websites in the browser"><link rel="shortcut icon" href="assets/favicon.png?
|
|
1
|
+
<!DOCTYPE html><html lang="en" translate="no"><head><title>Silex</title><meta name="description" content="This is a public instance of Silex website builder. Build websites in the browser"><link rel="shortcut icon" href="assets/favicon.png?98525"><style>body {
|
|
2
2
|
background-color: #444444;
|
|
3
3
|
font-family: "Ubuntu", "Helvetica Neue", Helvetica, Arial, sans-serif;
|
|
4
4
|
}
|
|
@@ -7,5 +7,5 @@
|
|
|
7
7
|
transition: opacity 0.25s 0.25s ease-in-out;
|
|
8
8
|
}
|
|
9
9
|
</style></head><body class="silex-loading"><div class="silex-loader silex-dialog" role="status" aria-live="polite" aria-busy="true">Loading
|
|
10
|
-
</div><link rel="stylesheet" type="text/css" href="css/admin.css?
|
|
10
|
+
</div><link rel="stylesheet" type="text/css" href="css/admin.css?702019"><main class="silex-workspace"><div class="silex-main silex-dialog-hide silex-ui-full" id="gjs"></div></main><script src="js/main.js?702019"></script><script>silex.start()
|
|
11
11
|
// From here silex.config is available and Silex is getting started</script></body></html>
|