3

Github GitHub - penge/my-notes: Simple and fast note-taking in Chrome with Googl...

 3 years ago
source link: https://github.com/penge/my-notes
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

My Notes — Web Store

My Notes is a Chrome extension for simple and fast note-taking.

Write down your ideas, notes, todos, and other – all effortlessly while staying in Chrome.

Features

→   All notes quickly accessible in Chrome (How to open)

→   All notes automatically saved and synchronized in every open tab

→   Context menu to save selected text from websites, or transfer selected text to other computer (Context menu)

→   Backup notes to Google Drive or edit them from other devices (Google Drive Sync)

→   Themes (Light, Dark, Custom)

→   Keyboard shortcuts

→   Works offline

How to open

My Notes:

  1. Click on My Notes icon in Chrome Toolbar (pin the icon for quick access)
  2. Use keyboard shortcut (see chrome://extensions/shortcuts)

Options:

  1. Click on gear icon in bottom left corner
  2. Right-click on the pinned icon in Chrome Toolbar and select Options
  3. Click on three-dots icon next to My Notes in Chrome Toolbar and select Options
  4. Use keyboard shortcut (see Options)

Context menu

Context menu allows you to quickly save selected text from any website to My Notes, or to transfer selected text to My Notes in other computer.

To use Context menu, select the text on website, right-click and see "My Notes" Context menu.

Context menu has these options:

  • Save to [note name] – Option for every note. As you create new notes, they are automatically added to the list. My Notes doesn't have to be open. Google Drive Sync is not required.
  • Save to remotely open My Notes – My Notes in other computer needs to be open. Same Google Account needs to be used. Google Drive Sync is not required. The destination note to save the text will be named "@Received" (created automatically if doesn't exist, otherwise updated).

Google Drive Sync

Google Drive Sync (see Options) saves your notes to your personal Google Drive and synchronizes the changes between your local My Notes and your Google Drive every time you hit the Sync button (bottom left corner).

Benefits:

  • backup of notes in your Google Drive
  • notes can be restored in the future if My Notes is re-installed, by re-enabling Google Drive Sync
  • notes can be edited from Google Drive if needed (or from other devices that have access to Google Drive)
  • notes can be edited from other computers where My Notes is installed and Google Drive Sync is enabled (using same Google Account is needed)

Location

Notes are uploaded to your Google Drive to the folder "My Notes". This folder is created automatically. If the folder exists from a previous installation, notes are downloaded and uploaded and the synchronization continues.

Synchronization

Synchronization works in both ways — to Google Drive, from Google Drive.

Notes are synchronized every time you hit the Sync button. While the synchronization is in progress, Sync button will spin. Sync button tooltip shows the time of the most recent synchronization.

Access

My Notes has only access to the folder "My Notes" and only to the files it created in this folder. It cannot see, access or modify any other files in your Google Drive.

Tips and tricks

  1. Set a keyboard shortcut to quickly open My Notes (for example Cmd + Shift + M), which you can set on this page chrome://extensions/shortcuts. If you make the keyboard shortcut Global, it will open My Notes even if Google Chrome is closed.
  2. Check keyboard shortcuts (open Options) on how to quickly do some actions.
  3. Hold down the Shift key (Cmd + Shift + V) to paste text in a plain format (without styles).
  4. Hide Toolbar and Sidebar if you prefer a simple interface.
  5. See Google Fonts for a font you like, write its name into My Notes Options to use it.
  6. Note name is present in the URL, therefore you can save it to bookmarks for quick access (if you append saved URL with &focus, it will always open that note in Focus mode).
  7. Use Context menu to transfer selected text to My Notes in other computer(s).
  8. Use Custom theme to customize the look of My Notes in any way needed.
  9. Drag and Drop text onto a note's name in the Sidebar to insert the text into the note.
  10. Drag the Sidebar line to resize the Sidebar, double-click on the Sidebar line to restore the original Sidebar width.

How to contribute

  1. Share your feedback (what to improve, what to change) under Issues or join the discussion in Discussions.
  2. Buy Me a Coffee.
  3. Develop a feature.
  4. Help to test the upcoming version (to get feedback, to improve or tweak).
  5. Help to improve the documentation.

Folder structure

env/              # Helpers for environment variables

out/              # Bundled My Notes (excluded from Git)

src/
  background/
    google-drive/   # Everything related to Google Drive Sync
                      # - File operations (List, Create, Get, Update, Delete)
                      # - Synchronization (to Google Drive, from Google Drive)
                      # - Queries (find My Notes folder, list files in My Notes folder)
                      # - Multipart bodies (create My Notes folder, create file, update file)
                      # - Tests

    init/           # Run when My Notes is installed/updated
                      # - Sets a Unique ID for My Notes installation (used by Context menu), if not already set
                      # - Migrates notes and options
                      # - Creates Context menu and attaches the events
                      # - Creates a Notification when My Notes is installed/updated
                      # - Registers the ways to open My Notes (icon click, keyboard shortcut)
                      # - Registers events to trigger Google Drive Sync from My Notes

  dom/              # Helpers to get DOM elements

  integration/      # Integration tests for Google Drive Sync

  messages/         # Communication between My Notes and background script

  notes/            # Everything related to Notes
                      # - Create/Rename/Delete notes; Note editing, Note saving
                      # - Toolbar
                      # - Every UI init and update when data changes
                      # - Registers commands (Toggle Focus mode - can be enabled in Options)

  options/          # Everything related to Options
                      # - Font type, Font size, Theme, etc.
                      # - Every UI init and update when data changes

  shared/           # Everything common (used at more places)
                      # - Date formatting (Last sync)
                      # - Managing the permissions (Requesting, Removing, Checking)
                      # - Helpers for Chrome Storage
                      # - Default values (Notes, Options)

  themes/           # Light, Dark, Custom

  background.ts     # Main script for background page
  notes.ts          # Main script for notes
  options.ts        # Main script for options

static/           # All static files (images, icons, HTML, CSS) copied to out/


.editorconfig     # To enforce same editor configuration
.eslintrc         # To enforce code quality and same coding style with ESLint
.eslintignore     # Files excluded from ESLint checking
.gitignore        # Files excluded from Git

jest.config.js    # Jest configuration
tsconfig.json     # Typescript configuration

package-lock.json
package.json

LICENSE           # MIT
manifest.json     # Main extension file

README.md

Browser support

My Notes has full support in Google Chrome only. Although it may be possible to install it in other browsers, the support is not complete.

Support for other Chromium-based browsers will be added if possible.

Security and Privacy

My Notes doesn't collect any personal information or data. All your notes are stored locally in your browser. If you use Google Drive Sync, My Notes can backup the notes to your personal Google Drive.

To provide Google Drive functionality, My Notes has an application in Google Cloud. The sole purpose of this application is to authenticate you securely towards Google Drive and to allow the synchronization of notes.

Permissions

My Notes has the permissions listed in manifest.json.

Required:

  • "storage" — used to save the notes and options to Chrome Storage
  • "contextMenus" — used to create My Notes Context menu

Required permissions are shown to the user before installing the extension, and are needed at all times to provide the basic functionality.

Optional:

  • "identity" — needed for "Enable Google Drive Sync" (see Options)

Optional permissions are needed only to provide additional functionality that can be enabled via a checkbox in Options.

User has the choice to either approve or deny the permissions.

1. Where is My Notes published? What is the process behind publishing My Notes?

My Notes is published on Web Store, a store for Google Chrome extensions. When publishing a new version, I first make a new release here on GitHub. Then I create a build of the new release and send it to Web Store for a review. The review usually takes between 24 hours and a few days. After a successful review, the new version is available on Web Store.

2. Can I install My Notes manually by downloading it from GitHub?

Yes, My Notes can be installed manually by downloading it from GitHub, but keep in mind, that Google Drive Sync works only if My Notes is installed from Web Store. To install My Notes manually, download the zip file of the latest version which you can find here. Then, unpack the downloaded file and install NPM packages followed by npm run build. Finally, open chrome://extensions address in Google Chrome and click the "Load unpacked" button to load the unpacked extension from your drive by selecting the out directory.

3. Google Drive Sync isn't working. What's the cause?

Google Drive Sync works only if My Notes is installed from Web Store and in Google Chrome. The reasons for this are two. First, Google Chrome provides an "identity" API that My Notes relies on. Second, for security reasons, Google Drive Sync works only if My Notes has an ID equal to "lkeeogfaiembcblonahillacpaabmiop", which is the ID it has on Web Store (also in the URL). When My Notes is installed manually, it gets an ID that is different to the one on Web Store.

4. What browsers and operating systems are supported?

Currently, only Google Chrome is supported. Other Chromium-based browsers are next to come, if possible. Any common OS (Windows, Linux, OSX) is supported. Chromebooks are supported as well.

5. How can I open or edit notes from my phone?

If Google Drive Sync is enabled, My Notes will sync your notes to/from your personal Google Drive into a folder "My Notes".

To get access to your Google Drive from a phone, install Google Drive application. To open the note, click on in from the list. To edit the note, click on the three-circles icon next to the note, and select "Open with" from the context menu. You can then chose a preferred editor from the list.

6. What is the size limit for my notes?

Notes are limited to 5MB in total.

This limit comes with the default setting of the browser. In case of interest, future versions of My Notes could be having a new optional "unlimitedStorage" permission, which if enabled, would increase the storage infinitely (as your hard drive allows).

7. Is My Notes for free?

My Notes is available as open-source, free to download, install, and use. Preferred way to install My Notes is from Web Store.


Created with ❤ in 2019.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK