Code Monkey home page Code Monkey logo

code-medium's People

Contributors

maluen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

code-medium's Issues

Support Substack

The extension is great for doing code blocks in Medium. Any thoughts on supporting Substack, or do you know a similar solution to substack?

[Feature] option to display popup on the side

First of all, thanks for an amazing extension!

I often find it useful to be able to see the article I'm editing while creating the gist. Currently, the popup is positioned in the middle of the screen and overlays the majority of the content. There could be an option to move the popup in the empty area of the page (to the left or to the right of the content) and make sure that the content of the article is still selectable. This way I'd be able to copy-paste things from the article into the gist.

Gist content not loaded on double click

I have been using Code-Medium for a while (thanks for a great tool!).

Recently, modifying a gist stopped working properly.
When I double click an existing gist when editing my story, the code-medium interface appears but completely empty.
The "View on Github" button still works, though.

I get the following error:

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'content')
    at App.js:2:2522360

The json object of the gist being retrieved:

{
    "url": "https://api.github.com/gists/b85b9abae5c2efea5835addfcb827f67",
    "forks_url": "https://api.github.com/gists/b85b9abae5c2efea5835addfcb827f67/forks",
    "commits_url": "https://api.github.com/gists/b85b9abae5c2efea5835addfcb827f67/commits",
    "id": "b85b9abae5c2efea5835addfcb827f67",
    "node_id": "G_kwDOAAPQAdoAIGI4NWI5YWJhZTVjMmVmZWE1ODM1YWRkZmNiODI3ZjY3",
    "git_pull_url": "https://gist.github.com/b85b9abae5c2efea5835addfcb827f67.git",
    "git_push_url": "https://gist.github.com/b85b9abae5c2efea5835addfcb827f67.git",
    "html_url": "https://gist.github.com/b85b9abae5c2efea5835addfcb827f67",
    "files": {
        "mocking-with-mockk.kt": {
            "filename": "mocking-with-mockk.kt",
            "type": "text/plain",
            "language": "Kotlin",
            "raw_url": "https://gist.githubusercontent.com/SalomonBrys/b85b9abae5c2efea5835addfcb827f67/raw/00c6dae9c142f190c1b7b846e6a43e3bf6ac883f/mocking-with-mockk.kt",
            "size": 128,
            "truncated": false,
            "content": "val repo = mockk<Repository>()\nevery { repo.getUser(id = any()) } returns fakeUser()\n\nassertEquals(fakeUser(), repo.getUser(42))"
        }
    },
    "public": false,
    "created_at": "2022-01-10T18:42:00Z",
    "updated_at": "2022-01-10T18:51:14Z",
    "description": "",
    "comments": 0,
    "user": null,
    "comments_url": "https://api.github.com/gists/b85b9abae5c2efea5835addfcb827f67/comments",
    "owner": {
        "login": "SalomonBrys",
        "id": 249857,
        "node_id": "MDQ6VXNlcjI0OTg1Nw==",
        "avatar_url": "https://avatars.githubusercontent.com/u/249857?v=4",
        "gravatar_id": "",
        "url": "https://api.github.com/users/SalomonBrys",
        "html_url": "https://github.com/SalomonBrys",
        "followers_url": "https://api.github.com/users/SalomonBrys/followers",
        "following_url": "https://api.github.com/users/SalomonBrys/following{/other_user}",
        "gists_url": "https://api.github.com/users/SalomonBrys/gists{/gist_id}",
        "starred_url": "https://api.github.com/users/SalomonBrys/starred{/owner}{/repo}",
        "subscriptions_url": "https://api.github.com/users/SalomonBrys/subscriptions",
        "organizations_url": "https://api.github.com/users/SalomonBrys/orgs",
        "repos_url": "https://api.github.com/users/SalomonBrys/repos",
        "events_url": "https://api.github.com/users/SalomonBrys/events{/privacy}",
        "received_events_url": "https://api.github.com/users/SalomonBrys/received_events",
        "type": "User",
        "site_admin": false
    },
    "forks": [],
    "history": [
        {
            "user": {
                "login": "SalomonBrys",
                "id": 249857,
                "node_id": "MDQ6VXNlcjI0OTg1Nw==",
                "avatar_url": "https://avatars.githubusercontent.com/u/249857?v=4",
                "gravatar_id": "",
                "url": "https://api.github.com/users/SalomonBrys",
                "html_url": "https://github.com/SalomonBrys",
                "followers_url": "https://api.github.com/users/SalomonBrys/followers",
                "following_url": "https://api.github.com/users/SalomonBrys/following{/other_user}",
                "gists_url": "https://api.github.com/users/SalomonBrys/gists{/gist_id}",
                "starred_url": "https://api.github.com/users/SalomonBrys/starred{/owner}{/repo}",
                "subscriptions_url": "https://api.github.com/users/SalomonBrys/subscriptions",
                "organizations_url": "https://api.github.com/users/SalomonBrys/orgs",
                "repos_url": "https://api.github.com/users/SalomonBrys/repos",
                "events_url": "https://api.github.com/users/SalomonBrys/events{/privacy}",
                "received_events_url": "https://api.github.com/users/SalomonBrys/received_events",
                "type": "User",
                "site_admin": false
            },
            "version": "bd383f0b464434ea01e90785fc24e420775da5d0",
            "committed_at": "2022-01-10T18:51:14Z",
            "change_status": {
                "total": 4,
                "additions": 3,
                "deletions": 1
            },
            "url": "https://api.github.com/gists/b85b9abae5c2efea5835addfcb827f67/bd383f0b464434ea01e90785fc24e420775da5d0"
        },
        {
            "user": {
                "login": "SalomonBrys",
                "id": 249857,
                "node_id": "MDQ6VXNlcjI0OTg1Nw==",
                "avatar_url": "https://avatars.githubusercontent.com/u/249857?v=4",
                "gravatar_id": "",
                "url": "https://api.github.com/users/SalomonBrys",
                "html_url": "https://github.com/SalomonBrys",
                "followers_url": "https://api.github.com/users/SalomonBrys/followers",
                "following_url": "https://api.github.com/users/SalomonBrys/following{/other_user}",
                "gists_url": "https://api.github.com/users/SalomonBrys/gists{/gist_id}",
                "starred_url": "https://api.github.com/users/SalomonBrys/starred{/owner}{/repo}",
                "subscriptions_url": "https://api.github.com/users/SalomonBrys/subscriptions",
                "organizations_url": "https://api.github.com/users/SalomonBrys/orgs",
                "repos_url": "https://api.github.com/users/SalomonBrys/repos",
                "events_url": "https://api.github.com/users/SalomonBrys/events{/privacy}",
                "received_events_url": "https://api.github.com/users/SalomonBrys/received_events",
                "type": "User",
                "site_admin": false
            },
            "version": "a032c65d2abe1a0d007192d396c2cf018c6a88bf",
            "committed_at": "2022-01-10T18:46:51Z",
            "change_status": {
                "total": 2,
                "additions": 1,
                "deletions": 1
            },
            "url": "https://api.github.com/gists/b85b9abae5c2efea5835addfcb827f67/a032c65d2abe1a0d007192d396c2cf018c6a88bf"
        },
        {
            "user": {
                "login": "SalomonBrys",
                "id": 249857,
                "node_id": "MDQ6VXNlcjI0OTg1Nw==",
                "avatar_url": "https://avatars.githubusercontent.com/u/249857?v=4",
                "gravatar_id": "",
                "url": "https://api.github.com/users/SalomonBrys",
                "html_url": "https://github.com/SalomonBrys",
                "followers_url": "https://api.github.com/users/SalomonBrys/followers",
                "following_url": "https://api.github.com/users/SalomonBrys/following{/other_user}",
                "gists_url": "https://api.github.com/users/SalomonBrys/gists{/gist_id}",
                "starred_url": "https://api.github.com/users/SalomonBrys/starred{/owner}{/repo}",
                "subscriptions_url": "https://api.github.com/users/SalomonBrys/subscriptions",
                "organizations_url": "https://api.github.com/users/SalomonBrys/orgs",
                "repos_url": "https://api.github.com/users/SalomonBrys/repos",
                "events_url": "https://api.github.com/users/SalomonBrys/events{/privacy}",
                "received_events_url": "https://api.github.com/users/SalomonBrys/received_events",
                "type": "User",
                "site_admin": false
            },
            "version": "de330dc4602a34cef88176cc8a37a5b4060e034a",
            "committed_at": "2022-01-10T18:42:00Z",
            "change_status": {
                "total": 2,
                "additions": 2,
                "deletions": 0
            },
            "url": "https://api.github.com/gists/b85b9abae5c2efea5835addfcb827f67/de330dc4602a34cef88176cc8a37a5b4060e034a"
        }
    ],
    "truncated": false
}

