From 5ea4d835bd32c4ccf3bfecd99bb3f5b33c88f490 Mon Sep 17 00:00:00 2001 From: Troplo Date: Tue, 2 Aug 2022 21:15:16 +1000 Subject: [PATCH] 1.0.12 --- .github/workflows/desktop.yml | 34 ++ .../20220802105441-removeOldUserColumns.js | 17 + backend/models/users.js | 10 - frontend/package.json | 2 +- frontend/src/assets/styles.css | 10 + frontend/src/components/CommsInput.vue | 15 +- frontend/src/components/Message.vue | 212 +++++++--- frontend/src/main.js | 19 +- .../Communications/CommunicationsChat.vue | 400 ++++-------------- frontend/src/views/Login.vue | 5 +- frontend/src/views/Register.vue | 49 ++- frontend/src/views/Settings/SettingsSite.vue | 6 +- 12 files changed, 351 insertions(+), 428 deletions(-) create mode 100644 .github/workflows/desktop.yml create mode 100644 backend/migrations/20220802105441-removeOldUserColumns.js diff --git a/.github/workflows/desktop.yml b/.github/workflows/desktop.yml new file mode 100644 index 0000000..c0993b9 --- /dev/null +++ b/.github/workflows/desktop.yml @@ -0,0 +1,34 @@ +name: Build/release + +on: push + +jobs: + release: + runs-on: ${{ matrix.os }} + + strategy: + matrix: + os: [macos-latest, ubuntu-latest, windows-latest] + + steps: + - name: Check out Git repository + uses: actions/checkout@v1 + + - name: Install Node.js, NPM and Yarn + uses: actions/setup-node@v1 + with: + node-version: 10 + + - name: Build/release Electron app + uses: samuelmeuli/action-electron-builder@v1 + with: + # GitHub token, automatically provided to the action + # (No need to define this secret in the repo settings) + github_token: ${{ secrets.github_token }} + + # If the commit is tagged with a version (e.g. "v1.0.0"), + # release the app after building + release: ${{ startsWith(github.ref, 'refs/tags/v') }} + package_root: "./frontend", + use_vue_cli: true, + build_script_name: "electron:build" \ No newline at end of file diff --git a/backend/migrations/20220802105441-removeOldUserColumns.js b/backend/migrations/20220802105441-removeOldUserColumns.js new file mode 100644 index 0000000..d36e98b --- /dev/null +++ b/backend/migrations/20220802105441-removeOldUserColumns.js @@ -0,0 +1,17 @@ +"use strict" + +module.exports = { + async up(queryInterface, Sequelize) { + await queryInterface.removeColumn("Users", "guidedWizard") + await queryInterface.removeColumn("Users", "emailDirectLogin") + }, + + async down(queryInterface, Sequelize) { + /** + * Add reverting commands here. + * + * Example: + * await queryInterface.dropTable('users'); + */ + } +} diff --git a/backend/models/users.js b/backend/models/users.js index 8ec451b..9246ceb 100644 --- a/backend/models/users.js +++ b/backend/models/users.js @@ -64,11 +64,6 @@ module.exports = (sequelize, DataTypes) => { allowNull: true, defaultValue: null }, - guidedWizard: { - type: DataTypes.BOOLEAN, - allowNull: false, - defaultValue: true - }, privacy: { type: DataTypes.JSON, defaultValue: { @@ -99,11 +94,6 @@ module.exports = (sequelize, DataTypes) => { allowNull: false, defaultValue: false }, - emailDirectLogin: { - type: DataTypes.BOOLEAN, - allowNull: false, - defaultValue: false - }, email: { type: DataTypes.STRING, allowNull: true, diff --git a/frontend/package.json b/frontend/package.json index 5d2bfd5..ac1801f 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,6 +1,6 @@ { "name": "colubrina", - "version": "1.0.11", + "version": "1.0.12", "private": true, "author": "Troplo ", "scripts": { diff --git a/frontend/src/assets/styles.css b/frontend/src/assets/styles.css index 27d6d4f..c256ec7 100644 --- a/frontend/src/assets/styles.css +++ b/frontend/src/assets/styles.css @@ -1,3 +1,13 @@ +.offset-message { + padding-left: 47px; +} +.message-action-card { + position: absolute; + top: 0; + right: 0; + margin-top: 5px; + margin-right: 5px; +} /* large codeblock */ code { background-color: var(--v-bg-base) !important; diff --git a/frontend/src/components/CommsInput.vue b/frontend/src/components/CommsInput.vue index 023fbd2..03102d1 100644 --- a/frontend/src/components/CommsInput.vue +++ b/frontend/src/components/CommsInput.vue @@ -19,7 +19,11 @@
-
+ @@ -764,7 +837,8 @@ export default { "index", "show", "setImagePreview", - "deleteMessage" + "deleteMessage", + "lastMessage" ], components: { CommsInput, diff --git a/frontend/src/main.js b/frontend/src/main.js index 5ab37ca..bc66a24 100644 --- a/frontend/src/main.js +++ b/frontend/src/main.js @@ -18,26 +18,13 @@ import "highlight.js/styles/github.css" const md = require("markdown-it")({ html: false, // Enable HTML tags in source xhtmlOut: false, // Use '/' to close single tags (
). - // This is only for full CommonMark compatibility. breaks: true, // Convert '\n' in paragraphs into
langPrefix: "language-", // CSS language prefix for fenced blocks. Can be - // useful for external highlighters. linkify: true, // Autoconvert URL-like text to links - - // Enable some language-neutral replacement + quotes beautification - // For the full list of replacements, see https://github.com/markdown-it/markdown-it/blob/master/lib/rules_core/replacements.js typographer: false, - // Double + single quotes replacement pairs, when typographer enabled, - // and smartquotes on. Could be either a String or an Array. - // - // For example, you can use '«»„“' for Russian, '„“‚‘' for German, - // and ['«\xA0', '\xA0»', '‹\xA0', '\xA0›'] for French (including nbsp). quotes: "“”‘’", - // Highlighter function. Should return escaped HTML, - // or '' if the source string is not changed and should be escaped externally. - // If result starts with ", "") + .replaceAll("

", "
") } }) if (process.env.NODE_ENV === "development") { diff --git a/frontend/src/views/Communications/CommunicationsChat.vue b/frontend/src/views/Communications/CommunicationsChat.vue index 60b9909..9e3c1c5 100644 --- a/frontend/src/views/Communications/CommunicationsChat.vue +++ b/frontend/src/views/Communications/CommunicationsChat.vue @@ -1,5 +1,5 @@