3
0
فهرست منبع

Merge branch 'master' of http://git.onarbooks.com/Klapi/TrapiLib

sxoinas12 5 سال پیش
والد
کامیت
dc6eae88e3

+ 1 - 0
.gitignore

@@ -8,3 +8,4 @@ npm-debug.*
 *.orig.*
 web-build/
 web-report/
+dist/

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/lib/Module.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/lib/systems/ViewSystem.js


+ 1 - 1
dist/modules/BaseContainer/index.js

@@ -1 +1 @@
-"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=BaseContainer;var _extends2=_interopRequireDefault(require("@babel/runtime/helpers/extends"));var _objectWithoutProperties2=_interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));var _react=_interopRequireDefault(require("react"));var _reactNative=require("react-native");var _Types=_interopRequireDefault(require("../../lib/Types"));var _jsxFileName="C:\\Users\\Konstanitnos\\Development\\TrapiLib\\modules\\BaseContainer\\index.js";function BaseContainer(props){var selected=props.selected,width=props.width,height=props.height,restProps=(0,_objectWithoutProperties2["default"])(props,["selected","width","height"]);if(!width)width=BaseContainer.Inputs.width["default"];if(!height)height=BaseContainer.Inputs.height["default"];return _react["default"].createElement(_reactNative.View,(0,_extends2["default"])({},restProps,{style:{width:width,height:height},__source:{fileName:_jsxFileName,lineNumber:16}}));}BaseContainer.Inputs={width:new _Types["default"].Integer().require()["default"](50),height:new _Types["default"].Integer().require()["default"](50)};
+"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=BaseContainer;var _extends2=_interopRequireDefault(require("@babel/runtime/helpers/extends"));var _objectWithoutProperties2=_interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));var _react=_interopRequireDefault(require("react"));var _reactNative=require("react-native");var _Types=_interopRequireDefault(require("../../lib/Types"));var _jsxFileName="C:\\Users\\Karteri\\Desktop\\Development\\TrapiLib\\modules\\BaseContainer\\index.js";function BaseContainer(props){var selected=props.selected,width=props.width,height=props.height,overflow=props.overflow,restProps=(0,_objectWithoutProperties2["default"])(props,["selected","width","height","overflow"]);if(!width)width=BaseContainer.Inputs.width["default"];if(!height)height=BaseContainer.Inputs.height["default"];return _react["default"].createElement(_reactNative.View,(0,_extends2["default"])({},restProps,{style:{width:width,height:height,overflow:overflow},__source:{fileName:_jsxFileName,lineNumber:17}}));}BaseContainer.Inputs={width:new _Types["default"].Integer().require()["default"](50),height:new _Types["default"].Integer().require()["default"](50),overflow:new _Types["default"].Integer().require()["default"]('hidden')};

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/modules/BaseHolder/index.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/modules/Button/index.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/modules/Col.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/modules/DatePicker.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/modules/Form/index.js


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/modules/Image/index.js


+ 1 - 1
dist/modules/RootComp/index.js

@@ -1 +1 @@
-"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Types=_interopRequireDefault(require("../../lib/Types"));var _Module2=_interopRequireDefault(require("../../lib/Module"));var _reactNative=require("react-native");var _jsxFileName="C:\\Users\\Konstanitnos\\Development\\TrapiLib\\modules\\RootComp\\index.js";var RootComp=function(_Module){(0,_inherits2["default"])(RootComp,_Module);function RootComp(props){(0,_classCallCheck2["default"])(this,RootComp);return(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(RootComp).call(this,props));}(0,_createClass2["default"])(RootComp,[{key:"display",value:function display(){return;_react["default"].createElement(_reactNative.Text,{__source:{fileName:_jsxFileName,lineNumber:14}},this.props.text||""," - ",this.props.second);}}]);return RootComp;}(_Module2["default"]);exports["default"]=RootComp;RootComp.Inputs={text:new _Types["default"].Text().require()["default"]("Sample Text"),second:new _Types["default"].Integer().require()["default"](5)};
+"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Types=_interopRequireDefault(require("../../lib/Types"));var _Module2=_interopRequireDefault(require("../../lib/Module"));var _reactNative=require("react-native");var _jsxFileName="C:\\Users\\Karteri\\Desktop\\Development\\TrapiLib\\modules\\RootComp\\index.js";var RootComp=function(_Module){(0,_inherits2["default"])(RootComp,_Module);function RootComp(props){(0,_classCallCheck2["default"])(this,RootComp);return(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(RootComp).call(this,props));}(0,_createClass2["default"])(RootComp,[{key:"display",value:function display(){return;_react["default"].createElement(_reactNative.Text,{__source:{fileName:_jsxFileName,lineNumber:14}},this.props.text||""," - ",this.props.second);}}]);return RootComp;}(_Module2["default"]);exports["default"]=RootComp;RootComp.Inputs={text:new _Types["default"].Text().require()["default"]("Sample Text"),second:new _Types["default"].Integer().require()["default"](5)};

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 0 - 0
dist/modules/Row.js


