Skip to content

armgit / Vvveb

Public Imported from GitHub
0

Powerful and easy to use cms to build websites, blogs or ecommerce stores.

Enable save button if changes are made in code editor, save page zip use page title as zip name, fixed media path for relative theme assets

givanzc5a144ac0ae1
diff --git a/public/js/vvvebjs/blocks-bootstrap4.js b/public/js/vvvebjs/blocks-bootstrap4.js
index 143351a..b99c67a 100755
--- a/public/js/vvvebjs/blocks-bootstrap4.js
+++ b/public/js/vvvebjs/blocks-bootstrap4.js
@@ -16,6 +16,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
+ * https://github.com/givanz/Vvveb
*/
//Snippets from https://bootsnipp.com/license
diff --git a/public/js/vvvebjs/components-bootstrap5.js b/public/js/vvvebjs/components-bootstrap5.js
index 4a0114c..079e7c7 100755
--- a/public/js/vvvebjs/components-bootstrap5.js
+++ b/public/js/vvvebjs/components-bootstrap5.js
@@ -1,20 +1,23 @@
-/*
-Copyright 2017 Ziadin Givan
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-https://github.com/givanz/Vvvebjs
-*/
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
Vvveb.ComponentsGroup['Bootstrap 5'] =
["html/container", "html/gridrow", "html/btn", "html/btn-link", "html/buttongroup", "html/buttontoolbar", "html/alert", "html/card", "html/listgroup", "html/badge", "html/progress", "html/navbar", "html/breadcrumbs", "html/pagination"];
@@ -1001,22 +1004,23 @@ Vvveb.Components.extend("_base", "html/gridrow", {
}],
},
},{
- name: "Column",
- key: "column1",
- inputtype: GridInput
+ name: "Column",
+ key: "column1",
+ inputtype: GridInput
},{
- name: "Column",
- key: "column1",
- inline:true,
- col:12,
- inputtype: GridInput
+ name: "Column",
+ key: "column1",
+ inline:true,
+ col:12,
+ inputtype: GridInput
},{
- name: "",
- key: "addChild",
- inputtype: ButtonInput,
- data: {text:"Add column", icon:"la la-plus"},
- onChange: function(node)
- {
+ name: "",
+ key: "addChild",
+ inline:true,
+ inputtype: ButtonInput,
+ data: {text:"Add column", icon:"la la-plus", className:"btn-secondary"},
+ onChange: function(node)
+ {
node.append(generateElements('<div class="col-3"><h3>Col-3</h3></div>')[0]);
//render component properties again to include the new column inputs
diff --git a/public/js/vvvebjs/components-content.js b/public/js/vvvebjs/components-content.js
index ef7bc60..10f8b68 100755
--- a/public/js/vvvebjs/components-content.js
+++ b/public/js/vvvebjs/components-content.js
@@ -1,19 +1,22 @@
-/*
-Copyright 2017 Ziadin Givan
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-https://github.com/givanz/VvvebJs
-*/
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
Vvveb.ComponentsGroup['Content'] = ["content/posts", "content/post", "content/categories", "content/search", "content/menu", "content/language", "content/currency", "content/tags", "content/archives", "content/user"];
diff --git a/public/js/vvvebjs/components-ecommerce.js b/public/js/vvvebjs/components-ecommerce.js
index 8a658a5..9ae8781 100755
--- a/public/js/vvvebjs/components-ecommerce.js
+++ b/public/js/vvvebjs/components-ecommerce.js
@@ -1,20 +1,23 @@
-/*
-Copyright 2017 Ziadin Givan
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-https://github.com/givanz/VvvebJs
-*/
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
import {productComponent} from './ecommerce/products.js';
import {productsComponent} from './ecommerce/products.js';
diff --git a/public/js/vvvebjs/components-embeds.js b/public/js/vvvebjs/components-embeds.js
index d180bfb..0fe5e90 100755
--- a/public/js/vvvebjs/components-embeds.js
+++ b/public/js/vvvebjs/components-embeds.js
@@ -1,20 +1,23 @@
-/*
-Copyright 2017 Ziadin Givan
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-https://github.com/givanz/VvvebJs
-*/
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
Vvveb.ComponentsGroup['Embeds'] = ["embeds/embed"];
diff --git a/public/js/vvvebjs/plugin-aos.js b/public/js/vvvebjs/plugin-aos.js
index 4a0e8f2..0031ced 100755
--- a/public/js/vvvebjs/plugin-aos.js
+++ b/public/js/vvvebjs/plugin-aos.js
@@ -1,3 +1,24 @@
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
+
/*
Animate on scroll
The edited page should include the aos library https://github.com/michalsnik/aos
diff --git a/public/js/vvvebjs/plugin-codemirror.js b/public/js/vvvebjs/plugin-codemirror.js
index 78e0857..93f2651 100755
--- a/public/js/vvvebjs/plugin-codemirror.js
+++ b/public/js/vvvebjs/plugin-codemirror.js
@@ -1,3 +1,24 @@
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
+
Vvveb.CodeEditor = {
isActive: false,
@@ -19,8 +40,13 @@ Vvveb.CodeEditor = {
this.isActive = true;
this.codemirror.getDoc().on("change", function (e, v) {
- if (v.origin != "setValue")
- delay(() => Vvveb.Builder.setHtml(e.getValue()), 1000);
+ if (v.origin != "setValue") {
+ delay(() => {
+ Vvveb.Builder.setHtml(e.getValue());
+ //enable save button
+ document.querySelectorAll("#top-panel .save-btn").forEach(e => e.removeAttribute("disabled"));
+ }, 1000);
+ }
});
}
diff --git a/public/js/vvvebjs/plugin-google-fonts.js b/public/js/vvvebjs/plugin-google-fonts.js
index 7446411..4b529f8 100755
--- a/public/js/vvvebjs/plugin-google-fonts.js
+++ b/public/js/vvvebjs/plugin-google-fonts.js
@@ -1,3 +1,24 @@
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
+
GoogleFontsManager = {
url: "https://fonts.googleapis.com/css2?display=swap&family=",
activeFonts: [],
diff --git a/public/js/vvvebjs/plugin-jszip.js b/public/js/vvvebjs/plugin-jszip.js
index 7716073..476f9ea 100755
--- a/public/js/vvvebjs/plugin-jszip.js
+++ b/public/js/vvvebjs/plugin-jszip.js
@@ -115,10 +115,10 @@ function () {
}
}
- zip.file("index.html", html);
+ zip.file(Vvveb.FileManager.getCurrentFileName() ?? "index.html", html);
zip.generateAsync({type:"blob"})
.then(function(content) {
- saveAs(content, Vvveb.FileManager.getCurrentPage());
+ saveAs(content, Vvveb.FileManager.getPageData("title") ?? Vvveb.FileManager.getCurrentPage());
});
}).catch((error) => {
console.log(error)
diff --git a/public/js/vvvebjs/plugin-media.js b/public/js/vvvebjs/plugin-media.js
index aa566f7..dedd755 100755
--- a/public/js/vvvebjs/plugin-media.js
+++ b/public/js/vvvebjs/plugin-media.js
@@ -1,3 +1,24 @@
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
+
ImageInput = { ...ImageInput, ...{
tag: "img",
@@ -12,7 +33,7 @@ ImageInput = { ...ImageInput, ...{
if (value && value.indexOf("data:image") == -1 && value != "none") {
this.element[0].querySelector('input[type="text"]').value = value;
//$('input[type="text"]', this.element).val(value);
- let src = (value.indexOf("//") > -1 || value.indexOf("media/") > -1 || value.indexOf("image-cache/") > -1 ? '' : Vvveb.themeBaseUrl) + value
+ let src = (value.indexOf("//") > -1 || value.indexOf("media/") > -1 || value.indexOf("image-cache/") > -1 || value[0] == '/' ? '' : Vvveb.themeBaseUrl) + value;
this.element[0].querySelector(this.tag).src = src;
//$(this.tag, this.element).attr("src", src);
} else {
diff --git a/public/js/vvvebjs/sections-bootstrap4.js b/public/js/vvvebjs/sections-bootstrap4.js
index 479236c..3479156 100755
--- a/public/js/vvvebjs/sections-bootstrap4.js
+++ b/public/js/vvvebjs/sections-bootstrap4.js
@@ -1,378 +1,26 @@
-/*
-Copyright 2017 Ziadin Givan
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-https://github.com/givanz/Vvvebjs
-*/
+/**
+ * Vvveb
+ *
+ * Copyright (C) 2021 Ziadin Givan
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
+ *
+ * https://github.com/givanz/Vvveb
+ */
Vvveb.SectionsGroup['Bootstrap'] =
-["bootstrap4/signin-split", "bootstrap4/image-gallery", "bootstrap4/video-header", "bootstrap4/slider-header", "bootstrap4/about-team", "bootstrap4/portfolio-one-column", "bootstrap4/portfolio-two-column", "bootstrap4/portfolio-three-column", "bootstrap4/portfolio-four-column"];
-
-
-Vvveb.Sections.add("bootstrap4/signin-split", {
- name: "Modern Sign In Page with Split Screen Format",
- dragHtml: '<img src="' + Vvveb.baseUrl + 'icons/product.png">',
- image: "https://assets.startbootstrap.com/img/screenshots/snippets/sign-in-split.jpg",
- html: `
-<section data-name="sigin-split">
-<div class="container-fluid">
- <div class="row no-gutter">
- <div class="d-none d-md-flex col-md-4 col-lg-6 bg-image"></div>
- <div class="col-md-8 col-lg-6">
- <div class="login d-flex align-items-center py-5">
- <div class="container">
- <div class="row">
- <div class="col-md-9 col-lg-8 mx-auto">
- <h3 class="login-heading mb-4">Welcome back!</h3>
- <form>
- <div class="form-label-group">
- <input type="email" id="inputEmail" class="form-control" placeholder="Email address" required autofocus>
- <label for="inputEmail">Email address</label>
- </div>
-
- <div class="form-label-group">
- <input type="password" id="inputPassword" class="form-control" placeholder="Password" required>
- <label for="inputPassword">Password</label>
- </div>
-
- <div class="mb-3">
- <input type="checkbox" class="form-check-input" id="customCheck1">
- <label class="custom-control-label" for="customCheck1">Remember password</label>
- </div>
- <button class="btn btn-lg btn-primary btn-section btn-login text-uppercase font-weight-bold mb-2" type="submit">Sign in</button>
- <div class="text-center">
- <a class="small" href="#">Forgot password?</a></div>
- </form>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
-<style>
-.login,
-.image {
- min-height: 100vh;
-}
-
-.bg-image {
- background-image: url('https://source.unsplash.com/WEQbe2jBg40/600x1200');
- background-size: cover;
- background-position: center;
-}
-
-.login-heading {
- font-weight: 300;
-}
-
-.btn-login {
- font-size: 0.9rem;
- letter-spacing: 0.05rem;
- padding: 0.75rem 1rem;
- border-radius: 2rem;
-}
-
-.form-label-group {
- position: relative;
- margin-bottom: 1rem;
-}
-
-.form-label-group>input,
-.form-label-group>label {
- padding: 1rem 1rem;
- height: auto;
- border-radius: 2rem;
-}
-
-.form-label-group>label {
- position: absolute;
- top: 0;
- left: 0;
- display: block;
- width: 100%;
- margin-bottom: 0;
- line-height: 1.5;
- color: #495057;
- cursor: text;
- /* Match the input under the label */
- border: 1px solid transparent;
- border-radius: .25rem;
- transition: all .1s ease-in-out;
-}
-
-.form-label-group input::-webkit-input-placeholder {
- color: transparent;
-}
-
-.form-label-group input:-ms-input-placeholder {
- color: transparent;
-}
-
-.form-label-group input::-ms-input-placeholder {
- color: transparent;
-}
-
-.form-label-group input::-moz-placeholder {
- color: transparent;
-}
-
-.form-label-group input::placeholder {
- color: transparent;
-}
-
-.form-label-group input:not(:placeholder-shown) {
- padding-top: calc(var(--input-padding-y) + var(--input-padding-y) * (2 / 3));
- padding-bottom: calc(var(--input-padding-y) / 3);
-}
-
-.form-label-group input:not(:placeholder-shown)~label {
- padding-top: 0.5;
- padding-bottom: 0.5;
- font-size: 12px;
- color: #777;
-}
-</style>
-</div>
-</section>
-`,
-});
-
-Vvveb.Sections.add("bootstrap4/image-gallery", {
- name: "Image gallery",
- image: "https://assets.startbootstrap.com/img/screenshots/snippets/thumbnail-gallery.jpg",
- dragHtml: '<img src="' + Vvveb.baseUrl + 'icons/product.png">',
- html: `
-<section data-name="image-gallery">
-<div class="container">
-
- <h1 class="font-weight-light text-center text-lg-left">Thumbnail Gallery</h1>
-
- <hr class="mt-2 mb-5">
-
- <div class="row text-center text-lg-left">
-
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/pWkk7iiCoDM/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/aob0ukAYfuI/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/EUfxH-pze7s/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/M185_qYH8vg/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/sesveuG_rNo/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/AvhMzHwiE_0/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/2gYsZUmockw/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/EMSDtjVHdQ8/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/8mUEy0ABdNE/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/G9Rfc1qccH4/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/aJeH0KcFkuc/400x300" alt="">
- </a>
- </div>
- <div class="col-lg-3 col-md-4 col-6">
- <a href="#" class="d-block mb-4 h-100">
- <img class="img-fluid img-thumbnail" src="https://source.unsplash.com/p2TQ-3Bh3Oo/400x300" alt="">
- </a>
- </div>
- </div>
-
-</div>
-</section>
-`,
-});
-
-Vvveb.Sections.add("bootstrap4/slider-header", {
- name: "Image Slider Header",
- dragHtml: '<img src="' + Vvveb.baseUrl + 'icons/product.png">',
- image: "https://assets.startbootstrap.com/img/screenshots/snippets/full-slider.jpg",
- html:`
-<header class="slider" data-name="slider">
- <div id="carouselExampleIndicators" class="carousel slide" data-ride="carousel">
- <ol class="carousel-indicators">
- <li data-bs-target="#carouselExampleIndicators" data-slide-to="0" class="active"></li>
- <li data-bs-target="#carouselExampleIndicators" data-slide-to="1"></li>
- <li data-bs-target="#carouselExampleIndicators" data-slide-to="2"></li>
- </ol>
- <div class="carousel-inner" role="listbox">
- <!-- Slide One - Set the background image for this slide in the line below -->
- <div class="carousel-item active" style="background-image: url('https://source.unsplash.com/LAaSoL0LrYs/1920x1080')">
- <div class="carousel-caption d-none d-md-block">
- <h2 class="display-4">First Slide</h2>
- <p class="lead">This is a description for the first slide.</p>
- </div>
- </div>
- <!-- Slide Two - Set the background image for this slide in the line below -->
- <div class="carousel-item" style="background-image: url('https://source.unsplash.com/bF2vsubyHcQ/1920x1080')">
- <div class="carousel-caption d-none d-md-block">
- <h2 class="display-4">Second Slide</h2>
- <p class="lead">This is a description for the second slide.</p>
- </div>
- </div>
- <!-- Slide Three - Set the background image for this slide in the line below -->
- <div class="carousel-item" style="background-image: url('https://source.unsplash.com/szFUQoyvrxM/1920x1080')">
- <div class="carousel-caption d-none d-md-block">
- <h2 class="display-4">Third Slide</h2>
- <p class="lead">This is a description for the third slide.</p>
- </div>
- </div>
- </div>
- <a class="carousel-control-prev" href="#carouselExampleIndicators" role="button" data-slide="prev">
- <span class="carousel-control-prev-icon" aria-hidden="true"></span>
- <span class="sr-only">Previous</span>
- </a>
- <a class="carousel-control-next" href="#carouselExampleIndicators" role="button" data-slide="next">
- <span class="carousel-control-next-icon" aria-hidden="true"></span>
- <span class="sr-only">Next</span>
- </a>
- </div>
-
-<style>
-.carousel-item {
- height: 100vh;
- min-height: 350px;
- background: no-repeat center center scroll;
- -webkit-background-size: cover;
- -moz-background-size: cover;
- -o-background-size: cover;
- background-size: cover;
-}
-</style>
-</header>
-`,
-});
-
-
-Vvveb.Sections.add("bootstrap4/video-header", {
- name: "Video Header",
- dragHtml: '<img src="' + Vvveb.baseUrl + 'icons/image.svg">',
- image: "https://assets.startbootstrap.com/img/screenshots/snippets/video-header.jpg",
- html:`
-<header class="video" data-name="header-video">
- <div class="overlay"></div>
- <video playsinline="playsinline" autoplay="autoplay" muted="muted" loop="loop">
- <source src="../../media/demo/sample.webm" type="video/mp4">
- </video>
- <div class="container h-100">
- <div class="d-flex h-100 text-center align-items-center">
- <div class="w-100 text-white">
- <h1 class="display-3">Video Header</h1>
- <p class="lead mb-0">With HTML5 Video and Bootstrap 4</p>
- </div>
- </div>
- </div>
-
-
-<div class="my-5">
- <div class="container">
- <div class="row">
- <div class="col-md-8 mx-auto">
- <p>The HTML5 video element uses an mp4 video as a source. Change the source video to add in your own background! The header text is vertically centered using flex utilities that are build into Bootstrap 4.</p>
- </div>
- </div>
- </div>
-</div>
-<style>
-header.video {
- position: relative;
- background-color: black;
- height: 75vh;
- min-height: 25rem;
- width: 100%;
- overflow: hidden;
-}
-
-header.video video {
- position: absolute;
- top: 50%;
- left: 50%;
- min-width: 100%;
- min-height: 100%;
- width: auto;
- height: auto;
- z-index: 0;
- -ms-transform: translateX(-50%) translateY(-50%);
- -moz-transform: translateX(-50%) translateY(-50%);
- -webkit-transform: translateX(-50%) translateY(-50%);
- transform: translateX(-50%) translateY(-50%);
-}
-
-header.video .container {
- position: relative;
- z-index: 2;
-}
-
-header.video .overlay {
- /*position: absolute;*/
- top: 0;
- left: 0;
- height: 100%;
- width: 100%;
- background-color: black;
- opacity: 0.5;
- z-index: 1;
-}
-
-@media (pointer: coarse) and (hover: none) {
- header {
- background: url('https://source.unsplash.com/XT5OInaElMw/1600x900') black no-repeat center center scroll;
- }
- header video {
- display: none;
- }
-}
-</style>
-</header>
-`,
-});
-
+["bootstrap4/about-team", "bootstrap4/portfolio-one-column", "bootstrap4/portfolio-two-column", "bootstrap4/portfolio-three-column", "bootstrap4/portfolio-four-column"];
Vvveb.Sections.add("bootstrap4/about-team", {
@@ -392,7 +40,7 @@ Vvveb.Sections.add("bootstrap4/about-team", {
<!-- Team Member 1 -->
<div class="col-xl-3 col-md-6 mb-4">
<div class="card border-0 shadow">
- <img src="https://source.unsplash.com/TMgQMXoglsM/500x350" class="card-img-top" alt="...">
+ <img src="https://images.unsplash.com/photo-1507591064344-4c6ce005b128?w=640" class="card-img-top" alt="...">
<div class="card-body text-center">
<h5 class="card-title mb-0">Team Member</h5>
<div class="card-text text-black-50">Web Developer</div>
@@ -402,7 +50,7 @@ Vvveb.Sections.add("bootstrap4/about-team", {
<!-- Team Member 2 -->
<div class="col-xl-3 col-md-6 mb-4">
<div class="card border-0 shadow">
- <img src="https://source.unsplash.com/9UVmlIb0wJU/500x350" class="card-img-top" alt="...">
+ <img src="https://images.unsplash.com/photo-1487412720507-e7ab37603c6f?w=640" class="card-img-top" alt="...">
<div class="card-body text-center">
<h5 class="card-title mb-0">Team Member</h5>
<div class="card-text text-black-50">Web Developer</div>
@@ -412,7 +60,7 @@ Vvveb.Sections.add("bootstrap4/about-team", {
<!-- Team Member 3 -->
<div class="col-xl-3 col-md-6 mb-4">
<div class="card border-0 shadow">
- <img src="https://source.unsplash.com/sNut2MqSmds/500x350" class="card-img-top" alt="...">
+ <img src="https://images.unsplash.com/photo-1522536421511-14c9073df899?w=640" class="card-img-top" alt="...">
<div class="card-body text-center">
<h5 class="card-title mb-0">Team Member</h5>
<div class="card-text text-black-50">Web Developer</div>
@@ -422,7 +70,7 @@ Vvveb.Sections.add("bootstrap4/about-team", {
<!-- Team Member 4 -->
<div class="col-xl-3 col-md-6 mb-4">
<div class="card border-0 shadow">
- <img src="https://source.unsplash.com/ZI6p3i9SbVU/500x350" class="card-img-top" alt="...">
+ <img src="https://images.unsplash.com/photo-1477118476589-bff2c5c4cfbb?w=640" class="card-img-top" alt="...">
<div class="card-body text-center">
<h5 class="card-title mb-0">Team Member</h5>
<div class="card-text text-black-50">Web Developer</div>
@@ -456,7 +104,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-one-column", {
<div class="row">
<div class="col-md-7">
<a href="#">
- <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.it/700x300" alt="">
+ <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.co/700x300" alt="">
</a>
</div>
<div class="col-md-5">
@@ -473,7 +121,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-one-column", {
<div class="row">
<div class="col-md-7">
<a href="#">
- <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.it/700x300" alt="">
+ <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.co/700x300" alt="">
</a>
</div>
<div class="col-md-5">
@@ -490,7 +138,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-one-column", {
<div class="row">
<div class="col-md-7">
<a href="#">
- <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.it/700x300" alt="">
+ <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.co/700x300" alt="">
</a>
</div>
<div class="col-md-5">
@@ -508,7 +156,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-one-column", {
<div class="col-md-7">
<a href="#">
- <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.it/700x300" alt="">
+ <img class="img-fluid rounded mb-3 mb-md-0" src="http://placehold.co/700x300" alt="">
</a>
</div>
<div class="col-md-5">
@@ -569,7 +217,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-two-column", {
<div class="row">
<div class="col-lg-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project One</a>
@@ -580,7 +228,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-two-column", {
</div>
<div class="col-lg-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Two</a>
@@ -591,7 +239,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-two-column", {
</div>
<div class="col-lg-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Three</a>
@@ -602,7 +250,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-two-column", {
</div>
<div class="col-lg-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Four</a>
@@ -613,7 +261,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-two-column", {
</div>
<div class="col-lg-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Five</a>
@@ -624,7 +272,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-two-column", {
</div>
<div class="col-lg-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Six</a>
@@ -682,7 +330,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-three-column", {
<div class="row">
<div class="col-lg-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project One</a>
@@ -693,7 +341,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-three-column", {
</div>
<div class="col-lg-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Two</a>
@@ -704,7 +352,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-three-column", {
</div>
<div class="col-lg-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Three</a>
@@ -715,7 +363,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-three-column", {
</div>
<div class="col-lg-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Four</a>
@@ -726,7 +374,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-three-column", {
</div>
<div class="col-lg-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Five</a>
@@ -737,7 +385,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-three-column", {
</div>
<div class="col-lg-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Six</a>
@@ -795,7 +443,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
<div class="row">
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project One</a>
@@ -806,7 +454,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
</div>
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Two</a>
@@ -817,7 +465,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
</div>
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Three</a>
@@ -828,7 +476,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
</div>
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Four</a>
@@ -839,7 +487,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
</div>
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Five</a>
@@ -850,7 +498,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
</div>
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Six</a>
@@ -861,7 +509,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
</div>
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Seven</a>
@@ -872,7 +520,7 @@ Vvveb.Sections.add("bootstrap4/portfolio-four-column", {
</div>
<div class="col-lg-3 col-md-4 col-sm-6 mb-4">
<div class="card h-100">
- <a href="#"><img class="card-img-top" src="http://placehold.it/700x400" alt=""></a>
+ <a href="#"><img class="card-img-top" src="http://placehold.co/700x400" alt=""></a>
<div class="card-body">
<h4 class="card-title">
<a href="#">Project Eight</a>
diff --git a/public/js/vvvebjs/undo.js b/public/js/vvvebjs/undo.js
index ae263b6..5c6c4de 100755
--- a/public/js/vvvebjs/undo.js
+++ b/public/js/vvvebjs/undo.js
@@ -16,8 +16,9 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
+ * https://github.com/givanz/Vvveb
*/
-
+
Vvveb.Undo = {
mutations: [],