Merge pull request #57 from fsih/convertDep

Use scratch fork of paper
This commit is contained in:
DD Liu 2017-10-14 19:34:19 -04:00 committed by GitHub
commit f2e090e293
23 changed files with 23 additions and 22 deletions

View file

@ -27,6 +27,7 @@
"react-dom": "^16"
},
"devDependencies": {
"@scratch/paper": "~0.11.6",
"autoprefixer": "7.1.2",
"babel-cli": "6.26.0",
"babel-core": "^6.23.1",

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import log from '../../log/log';
import BroadBrushHelper from './broad-brush-helper';
import SegmentBrushHelper from './segment-brush-helper';

View file

@ -1,5 +1,5 @@
// Broadbrush based on http://paperjs.org/tutorials/interaction/working-with-mouse-vectors/
import paper from 'paper';
import paper from '@scratch/paper';
import {stylePath} from '../../helper/style-path';
/**

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import {stylePath} from '../../helper/style-path';
/**

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import PropTypes from 'prop-types';
import React from 'react';
import {connect} from 'react-redux';

View file

@ -11,7 +11,7 @@ import {performUndo, performRedo, performSnapshot} from '../helper/undo';
import Modes from '../modes/modes';
import {connect} from 'react-redux';
import bindAll from 'lodash.bindall';
import paper from 'paper';
import paper from '@scratch/paper';
class PaintEditor extends React.Component {
constructor (props) {

View file

@ -2,7 +2,7 @@ import bindAll from 'lodash.bindall';
import PropTypes from 'prop-types';
import React from 'react';
import {connect} from 'react-redux';
import paper from 'paper';
import paper from '@scratch/paper';
import {performSnapshot} from '../helper/undo';
import {undoSnapshot} from '../reducers/undo';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import PropTypes from 'prop-types';
import React from 'react';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import {getRootItem, isGroupItem} from './item';
import {clearSelection, getSelectedRootItems, setItemSelection} from './selection';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import {getGuideLayer} from './layer';
import {getAllRootItems} from './selection';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import {isBoundsItem, getRootItem} from './item';
import {hoverBounds, hoverItem} from './guides';
import {isGroupChild} from './group';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
const getRootItem = function (item) {
if (item.parent.className === 'Layer') {

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
const getGuideLayer = function () {
for (let i = 0; i < paper.project.layers.length; i++) {

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
const checkPointsClose = function (startPos, eventPoint, threshold) {
const xOff = Math.abs(startPos.x - eventPoint.x);

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import keyMirror from 'keymirror';
import {getSelectedRootItems} from '../selection';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import {snapDeltaToAngle} from '../math';
import {clearSelection, getSelectedLeafItems} from '../selection';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import log from '../../log/log';
import keyMirror from 'keymirror';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
/**
* Tool to handle rotation when dragging the rotation handle in the bounding box tool.

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
/**
* Tool to handle scaling items by pulling on the handles around the edges of the bounding

View file

@ -4,7 +4,7 @@ import {getHoveredItem} from '../hover';
import {deleteSelection, selectRootItem} from '../selection';
import BoundingBoxTool from './bounding-box-tool';
import SelectionBoxTool from './selection-box-tool';
import paper from 'paper';
import paper from '@scratch/paper';
/**
* paper.Tool that handles select mode. This is made up of 2 subtools.

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import Modes from '../modes/modes';
import {getItemsGroup, isGroup} from './group';

View file

@ -1,4 +1,4 @@
import paper from 'paper';
import paper from '@scratch/paper';
import {getSelectedLeafItems} from './selection';
import {isPGTextItem, isPointTextItem} from './item';
import {isGroup} from './group';

View file

@ -1,6 +1,6 @@
// undo functionality
// modifed from https://github.com/memononen/stylii
import paper from 'paper';
import paper from '@scratch/paper';
const performSnapshot = function (dispatchPerformSnapshot) {
dispatchPerformSnapshot({