Skip to content

various fixes #506

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
May 4, 2020
Merged
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
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

This project adheres to [Semantic Versioning](http://semver.org/). Every release, along with the migration instructions, is documented on the Github [Releases](https://github.com/airbnb/react-sketchapp/releases) page.

## Version 3.2.2

- Fix getting the default bridge on NodeJS

## Version 3.2.1

- `Platform.version` now reflects the Sketch version
- Fix a bug for a broken version of `@sketch-hq/sketch-file-format-ts`

## Version 3.2.0

- Add a new `useWindowDimensions` hook for Artboard viewport (#501)
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-sketchapp",
"version": "3.2.0",
"version": "3.2.2",
"description": "A React renderer for Sketch.app",
"sideEffects": false,
"main": "lib/index.js",
Expand Down Expand Up @@ -44,7 +44,7 @@
},
"dependencies": {
"@lona/svg-model": "^2.0.0",
"@sketch-hq/sketch-file-format-ts": "^4.0.3",
"@sketch-hq/sketch-file-format-ts": "4.0.3",
"airbnb-prop-types": "^2.15.0",
"error-stack-parser": "^2.0.6",
"invariant": "^2.2.2",
Expand Down
4 changes: 3 additions & 1 deletion src/Platform.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import { getSketchVersion } from './utils/getSketchVersion';

export const Platform = {
OS: 'sketch',
Version: 1,
Version: getSketchVersion(),
select: (obj: { sketch: any }) => obj.sketch,
};
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {
import { TextStyles as _TextStyles } from './sharedStyles/TextStyles';

function getDefaultPlatformBridge() {
return require('./platformBridges/macos');
return require('./platformBridges/macos').default;
}

export function render(
Expand Down