@papillonbits/components 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2022 MTS.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1 @@
1
+ <h1 align="center">Papillon Bits Components</h1>
package/build/index.js ADDED
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "primer", {
7
+ enumerable: true,
8
+ get: function get() {
9
+ return _primer.primer;
10
+ }
11
+ });
12
+
13
+ var _primer = require("./primer");
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.Button = Button;
9
+
10
+ var _classnames = _interopRequireDefault(require("classnames"));
11
+
12
+ var _Button = require("./Button.prop");
13
+
14
+ var _Button2 = _interopRequireDefault(require("./Button.scss"));
15
+
16
+ var _jsxRuntime = require("react/jsx-runtime");
17
+
18
+ function Button(_ref) {
19
+ var className = _ref.className,
20
+ text = _ref.text;
21
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)("button", {
22
+ className: (0, _classnames["default"])(className, _Button2["default"].btn),
23
+ type: "button",
24
+ children: text
25
+ });
26
+ }
27
+
28
+ Button.propTypes = _Button.propTypes;
29
+ Button.defaultProps = _Button.defaultProps;
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.propTypes = exports.defaultProps = void 0;
7
+
8
+ var _propTypes = require("prop-types");
9
+
10
+ var propTypes = {
11
+ className: _propTypes.string,
12
+ text: _propTypes.string.isRequired
13
+ };
14
+ exports.propTypes = propTypes;
15
+ var defaultProps = {
16
+ className: null
17
+ };
18
+ exports.defaultProps = defaultProps;
@@ -0,0 +1,27 @@
1
+ @import './misc.scss';
2
+ @import '../index.scss';
3
+
4
+ .btn {
5
+ position: relative;
6
+ display: inline-block;
7
+ line-height: 20px;
8
+ white-space: nowrap;
9
+ vertical-align: middle;
10
+ cursor: pointer;
11
+ user-select: none;
12
+ appearance: none;
13
+
14
+ &:hover {
15
+ text-decoration: none;
16
+ }
17
+
18
+ &:disabled,
19
+ &.disabled,
20
+ &[aria-disabled='true'] {
21
+ cursor: default;
22
+
23
+ .octicon {
24
+ color: inherit;
25
+ }
26
+ }
27
+ }
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "Button", {
7
+ enumerable: true,
8
+ get: function get() {
9
+ return _Button.Button;
10
+ }
11
+ });
12
+
13
+ var _Button = require("./Button");
@@ -0,0 +1,24 @@
1
+ .btn-link {
2
+ display: inline-block;
3
+ padding: 0;
4
+ font-size: inherit;
5
+ text-decoration: none;
6
+ white-space: nowrap;
7
+ cursor: pointer;
8
+ user-select: none;
9
+ background-color: transparent;
10
+ border: 0;
11
+ appearance: none;
12
+
13
+ &:hover {
14
+ text-decoration: underline;
15
+ }
16
+
17
+ &:disabled,
18
+ &[aria-disabled='true'] {
19
+ &,
20
+ &:hover {
21
+ cursor: default;
22
+ }
23
+ }
24
+ }
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.primer = void 0;
7
+
8
+ var _Button = require("./Button");
9
+
10
+ var primer = {
11
+ Button: {
12
+ Button: _Button.Button
13
+ }
14
+ };
15
+ exports.primer = primer;
@@ -0,0 +1,6 @@
1
+ @mixin inactive {
2
+ pointer-events: none;
3
+ color: $gray-200;
4
+ cursor: not-allowed;
5
+ user-select: none;
6
+ }
package/package.json ADDED
@@ -0,0 +1,32 @@
1
+ {
2
+ "name": "@papillonbits/components",
3
+ "version": "0.1.0",
4
+ "description": "Papillon Bits Components",
5
+ "homepage": "https://github.com/papillonbits/papillonbits/tree/master/packages/components",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "https://github.com/papillonbits/papillonbits.git",
9
+ "directory": "packages/components"
10
+ },
11
+ "main": "build/index.js",
12
+ "module": "src/index.js",
13
+ "files": [
14
+ "build",
15
+ "README.md"
16
+ ],
17
+ "scripts": {
18
+ "clean-up": "rm -rf build node_modules package-lock.json",
19
+ "install-packages": "npm install",
20
+ "install-papillonbits-latest": "npm i \"@papillonbits/css\"@latest && npm i \"@papillonbits/library\"@latest",
21
+ "remove-test-folders": "rm -rf src/**/**/__tests__ && rm -rf src/**/**/**/__tests__ && rm -rf src/primer/Concept",
22
+ "remove-snapshot-folders": "rm -rf src/**/**/__tests__/__snapshots__",
23
+ "remove-build-folder": "rm -rf build",
24
+ "transpile": "babel --copy-files --no-copy-ignored --out-dir build src --ignore **/__tests__",
25
+ "remove-markdown-files": "find build -maxdepth 3 -type f -name \"*.md\" -delete",
26
+ "build": "npm-run-all remove-snapshot-folders remove-build-folder transpile remove-markdown-files",
27
+ "build-test": "npm run build",
28
+ "build-acceptance": "npm run build",
29
+ "build-release": "npm run build"
30
+ },
31
+ "gitHead": "d1d69160a726db6045ba81b79c29ba9d00e2b631"
32
+ }