Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Carries the Prettier basics into editors that do not run Prettier on save.
root = true

[*]
charset = utf-8
end_of_line = lf
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false
55 changes: 55 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Bug report
description: Something in the React wrapper is not working
labels: [bug]
body:
- type: markdown
attributes:
value: |
This repository is the **React wrapper**. Questions about the editor
itself, your Unlayer account, or AI Assistant entitlements are better
raised with Unlayer support — see the links when you go back.
- type: textarea
id: what-happened
attributes:
label: What happened?
description: What did you expect, and what happened instead?
validations:
required: true
- type: textarea
id: repro
attributes:
label: Steps to reproduce
description: A minimal example is worth far more than a description.
placeholder: |
1. Render <ImageEditor image="..." options={{ ... }} />
2. ...
validations:
required: true
- type: input
id: version
attributes:
label: '@unlayer/react-image-editor version'
placeholder: 1.0.2
validations:
required: true
- type: input
id: react-version
attributes:
label: React version
placeholder: 19.2.7
validations:
required: true
- type: input
id: environment
attributes:
label: Browser / framework
description: Include the framework if relevant (Next.js App Router, Vite, CRA...).
placeholder: Chrome 140, Next.js 15 App Router
validations:
required: true
- type: textarea
id: console
attributes:
label: Console output
description: Any errors logged by the wrapper or passed to onError.
render: shell
8 changes: 8 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
blank_issues_enabled: true
contact_links:
- name: Unlayer support
url: https://unlayer.com/contact
about: Account, billing, AI Assistant entitlements, or the editor itself (not the React wrapper).
- name: Unlayer documentation
url: https://docs.unlayer.com
about: Editor options, features and configuration reference.
21 changes: 21 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Feature request
description: Suggest an improvement to the React wrapper
labels: [enhancement]
body:
- type: textarea
id: problem
attributes:
label: What problem does this solve?
description: Describe the situation you are stuck in, not only the solution you have in mind.
validations:
required: true
- type: textarea
id: proposal
attributes:
label: Proposed API
description: If you have a shape in mind, sketch it.
render: jsx
- type: textarea
id: alternatives
attributes:
label: Alternatives you have tried
16 changes: 16 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
## What and why

<!-- What changes, and what problem it solves. Link the issue: Fixes #123 -->

## How it was verified

<!-- Tests added, manual steps, screenshots for demo/UI changes. -->

## Checklist

- [ ] Commit messages follow [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/)
- [ ] `npm run lint`, `npm run typecheck` and `npm test` pass
- [ ] Coverage is still 100% (`npm run test:coverage`)
- [ ] New or changed props are documented in the README
- [ ] Any new dependency is pinned exact (no `^` / `~`)
- [ ] No `console.log` / `console.debug`
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
22
58 changes: 58 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# Contributor Covenant Code of Conduct

## Our Pledge

We as members, contributors, and leaders pledge to make participation in our
community a harassment-free experience for everyone, regardless of age, body
size, visible or invisible disability, ethnicity, sex characteristics, gender
identity and expression, level of experience, education, socio-economic status,
nationality, personal appearance, race, caste, color, religion, or sexual
identity and orientation.

We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.

## Our Standards

Examples of behavior that contributes to a positive environment:

- Demonstrating empathy and kindness toward other people
- Being respectful of differing opinions, viewpoints, and experiences
- Giving and gracefully accepting constructive feedback
- Accepting responsibility and apologizing to those affected by our mistakes
- Focusing on what is best for the overall community

Examples of unacceptable behavior:

- The use of sexualized language or imagery, and sexual attention or advances
- Trolling, insulting or derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or email address,
without their explicit permission
- Other conduct which could reasonably be considered inappropriate in a
professional setting

## Enforcement Responsibilities

Community leaders are responsible for clarifying and enforcing these standards
and will take appropriate and fair corrective action in response to any behavior
that they deem inappropriate, threatening, offensive, or harmful.

## Scope

This Code of Conduct applies within all community spaces, and also applies when
an individual is officially representing the community in public spaces.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the maintainers responsible for enforcement by opening a report
through GitHub. All complaints will be reviewed and investigated promptly and
fairly. Community leaders are obligated to respect the privacy and security of
the reporter of any incident.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant](https://www.contributor-covenant.org),
version 2.1, available at
https://www.contributor-covenant.org/version/2/1/code_of_conduct.html.
31 changes: 31 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Security Policy

## Supported versions

Security fixes land on the latest released minor version. Please upgrade to the
latest release before reporting.

## Reporting a vulnerability

**Please do not open a public issue for a security report.**

Use GitHub's private vulnerability reporting instead:
[Report a vulnerability](https://github.com/unlayer/react-image-editor/security/advisories/new).
That opens a private advisory visible only to you and the maintainers.

Please include:

- the version of `@unlayer/react-image-editor` affected
- a description of the issue and its impact
- steps to reproduce, ideally a minimal example
- any suggested mitigation

You can expect an acknowledgement within a few business days. We will keep you
updated as we work on a fix, and will credit you in the advisory unless you ask
otherwise.

## Scope

This repository is the React wrapper. It loads the Unlayer Image Editor from a
CDN at runtime, so issues in the editor itself, or in Unlayer's hosted APIs, are
outside this repository — report those to Unlayer directly.
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,7 @@
"format": "prettier --write .",
"prepare": "npm run build",
"prepublishOnly": "npm run lint && npm run typecheck && npm test",
"release": "npm run build && npm publish",
"netlify-build": "cd demo && npm install && npm run build"
"release": "npm run build && npm publish"
},
"peerDependencies": {
"react": ">=18"
Expand Down