471 Commits

Author SHA1 Message Date
dependabot[bot]
9020ab3761
chore(deps-dev): bump @babel/core in /src/packages/excalidraw (#3345)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.13.10 to 7.13.13.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.13/packages/babel-core)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-28 13:07:31 +05:30
dependabot[bot]
136f8b2279
chore(deps-dev): bump @babel/core in /src/packages/utils (#3347)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.13.10 to 7.13.13.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.13/packages/babel-core)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-28 13:06:56 +05:30
David Luzar
30ae4b8bf2
feat: don't unnecessarily prompt when installing libraries (#3329) 2021-03-26 18:32:38 +01:00
David Luzar
cf9e29834d
feat: prefer hash when importing libraries & expose importLibrary (#3320) 2021-03-26 18:10:43 +01:00
Riley Schnee
b0d7ff290f
feat: Add option to flip single element on the context menu (#2520)
Co-authored-by: dwelle <luzar.david@gmail.com>
2021-03-26 16:45:08 +01:00
David Luzar
1b626175de
feat: use origin + pathname as libraryReturnUrl default (#3325) 2021-03-25 18:27:40 +01:00
Aakansha Doshi
5ffdd3f32d
docs: Readme tweaks :) (#3319)
* docs: Readme tweaks :)

* update

* fix

* Add info about collab
2021-03-25 21:38:15 +05:30
Aakansha Doshi
86bf2d697d
docs: Release @excalidraw/excalidraw@0.5.0 🎉 (#3289)
* docs: Release @excalidraw/excalidraw@0.5.0

* update changelog

* update readme

* remove styles since github strips the styles in markdown
2021-03-21 19:19:09 +05:30
Aakansha Doshi
7ee8de0a46
feat: set window.name in excalidraw app & also support target for excalidraw libraries (#3299)
* feat: set window.name in excalidraw app so library installation always opens on same tab & also support target for excalidraw libraries

* update changelog and readme

* Update public/index.html

Co-authored-by: David Luzar <luzar.david@gmail.com>

* use level 4 heading

* Update src/packages/excalidraw/README.md

Co-authored-by: David Luzar <luzar.david@gmail.com>

Co-authored-by: David Luzar <luzar.david@gmail.com>
2021-03-21 18:13:52 +05:30
dependabot[bot]
981f327b48
chore(deps-dev): bump css-loader in /src/packages/utils (#3292)
Bumps [css-loader](https://github.com/webpack-contrib/css-loader) from 5.1.2 to 5.1.3.
- [Release notes](https://github.com/webpack-contrib/css-loader/releases)
- [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/css-loader/compare/v5.1.2...v5.1.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-21 12:55:37 +05:30
dependabot[bot]
eeea8406c9
chore(deps-dev): bump css-loader in /src/packages/excalidraw (#3293)
Bumps [css-loader](https://github.com/webpack-contrib/css-loader) from 5.1.2 to 5.1.3.
- [Release notes](https://github.com/webpack-contrib/css-loader/releases)
- [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/css-loader/compare/v5.1.2...v5.1.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-21 12:31:15 +05:30
dependabot[bot]
0f249e3b26
chore(deps-dev): bump webpack in /src/packages/utils (#3294)
Bumps [webpack](https://github.com/webpack/webpack) from 5.24.3 to 5.27.1.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.24.3...v5.27.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-21 12:29:44 +05:30
dependabot[bot]
2c7c80bd75
chore(deps-dev): bump webpack in /src/packages/excalidraw (#3295)
Bumps [webpack](https://github.com/webpack/webpack) from 5.24.3 to 5.27.1.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.24.3...v5.27.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-21 12:21:09 +05:30
Arun
c3ecbcb3ab
feat: Allow host app to update title of drawing (#3273)
* Allow updating name on updateScene

* Revert "Allow updating name on updateScene"

This reverts commit 4e07a608d38a585e0f3c04e26b9f5e0e404824b1.

* Make requested changes

* Make requested changes

* Remove customName from state

* Remove redundant if statement

* Add tests, update changelog and minor fixes

* remove eempty lines

* minor fixes

* no border and on hover no background change

* Give preference to name prop when initialData.appState.name is present and update specs

* minor fix

* Fix name input style in dark mode

Co-authored-by: Aakansha Doshi <aakansha1216@gmail.com>
2021-03-20 16:08:03 +05:30
Aakansha Doshi
de99484a1f
feat: Expose the API to calculate offsets and remove offsetTop and offsetLeft props (#3265)
* feat: Expose the API to calculate offsets and remove offsetTop and offsetLeft props

* update

* fix tests

* fix

* update readme and changelog

* fix

* better
2021-03-20 13:00:49 +05:30
Matias Capeletto
0e3eb3cc63
chore: fix npm to yarn in contributing.md and package.json (#3274)
* chore: fix npm to yarn in contributing.md

* chore: fix npm pack to yarn pack
2021-03-18 22:57:00 +05:30
Aakansha Doshi
052b73d95b
refactor: Rename prop scrollToCenter and setScrollToCenter to scrollToContent and setScrollToContent respectively (#3261)
* refactor: Rename prop scrollToCenter and setScrollToCenter to scrollToContent and setScrollToContent respectively

* fix

* update changelog/readme

* fix
2021-03-16 23:02:17 +05:30
Aakansha Doshi
edc62c550a
feat: Export API's to export the drawing to canvas, svg and blob (#3258)
* feat: Export utilities from package/utils

* update

* fix

* collapsible

* Update README.md

* update change

* update

* fix

* Apply suggestions from code review

Co-authored-by: David Luzar <luzar.david@gmail.com>

* Apply suggestions from code review

Co-authored-by: David Luzar <luzar.david@gmail.com>

* update

* Apply suggestions from code review

Co-authored-by: David Luzar <luzar.david@gmail.com>
2021-03-16 22:21:56 +05:30
Jeremy Press
84a1863233
feat: Add theme prop (#3228)
* support appearance when updating scene data

* works!

* whoops, missed a prop

* hide appearance button when prop is not set

* cleanup

* fix export + rename prop to theme

* rename to showThemeBtn, hide via react instead of css

* adapt to new state name

* add tests and css selector to target the dark mode toggle

* updated changelog and readme

* fix markdown rendering in readme

* pr feedback
2021-03-16 00:03:46 +05:30
dependabot[bot]
fa186c69cb
chore(deps-dev): bump @babel/core from 7.13.8 to 7.13.10 in /src/packages/utils (#3248)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.13.8 to 7.13.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.10/packages/babel-core)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:23:39 +02:00
dependabot[bot]
f2adda46e5
chore(deps-dev): bump ts-loader from 8.0.17 to 8.0.18 in /src/packages/utils (#3246)
Bumps [ts-loader](https://github.com/TypeStrong/ts-loader) from 8.0.17 to 8.0.18.
- [Release notes](https://github.com/TypeStrong/ts-loader/releases)
- [Changelog](https://github.com/TypeStrong/ts-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/TypeStrong/ts-loader/compare/v8.0.17...v8.0.18)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:23:33 +02:00
dependabot[bot]
0786b472cc
chore(deps-dev): bump @babel/preset-env from 7.13.9 to 7.13.10 in /src/packages/utils (#3251)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.13.9 to 7.13.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.10/packages/babel-preset-env)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:23:25 +02:00
dependabot[bot]
15ae64eb7a
chore(deps-dev): bump ts-loader from 8.0.17 to 8.0.18 in /src/packages/excalidraw (#3247)
Bumps [ts-loader](https://github.com/TypeStrong/ts-loader) from 8.0.17 to 8.0.18.
- [Release notes](https://github.com/TypeStrong/ts-loader/releases)
- [Changelog](https://github.com/TypeStrong/ts-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/TypeStrong/ts-loader/compare/v8.0.17...v8.0.18)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:23:18 +02:00
dependabot[bot]
f3b9bd7c1d
chore(deps-dev): bump @babel/plugin-transform-runtime from 7.13.9 to 7.13.10 in /src/packages/utils (#3250)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:23:05 +02:00
dependabot[bot]
eae25329f0
chore(deps-dev): bump css-loader from 5.1.1 to 5.1.2 in /src/packages/utils (#3249)
Bumps [css-loader](https://github.com/webpack-contrib/css-loader) from 5.1.1 to 5.1.2.
- [Release notes](https://github.com/webpack-contrib/css-loader/releases)
- [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/css-loader/compare/v5.1.1...v5.1.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:22:51 +02:00
dependabot[bot]
99de8e79e2
chore(deps-dev): bump @babel/plugin-transform-runtime from 7.13.9 to 7.13.10 in /src/packages/excalidraw (#3245)
Bumps [@babel/plugin-transform-runtime](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-transform-runtime) from 7.13.9 to 7.13.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.10/packages/babel-plugin-transform-runtime)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:22:35 +02:00
dependabot[bot]
adcfaf34de
chore(deps-dev): bump @babel/core from 7.13.8 to 7.13.10 in /src/packages/excalidraw (#3242)
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.13.8 to 7.13.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.10/packages/babel-core)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:21:57 +02:00
dependabot[bot]
04ae836874
chore(deps-dev): bump css-loader from 5.1.1 to 5.1.2 in /src/packages/excalidraw (#3243)
Bumps [css-loader](https://github.com/webpack-contrib/css-loader) from 5.1.1 to 5.1.2.
- [Release notes](https://github.com/webpack-contrib/css-loader/releases)
- [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/css-loader/compare/v5.1.1...v5.1.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:21:40 +02:00
dependabot[bot]
f6ffa7ed45
chore(deps-dev): bump @babel/preset-env from 7.13.9 to 7.13.10 in /src/packages/excalidraw (#3244)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.13.9 to 7.13.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.10/packages/babel-preset-env)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-14 09:21:27 +02:00
Aakansha Doshi
f1daff2437
refactor: Rename appearance to theme (#3237)
* refactor: Rename appearance to theme

* fix

* update changelog

* rename theme_dark to theme--dark

* add about migration
2021-03-13 18:58:06 +05:30
David Luzar
91c8b6ecbf
feat: support libraryReturnUrl when installing libraries (#3227)
Co-authored-by: Aakansha Doshi <aakansha1216@gmail.com>
2021-03-13 12:35:35 +01:00
Aakansha Doshi
47c26cd4cf
docs: release patch version 0.4.3 (#3236) 2021-03-13 01:29:54 +05:30
Aakansha Doshi
6e629383ea
fix: Don't overflow text beyond width of Excalidraw (#3215)
* fix: Don't overflow text beyond width of Excalidraw

* update changelog
2021-03-10 01:49:32 +05:30
Aakansha Doshi
612e71e38b
docs: Remove unreleased link as its already available (#3212) 2021-03-09 21:44:56 +05:30
Aakansha Doshi
00ac804dd8
fix: Allow copy of excalidraw elements only when inside excalidraw (#3206)
* fix: Allow copy event only inside canvas

* use pointerdown

* use document.getSelection

* remove poiterdown

* remove keyTest

* update changelog
2021-03-09 11:52:28 +05:30
Aakansha Doshi
3a0a638a0d
fix: Position text editor absolute and fix the offsets so it doesn't remain fixed when container is scrolled (#3200)
* fix: Position text editor absolute and fix the offsets so it doesn't remain fixed when container is scrolled

* update changelog

* Update src/packages/excalidraw/CHANGELOG.md
2021-03-07 21:12:10 +05:30
Aakansha Doshi
420703ba50
fix: scope css variables so that host css vars don't clash with excalidraw (#3199)
* fix: scope css variables so that host css vars don't clash with excalidraw

* update changelog
2021-03-07 16:41:37 +05:30
dependabot[bot]
4d6ef81c83
chore(deps-dev): bump css-loader from 5.1.0 to 5.1.1 in /src/packages/utils (#3189)
Bumps [css-loader](https://github.com/webpack-contrib/css-loader) from 5.1.0 to 5.1.1.
- [Release notes](https://github.com/webpack-contrib/css-loader/releases)
- [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/css-loader/compare/v5.1.0...v5.1.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 10:44:53 +01:00
dependabot[bot]
88b980a8e0
chore(deps-dev): bump @babel/preset-env from 7.13.8 to 7.13.9 in /src/packages/utils (#3191)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.13.8 to 7.13.9.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.9/packages/babel-preset-env)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 10:44:39 +01:00
dependabot[bot]
d85c1955b4
chore(deps-dev): bump @babel/plugin-transform-runtime from 7.13.8 to 7.13.9 in /src/packages/utils (#3192)
Bumps [@babel/plugin-transform-runtime](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-transform-runtime) from 7.13.8 to 7.13.9.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.9/packages/babel-plugin-transform-runtime)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 10:44:22 +01:00
dependabot[bot]
a27e599798
chore(deps-dev): bump @babel/plugin-transform-runtime (#3190)
Bumps [@babel/plugin-transform-runtime](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-transform-runtime) from 7.13.8 to 7.13.9.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.9/packages/babel-plugin-transform-runtime)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 14:22:28 +05:30
dependabot[bot]
d25ed7bf88
chore(deps-dev): bump @babel/preset-env in /src/packages/excalidraw (#3188)
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.13.8 to 7.13.9.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.13.9/packages/babel-preset-env)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 14:16:52 +05:30
dependabot[bot]
28601b88bd
chore(deps-dev): bump css-loader in /src/packages/excalidraw (#3187)
Bumps [css-loader](https://github.com/webpack-contrib/css-loader) from 5.1.0 to 5.1.1.
- [Release notes](https://github.com/webpack-contrib/css-loader/releases)
- [Changelog](https://github.com/webpack-contrib/css-loader/blob/master/CHANGELOG.md)
- [Commits](https://github.com/webpack-contrib/css-loader/compare/v5.1.0...v5.1.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 14:15:57 +05:30
dependabot[bot]
1edfcc08d8
chore(deps-dev): bump webpack in /src/packages/excalidraw (#3186)
Bumps [webpack](https://github.com/webpack/webpack) from 5.24.2 to 5.24.3.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.24.2...v5.24.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 14:15:03 +05:30
dependabot[bot]
030814c254
chore(deps-dev): bump webpack in /src/packages/utils (#3193)
Bumps [webpack](https://github.com/webpack/webpack) from 5.24.2 to 5.24.3.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.24.2...v5.24.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-07 13:33:35 +05:30
Aakansha Doshi
eb24e8ffe4
fix: Wrap excalidraw in position relative & hide scrollbars in zen mode (#3174)
* fix: wrap excalidraw in position relative so that host need not add it explicitly to fix positioning when non zero offsets

* patch version

* Hide scrollbars on excalidraw container

* remove overflow hidden from index.html since its handled in excalidraw container

* review fix

* update changelog
2021-03-06 20:11:26 +05:30
Aakansha Doshi
07e71a8071
fix: Reduce the scroll debounce timeout to 100ms and update only if offset changes (#3182)
* fix: Reduce the scroll debounce timeout to 100ms so offsets get updated faster when the container scrolled
fixes https://github.com/excalidraw/excalidraw/issues/3175

* update changelog

* update offsets only when if it changes

* up

* Update src/components/App.tsx

Co-authored-by: David Luzar <luzar.david@gmail.com>
2021-03-06 19:06:42 +05:30
Aakansha Doshi
ef792ad906
docs: update readme with codesandbox example when excalidraw embeded via script tag (#3171)
* docs(README.md): update codesandbox example when excalidraw embeded via script tag

* up
2021-03-05 18:02:21 +05:30
Aakansha Doshi
0d2f72f87e
docs(README.md): fix typo excalidrawRef -> ref (#3170) 2021-03-04 20:20:01 +05:30
Aakansha Doshi
3d1cbf444d
fix: Use Array.from when spreading over set so that typescript transpiles correctly in the umd build (#3165)
* fix: Use Array.from when spreading over set so that typescript transpiles correctly in the umd build

* patch version

* fix

* update changelog

* tweak
2021-03-03 19:27:15 +05:30