+ 1 - 1
dist/modules/Text/index.js

@@ -1 +1 @@
-"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Module2=_interopRequireDefault(require("../../lib/Module"));var _reactNative=require("react-native");var _Types=_interopRequireDefault(require("../../lib/Types"));var _jsxFileName="C:\\Users\\Konstanitnos\\Development\\TrapiLib\\modules\\Text\\index.js";var TextComp=function(_Module){(0,_inherits2["default"])(TextComp,_Module);function TextComp(props){var _this;(0,_classCallCheck2["default"])(this,TextComp);_this=(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(TextComp).call(this,props));_this.state={text:props.text||""};return _this;}(0,_createClass2["default"])(TextComp,[{key:"display",value:function display(){var _this$props=this.props,text=_this$props.text,color=_this$props.color,fontSize=_this$props.fontSize;return _react["default"].createElement(_reactNative.View,{__source:{fileName:_jsxFileName,lineNumber:21}},_react["default"].createElement(_reactNative.Text,{style:{color:color,fontSize:fontSize},__source:{fileName:_jsxFileName,lineNumber:22}},text),this.props.children);}}]);return TextComp;}(_Module2["default"]);exports["default"]=TextComp;TextComp.Inputs={text:new _Types["default"].Text()["default"]("Enter Text"),color:new _Types["default"].Text(),fontSize:new _Types["default"].Integer()["default"](22)};
+"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Module2=_interopRequireDefault(require("../../lib/Module"));var _reactNative=require("react-native");var _Types=_interopRequireDefault(require("../../lib/Types"));var _jsxFileName="C:\\Users\\Karteri\\Desktop\\Development\\TrapiLib\\modules\\Text\\index.js";var TextComp=function(_Module){(0,_inherits2["default"])(TextComp,_Module);function TextComp(props){var _this;(0,_classCallCheck2["default"])(this,TextComp);_this=(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(TextComp).call(this,props));_this.state={text:props.text||""};return _this;}(0,_createClass2["default"])(TextComp,[{key:"display",value:function display(){var _this$props=this.props,text=_this$props.text,color=_this$props.color,fontSize=_this$props.fontSize;return _react["default"].createElement(_reactNative.View,{__source:{fileName:_jsxFileName,lineNumber:21}},_react["default"].createElement(_reactNative.Text,{style:{color:color,fontSize:fontSize},__source:{fileName:_jsxFileName,lineNumber:22}},text),this.props.children);}}]);return TextComp;}(_Module2["default"]);exports["default"]=TextComp;TextComp.Inputs={text:new _Types["default"].Text()["default"]("Enter Text"),color:new _Types["default"].Text(),fontSize:new _Types["default"].Integer()["default"](22)};

+ 1 - 1
dist/modules/View.js

@@ -1 +1 @@
-"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Module2=_interopRequireDefault(require("../lib/Module"));var _reactNative=require("react-native");var _jsxFileName="C:\\Users\\Konstanitnos\\Development\\TrapiLib\\modules\\View.js";var ViewComp=function(_Module){(0,_inherits2["default"])(ViewComp,_Module);function ViewComp(props){(0,_classCallCheck2["default"])(this,ViewComp);return(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(ViewComp).call(this,props));}(0,_createClass2["default"])(ViewComp,[{key:"display",value:function display(){return _react["default"].createElement(_reactNative.View,{__source:{fileName:_jsxFileName,lineNumber:16}},this.props.children);}}]);return ViewComp;}(_Module2["default"]);exports["default"]=ViewComp;
+"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Module2=_interopRequireDefault(require("../lib/Module"));var _reactNative=require("react-native");var _jsxFileName="C:\\Users\\Karteri\\Desktop\\Development\\TrapiLib\\modules\\View.js";var ViewComp=function(_Module){(0,_inherits2["default"])(ViewComp,_Module);function ViewComp(props){(0,_classCallCheck2["default"])(this,ViewComp);return(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(ViewComp).call(this,props));}(0,_createClass2["default"])(ViewComp,[{key:"display",value:function display(){return _react["default"].createElement(_reactNative.View,{__source:{fileName:_jsxFileName,lineNumber:16}},this.props.children);}}]);return ViewComp;}(_Module2["default"]);exports["default"]=ViewComp;

