diff --git a/app.js b/app.js index 55a7f6a..b05be58 100644 --- a/app.js +++ b/app.js @@ -13,6 +13,8 @@ let apos = require('apostrophe')({ modules: { 'two-column-widgets': {extend: 'apostrophe-widgets'}, + 'two-column-1-2-widgets': {}, + 'two-column-2-1-widgets': {}, // Apostrophe module configuration @@ -39,6 +41,15 @@ let apos = require('apostrophe')({ 'apostrophe-db': { uri: process.env.MONGO_URL }, + 'apostrophe-rich-text-permalinks': { + join: { + withType: ["apostrophe-page", "apostrophe-file"] + } + }, + + + //Note: Rich Text Widgets configuration is being done in the /lib/modules/apostrophe-rich-text-widgets/index.js + // // 'apostrophe-rich-text-widgets': { // sanitizeHtml: { // allowedAttributes: { @@ -50,7 +61,9 @@ let apos = require('apostrophe')({ // } // } // } - // Was having some issues with overlaying menus. + + + // Was having some issues with the menus hovering over the text the user was editing. Is less functional but better looking. //'apostrophe-tiptap-rich-text-widgets': {} } }); diff --git a/dev/images/Logo Stylized.svg b/dev/images/Logo Stylized.svg new file mode 100644 index 0000000..631449f --- /dev/null +++ b/dev/images/Logo Stylized.svg @@ -0,0 +1,3930 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/lib/modules/apostrophe-admin-bar/views/logo.html b/lib/modules/apostrophe-admin-bar/views/logo.html new file mode 100644 index 0000000..c380555 --- /dev/null +++ b/lib/modules/apostrophe-admin-bar/views/logo.html @@ -0,0 +1,2 @@ + +image/svg+xml diff --git a/lib/modules/apostrophe-assets/public/css/main.css b/lib/modules/apostrophe-assets/public/css/main.css index 5cb52f7..5e4e78e 100644 --- a/lib/modules/apostrophe-assets/public/css/main.css +++ b/lib/modules/apostrophe-assets/public/css/main.css @@ -51,6 +51,49 @@ ul.bulletLevel2 { list-style-position: inside; } +.apos-login-logo { + margin-bottom: 0; +} + +.apos-login-logo svg { + width: 200px; + height: 200px; +} + +.apos-login.apos-ui { + background-color: #d29a6b; +} + +.apos-ui .apos-field { + margin-bottom: 1rem; +} +.apos-ui .apos-field-input { + padding: 0.5rem; +} +.apos-ui .apos-login-submit { + margin-top: 3rem; +} +.apos-ui .apos-button--major { + background-color: saddlebrown; +} +.apos-ui .apos-button--global { + background-color: #4F3A28; +} +.apos-ui .apos-field-input:focus { + box-shadow: 0 0 15px 0 #4F3A28; +} + +.apos-login-wrapper, .apos-login-content, .apos-ui .apos-admin-bar { + background-color: #4F3A28; +} + +@media only screen and (min-width: 1450px) { + .apos-ui .apos-admin-bar-logo, .apos-ui .apos-admin-bar-logo svg { + max-height: 40px; + max-width: 40px; + margin-right: 30px; + } +} @media only screen and (max-width: 1100px) { html { font-size: 14px !important; diff --git a/lib/modules/apostrophe-assets/public/css/main.css.map b/lib/modules/apostrophe-assets/public/css/main.css.map index 581fb6c..6b737d5 100644 --- a/lib/modules/apostrophe-assets/public/css/main.css.map +++ b/lib/modules/apostrophe-assets/public/css/main.css.map @@ -1 +1 @@ -{"version":3,"sourceRoot":"","sources":["main.sass"],"names":[],"mappings":"AACA;EACC;EACA;EACA;;;AAED;EACC;EACA;EACA;EACA;;;AAED;EACC;;;AAED;EACC;EACA;;;AAED;EACC;EACA;;;AAED;EACC;;;AAED;EACC;;;AAGD;EACC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAED;EACC;EACA;EACA;;;AAMD;EACC;IACC;;;AAEF;EACC;IACC;;;AAEF;EACC;IACC;;;AAEF;EACC;IACC","file":"main.css"} \ No newline at end of file +{"version":3,"sourceRoot":"","sources":["main.sass"],"names":[],"mappings":"AACA;EACC;EACA;EACA;;;AAED;EACC;EACA;EACA;EACA;;;AAED;EACC;;;AAED;EACC;EACA;;;AAED;EACC;EACA;;;AAED;EACC;;;AAED;EACC;;;AAGD;EACC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAED;EACC;EACA;EACA;;;AAOD;EACC;;;AACD;EACC;EACA;;;AACD;EACC,kBAPU;;;AASV;EACC;;AACD;EACC;;AACD;EACC;;AACD;EACC;;AACD;EACC,kBAnBQ;;AAoBT;EACC;;;AACF;EACC,kBAvBS;;;AAwBV;EACC;IACC;IACA;IACA;;;AAKF;EACC;IACC;;;AAEF;EACC;IACC;;;AAEF;EACC;IACC;;;AAEF;EACC;IACC","file":"main.css"} \ No newline at end of file diff --git a/lib/modules/apostrophe-assets/public/css/main.sass b/lib/modules/apostrophe-assets/public/css/main.sass index 2a4ca9c..0d71495 100644 --- a/lib/modules/apostrophe-assets/public/css/main.sass +++ b/lib/modules/apostrophe-assets/public/css/main.sass @@ -45,6 +45,38 @@ ul.bulletLevel2 list-style-position: inside // +// Redefine some of the Apostrophe administrative UI. +// +$bg-dark: #4F3A28 +$bg-light: #d29a6b +.apos-login-logo + margin-bottom: 0 +.apos-login-logo svg + width: 200px + height: 200px +.apos-login.apos-ui + background-color: $bg-light +.apos-ui + .apos-field + margin-bottom: 1rem + .apos-field-input + padding: 0.5rem + .apos-login-submit + margin-top: 3rem + .apos-button--major + background-color: saddlebrown + .apos-button--global + background-color: $bg-dark + .apos-field-input:focus + box-shadow: 0 0 15px 0 $bg-dark +.apos-login-wrapper, .apos-login-content, .apos-ui .apos-admin-bar + background-color: $bg-dark +@media only screen and (min-width: 1450px) + .apos-ui .apos-admin-bar-logo, .apos-ui .apos-admin-bar-logo svg + max-height: 40px + max-width: 40px + margin-right: 30px +// // Everything scales off of the HTML tag font sizes since the whole site uses REM units. // diff --git a/lib/modules/apostrophe-pages/index.js b/lib/modules/apostrophe-pages/index.js index 1c1a049..0286292 100644 --- a/lib/modules/apostrophe-pages/index.js +++ b/lib/modules/apostrophe-pages/index.js @@ -14,10 +14,6 @@ module.exports = { { name: 'aves', label: 'Elementary School Page' - }, - { - name: 'basic', - label: 'basic' } // Add more page types here, but make sure you create a corresponding diff --git a/lib/modules/apostrophe-pages/views/pages/district.html b/lib/modules/apostrophe-pages/views/pages/district.html index 1bc2e4d..60ef619 100644 --- a/lib/modules/apostrophe-pages/views/pages/district.html +++ b/lib/modules/apostrophe-pages/views/pages/district.html @@ -18,7 +18,8 @@ ] }, 'apostrophe-files': {}, - 'two-column': {} + 'two-column': {}, + 'two-column-1-2': {} } }) }} diff --git a/lib/modules/two-column-1-2-widgets/index.js b/lib/modules/two-column-1-2-widgets/index.js new file mode 100644 index 0000000..5e07af6 --- /dev/null +++ b/lib/modules/two-column-1-2-widgets/index.js @@ -0,0 +1,16 @@ +module.exports = { + extend: 'apostrophe-widgets', + label: 'Two Column (1:2)', + addFields: [ + { + name: 'areaLeft', + type: 'area', + label: "Left Area", + }, + { + name: "areaRight", + type: "area", + label: "Right Area" + } + ] +}; diff --git a/lib/modules/two-column-1-2-widgets/views/widget.html b/lib/modules/two-column-1-2-widgets/views/widget.html new file mode 100644 index 0000000..a018e78 --- /dev/null +++ b/lib/modules/two-column-1-2-widgets/views/widget.html @@ -0,0 +1,40 @@ +
+
+
+ {{ apos.area(data.widget, "areaLeft", { + widgets: { + 'apostrophe-images': {size: 'one-half'}, + 'apostrophe-rich-text': { + toolbar: ['Styles', 'Bold', 'Italic', 'Link', 'Unlink', 'Anchor', 'Table', 'BulletedList', 'Blockquote', 'Strike', 'Subscript', 'Superscript', 'Split'], + styles: [ + {name: 'Paragraph', element: 'p'}, + {name: 'Heading 2', element: 'h2'}, + {name: 'Heading 3', element: 'h3'}, + {name: 'Heading 4', element: 'h4'}, + {name: 'Heading 5', element: 'h5'} + ] + }, + 'apostrophe-files': {} + } + }) }} +
+
+ {{ apos.area(data.widget, "areaRight", { + widgets: { + 'apostrophe-images': {size: 'full'}, + 'apostrophe-rich-text': { + toolbar: ['Styles', 'Bold', 'Italic', 'Link', 'Unlink', 'Anchor', 'Table', 'BulletedList', 'Blockquote', 'Strike', 'Subscript', 'Superscript', 'Split'], + styles: [ + {name: 'Paragraph', element: 'p'}, + {name: 'Heading 2', element: 'h2'}, + {name: 'Heading 3', element: 'h3'}, + {name: 'Heading 4', element: 'h4'}, + {name: 'Heading 5', element: 'h5'} + ] + }, + 'apostrophe-files': {} + } + }) }} +
+
+
diff --git a/lib/modules/two-column-2-1-widgets/index.js b/lib/modules/two-column-2-1-widgets/index.js new file mode 100644 index 0000000..0b65a75 --- /dev/null +++ b/lib/modules/two-column-2-1-widgets/index.js @@ -0,0 +1,16 @@ +module.exports = { + extend: 'apostrophe-widgets', + label: 'Two Column (2:1)', + addFields: [ + { + name: 'areaLeft', + type: 'area', + label: "Left Area", + }, + { + name: "areaRight", + type: "area", + label: "Right Area" + } + ] +}; diff --git a/lib/modules/two-column-2-1-widgets/views/widget.html b/lib/modules/two-column-2-1-widgets/views/widget.html new file mode 100644 index 0000000..94a8621 --- /dev/null +++ b/lib/modules/two-column-2-1-widgets/views/widget.html @@ -0,0 +1,40 @@ +
+
+
+ {{ apos.area(data.widget, "areaLeft", { + widgets: { + 'apostrophe-images': {size: 'one-half'}, + 'apostrophe-rich-text': { + toolbar: ['Styles', 'Bold', 'Italic', 'Link', 'Unlink', 'Anchor', 'Table', 'BulletedList', 'Blockquote', 'Strike', 'Subscript', 'Superscript', 'Split'], + styles: [ + {name: 'Paragraph', element: 'p'}, + {name: 'Heading 2', element: 'h2'}, + {name: 'Heading 3', element: 'h3'}, + {name: 'Heading 4', element: 'h4'}, + {name: 'Heading 5', element: 'h5'} + ] + }, + 'apostrophe-files': {} + } + }) }} +
+
+ {{ apos.area(data.widget, "areaRight", { + widgets: { + 'apostrophe-images': {size: 'full'}, + 'apostrophe-rich-text': { + toolbar: ['Styles', 'Bold', 'Italic', 'Link', 'Unlink', 'Anchor', 'Table', 'BulletedList', 'Blockquote', 'Strike', 'Subscript', 'Superscript', 'Split'], + styles: [ + {name: 'Paragraph', element: 'p'}, + {name: 'Heading 2', element: 'h2'}, + {name: 'Heading 3', element: 'h3'}, + {name: 'Heading 4', element: 'h4'}, + {name: 'Heading 5', element: 'h5'} + ] + }, + 'apostrophe-files': {} + } + }) }} +
+
+
diff --git a/lib/modules/two-column-widgets/index.js b/lib/modules/two-column-widgets/index.js index 8cb248c..c882e8e 100644 --- a/lib/modules/two-column-widgets/index.js +++ b/lib/modules/two-column-widgets/index.js @@ -1,6 +1,6 @@ module.exports = { extend: 'apostrophe-widgets', - label: 'Two Column', + label: 'Two Column (1:1)', addFields: [ { name: 'areaLeft', diff --git a/package-lock.json b/package-lock.json index c6d557c..21d7d9e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1100,6 +1100,14 @@ "stoppable": "^1.1.0" } }, + "apostrophe-rich-text-permalinks": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/apostrophe-rich-text-permalinks/-/apostrophe-rich-text-permalinks-2.0.5.tgz", + "integrity": "sha512-BVHAW9EC36rBrc1+AXDyw7xOyFhqqT+gokjT828lgVp17xJHoQU/ABKjpFrTH3ywoPyx+p2xYVWZjl5j57Ubjw==", + "requires": { + "lodash": "^4.17.10" + } + }, "apostrophe-tiptap-rich-text-widgets": { "version": "0.3.8", "resolved": "https://registry.npmjs.org/apostrophe-tiptap-rich-text-widgets/-/apostrophe-tiptap-rich-text-widgets-0.3.8.tgz", diff --git a/package.json b/package.json index 5a90531..91d8f26 100644 --- a/package.json +++ b/package.json @@ -17,6 +17,7 @@ "dependencies": { "apostrophe": "^2.111.4", "apostrophe-monitor": "^2.1.0", + "apostrophe-rich-text-permalinks": "^2.0.5", "apostrophe-tiptap-rich-text-widgets": "^0.3.8", "prosemirror-tables": "^0.9.1" },