Giter Site home page Giter Site logo

kommitters / editorjs-inline-image Goto Github PK

View Code? Open in Web Editor NEW
92.0 92.0 30.0 16.54 MB

Unsplash inline images plugin for editorjs

Home Page: https://www.npmjs.com/package/editorjs-inline-image

License: MIT License

JavaScript 92.77% CSS 7.23%
editorjs editorjs-plugin hacktoberfest javascript unsplash

editorjs-inline-image's People

Contributors

akash187 avatar brc-dd avatar dependabot[bot] avatar felipeguzmansierra avatar jhonatan-kmt avatar juanhurtado10 avatar juliandsg0222 avatar karolrojas07 avatar mariorodriguezs avatar mauriciosabogal avatar miguelnietoa avatar mrjuangaviriak avatar nickolasjadams avatar renovate[bot] avatar step-security-bot 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  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

editorjs-inline-image's Issues

Please add typescript support

I am working on a big project so I need typescript support . I tried to rewrite the library to typescript but failed . Please write this library in typescript . If you need help , I will also help . Please bro , rewrite this library in typescript .

spesific request image size

Is your feature request related to a problem? Please describe.

How to query a specific image size? Because if I take all the images from Unsplash, some of the images are very tall, I want certain images to be Landscape size.

Provide image select callback

Is your feature request related to a problem? Please describe.

I am trying to change selected image url. The url has some parameters, I have to add 'q' parameter in order to change image quality or fetch compressed image from unsplash

https://unsplash.com/blog/the-5-minute-guide-to-image-quality/

Describe the solution you'd like

I need a callback receiving selected image data and returning changed block data, which will be given to the editor for rendering. In other words, we can add callback, which will be called after image select action and before giving the block data to the editor
Screenshot 2022-11-19 at 17 29 25

Describe alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

Additional context

Add any other context or screenshots about the feature request here.

Add read-only mode support

Context

The recent EditorJS version has included a readOnly property. Ref.

Objective

To add support to this new property

Security Policy violation SECURITY.md

This issue was automatically created by Allstar.

Security Policy Violation
Security policy not enabled.
A SECURITY.md file can give users information about what constitutes a vulnerability and how to report one securely so that information about a bug is not publicly visible. Examples of secure reporting methods include using an issue tracker with private issue support, or encrypted email with a published key.

To fix this, add a SECURITY.md file that explains how to handle vulnerabilities found in your repository. Go to https://github.com/kommitters/editorjs-inline-image/security/policy to enable.

For more information, see https://docs.github.com/en/code-security/getting-started/adding-a-security-policy-to-your-repository.


This issue will auto resolve when the policy is in compliance.

Issue created by Allstar. See https://github.com/ossf/allstar/ for more information. For questions specific to the repository, please contact the owner or maintainer.

🚨 DO NOT LEAK YOUR UNSPLASH API KEYS 🚨

According to unsplash's documentation, you should NOT leave your API keys in client side, like this plugin intends.

I would recommend forking the original code and making your own library

Image zoom when clicked

Is your feature request related to a problem? Please describe.

Could you please add an ability to zoom in the image when clicked?

That would be great if image can be scaled up when user clicks it during read mode.

image

Custom apiUrl Example

Is your feature request related to a problem? Please describe.

Unsplash is great but what if my pictures/images/video are stored on my server/cloud? I see that config.apiUrl can be whatever I want. But how the apiUrl response should look like? Are paths of inserted media relative or absolute? What if I drag and drop a media inside editorjs from the same page (list of available images for example)?

Describe the solution you'd like

Maybe adding a dedicated "Custom apiUrl" section in the README.md including the following:

Expected response example:

{
  "id": "myuniqueid",
  "width": imgwidth,
  "height": imgheight,
  "urls": {
    "full": "articles/1/img/myimage.jpg",
    "thumb": "articles/1/img/myimage_thumb.jpg"
  },
},
{
  "id": "myuniqueid2",
  "width": imgwidth,
  "height": imgheight,
  "urls": {
    "full": "articles/1/img/myimage2.jpg",
    "thumb": "articles/1/img/myimage2_thumb.jpg"
  },
}

other custom apiUrl config options like:
config.imageAddedPath= "absolute/relative",
// option for path option? isn't better for local ressources to have relative paths so it's easier to maintain? host can be adapted on backend (dev server, prod server, amazon bucket, etc...)`

drag and drop from list on the same page:
config.imageDropped= "data or path",
// it would be great to have an option to have the relative path inserted like <img src="/img/example.jpg" instead of having image inserted as <img src="data:image/jpg;base64,...

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.