Gist is failed to be created

I might be mistaken, but I think there's an issue with the extension.

When trying to create a gist, I get an error in the UI:

Gist creation failed: {}

image

Looking in the console I see the following:
image

Please have a look if you have time.

Save the Gist when pressing Ctrl + S

Great plugin, thanks!

It would be quite neat if when editing a Gist, pressing Ctrl + S "saved" the Gist (effectively simulating the "update gist" button).

Medium itself does this when writing an article (pressing Ctrl + S will "save" the article").

Thanks!

Not working

Hello, since a few weeks I'm not able to use the extension withing Medium. The icon to add the codes doesn't appears. How can I fix this problem? Thanks.

Click on the app button causes no action

Extension doesn't work. No any action after clicking on the extension's icon. No errors in the console. Extension is activated, link "options" is deactivated.
Chrome 97.0.4692.71 x64

[Suggestion] Keyboard Shortcut?

This extension is exactly what I was looking for! Thanks for doing this. I was wondering if we can assign shortcut keys to insert Github Gists using this extension? Medium already has some for text (e.g., CMD+OPTION+1 => Heading 1). It'd be nice to have something like CMD+OPT+0 => Insert Gist.

Security-untrustful GitHub login window

When I install the extension and click "GitHub login" a popup window appears asking for GitHub credentials. The popup window doesn't have an addressbar, F11 (page inspect) doesn't work. How can I know it's real, not phished GitHub login window?

And also: IMHO this windows shouldn't even appear at all, I'm already logged in to GitHub, the extension could simply use cookie.

Browser: Chrome
OS: Kubuntu 20

Edition tool takes too much space on large screens

This bug started at 0.5.3

Screenshot 2022-01-11 at 13 05 20

As you can see in the screenshot, on large (2K) monitors, the code medium UI now takes more space than it needs, shrinking unnecessarily the Medium blog editor.

Clicking anywhere in the gray space around the code editor closes the editor.

Manifest V3

The extension should be ported from current MV2 to MV3. Deadline is January 2023, after which Chrome will stop running MV2 extensions, or at least prevent new installations and updates.

See https://developer.chrome.com/docs/extensions/mv3/intro/

The current chrome MV3 implementation is still bugged in some areas and some other APIs might change, so it's probably better to hold off on publishing until things are more stable. Work and testing can be done on a separate branch for now.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.