+ 1 - 1
dist/modules/ViewComp.js

@@ -1 +1 @@
-"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Module2=_interopRequireDefault(require("../lib/Module"));var _reactNative=require("react-native");var _jsxFileName="C:\\Users\\Konstanitnos\\Development\\TrapiLib\\modules\\ViewComp.js";var ViewComp=function(_Module){(0,_inherits2["default"])(ViewComp,_Module);function ViewComp(props){(0,_classCallCheck2["default"])(this,ViewComp);return(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(ViewComp).call(this,props));}(0,_createClass2["default"])(ViewComp,[{key:"display",value:function display(){return _react["default"].createElement(_reactNative.View,{key:Math.random(),__source:{fileName:_jsxFileName,lineNumber:16}});}}]);return ViewComp;}(_Module2["default"]);exports["default"]=ViewComp;
+"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _react=_interopRequireDefault(require("react"));var _Module2=_interopRequireDefault(require("../lib/Module"));var _reactNative=require("react-native");var _jsxFileName="C:\\Users\\Karteri\\Desktop\\Development\\TrapiLib\\modules\\ViewComp.js";var ViewComp=function(_Module){(0,_inherits2["default"])(ViewComp,_Module);function ViewComp(props){(0,_classCallCheck2["default"])(this,ViewComp);return(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(ViewComp).call(this,props));}(0,_createClass2["default"])(ViewComp,[{key:"display",value:function display(){return _react["default"].createElement(_reactNative.View,{key:Math.random(),__source:{fileName:_jsxFileName,lineNumber:16}});}}]);return ViewComp;}(_Module2["default"]);exports["default"]=ViewComp;

+ 1 - 2
lib/systems/ViewSystem.js

@@ -88,9 +88,8 @@ export default class ViewSystem {
 export class View {
 	constructor(){
 		this.ViewTree = new Tree();
-		let rootNode = new Node(Math.random(), {stretchContainer: true, selected: true}); // row
+		let rootNode = new Node(Math.random(), {stretchContainer: false, selected: true}); // row
 		this.addViewNode(rootNode);
-		// this.setColumns(rootNode, 1);
 		this.defaultContainer = rootNode;
 	}
 

+ 4 - 2
modules/BaseContainer/index.js

@@ -8,12 +8,13 @@ export default function BaseContainer(props) {
 		selected,
 		width,
 		height,
+		overflow,
 		...restProps
 	} = props;
 	if(!width) width = BaseContainer.Inputs.width.default;
 	if(!height) height = BaseContainer.Inputs.height.default;
 	return (
-	    <View {...restProps} style={{width, height}}>
+	    <View {...restProps} style={{width, height, overflow}}>
 	    </View>
 	);
 }
@@ -21,5 +22,6 @@ export default function BaseContainer(props) {
 
 BaseContainer.Inputs = {
 	width: new Types.Integer().require().default(50),
-	height: new Types.Integer().require().default(50)
+	height: new Types.Integer().require().default(50),
+	overflow: new Types.Integer().require().default('hidden')
 }

+ 2 - 1
package.json

@@ -6,7 +6,8 @@
     "ios": "expo start --ios",
     "web": "expo start --web",
     "eject": "expo eject",
-    "transpile": "rm dist -rf && babel lib --out-dir dist/lib --copy-files --ignore __tests__,spec.js,test.js,__snapshots__ && babel modules --out-dir dist/modules --copy-files --ignore __tests__,spec.js,test.js,__snapshots__"
+    "transpile": "rm dist -rf && babel lib --out-dir dist/lib --copy-files --ignore __tests__,spec.js,test.js,__snapshots__ && babel modules --out-dir dist/modules --copy-files --ignore __tests__,spec.js,test.js,__snapshots__",
+    "postinstall" : "rm dist -rf && babel lib --out-dir dist/lib --copy-files --ignore __tests__,spec.js,test.js,__snapshots__ && babel modules --out-dir dist/modules --copy-files --ignore __tests__,spec.js,test.js,__snapshots__"
   },
   "dependencies": {
     "expo": "^34.0.0-experiment.8",

برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است