@atlaskit/link-create 0.0.1

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/CHANGELOG.md ADDED
@@ -0,0 +1 @@
1
+ # @atlaskit/link-create
package/LICENSE.md ADDED
@@ -0,0 +1,13 @@
1
+ Copyright 2022 Atlassian Pty Ltd
2
+
3
+ Licensed under the Apache License, Version 2.0 (the "License");
4
+ you may not use this file except in compliance with the License.
5
+ You may obtain a copy of the License at
6
+
7
+ http://www.apache.org/licenses/LICENSE-2.0
8
+
9
+ Unless required by applicable law or agreed to in writing, software
10
+ distributed under the License is distributed on an "AS IS" BASIS,
11
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ See the License for the specific language governing permissions and
13
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,9 @@
1
+ # LinkCreate
2
+
3
+ The driver component of meta creation flow
4
+
5
+ ## Usage
6
+
7
+ `import LinkCreate from '@atlaskit/link-create';`
8
+
9
+ Detailed docs and example usage can be found [here](https://atlaskit.atlassian.com/packages/linking-platform/link-create).
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ Object.defineProperty(exports, "default", {
8
+ enumerable: true,
9
+ get: function get() {
10
+ return _linkCreate.default;
11
+ }
12
+ });
13
+ var _linkCreate = _interopRequireDefault(require("./ui/link-create"));
@@ -0,0 +1,41 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = LinkCreate;
7
+ var _react = require("@emotion/react");
8
+ var _colors = require("@atlaskit/theme/colors");
9
+ /** @jsx jsx */
10
+
11
+ var containerStyles = (0, _react.css)({
12
+ padding: '8px',
13
+ border: '1px solid',
14
+ borderRadius: '4px'
15
+ });
16
+ var unselectedStyles = (0, _react.css)({
17
+ borderColor: "var(--ds-border, ".concat(_colors.N50, ")"),
18
+ ':hover': {
19
+ backgroundColor: "var(--ds-background-neutral-hovered, ".concat(_colors.N20, ")")
20
+ }
21
+ });
22
+ var selectedStyles = (0, _react.css)({
23
+ backgroundColor: "var(--ds-background-selected, ".concat(_colors.B50, ")"),
24
+ borderColor: "var(--ds-border-selected, ".concat(_colors.B400, ")"),
25
+ color: "var(--ds-text-selected, ".concat(_colors.B400, ")"),
26
+ ':hover': {
27
+ backgroundColor: "var(--ds-background-selected-hovered, ".concat(_colors.B75, ")")
28
+ }
29
+ });
30
+ function LinkCreate(_ref) {
31
+ var isSelected = _ref.isSelected,
32
+ testId = _ref.testId,
33
+ width = _ref.width;
34
+ return (0, _react.jsx)("div", {
35
+ style: {
36
+ width: width
37
+ },
38
+ css: [containerStyles, isSelected ? selectedStyles : unselectedStyles],
39
+ "data-testid": testId
40
+ }, "Hello world");
41
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
@@ -0,0 +1,5 @@
1
+ {
2
+ "name": "@atlaskit/link-create",
3
+ "version": "0.0.1",
4
+ "sideEffects": false
5
+ }
@@ -0,0 +1 @@
1
+ export { default } from './ui/link-create';
@@ -0,0 +1,35 @@
1
+ /** @jsx jsx */
2
+ import { css, jsx } from '@emotion/react';
3
+ import { B400, B50, B75, N20, N50 } from '@atlaskit/theme/colors';
4
+ const containerStyles = css({
5
+ padding: '8px',
6
+ border: '1px solid',
7
+ borderRadius: '4px'
8
+ });
9
+ const unselectedStyles = css({
10
+ borderColor: `var(--ds-border, ${N50})`,
11
+ ':hover': {
12
+ backgroundColor: `var(--ds-background-neutral-hovered, ${N20})`
13
+ }
14
+ });
15
+ const selectedStyles = css({
16
+ backgroundColor: `var(--ds-background-selected, ${B50})`,
17
+ borderColor: `var(--ds-border-selected, ${B400})`,
18
+ color: `var(--ds-text-selected, ${B400})`,
19
+ ':hover': {
20
+ backgroundColor: `var(--ds-background-selected-hovered, ${B75})`
21
+ }
22
+ });
23
+ export default function LinkCreate({
24
+ isSelected,
25
+ testId,
26
+ width
27
+ }) {
28
+ return jsx("div", {
29
+ style: {
30
+ width
31
+ },
32
+ css: [containerStyles, isSelected ? selectedStyles : unselectedStyles],
33
+ "data-testid": testId
34
+ }, "Hello world");
35
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,5 @@
1
+ {
2
+ "name": "@atlaskit/link-create",
3
+ "version": "0.0.1",
4
+ "sideEffects": false
5
+ }
@@ -0,0 +1 @@
1
+ export { default } from './ui/link-create';
@@ -0,0 +1,34 @@
1
+ /** @jsx jsx */
2
+ import { css, jsx } from '@emotion/react';
3
+ import { B400, B50, B75, N20, N50 } from '@atlaskit/theme/colors';
4
+ var containerStyles = css({
5
+ padding: '8px',
6
+ border: '1px solid',
7
+ borderRadius: '4px'
8
+ });
9
+ var unselectedStyles = css({
10
+ borderColor: "var(--ds-border, ".concat(N50, ")"),
11
+ ':hover': {
12
+ backgroundColor: "var(--ds-background-neutral-hovered, ".concat(N20, ")")
13
+ }
14
+ });
15
+ var selectedStyles = css({
16
+ backgroundColor: "var(--ds-background-selected, ".concat(B50, ")"),
17
+ borderColor: "var(--ds-border-selected, ".concat(B400, ")"),
18
+ color: "var(--ds-text-selected, ".concat(B400, ")"),
19
+ ':hover': {
20
+ backgroundColor: "var(--ds-background-selected-hovered, ".concat(B75, ")")
21
+ }
22
+ });
23
+ export default function LinkCreate(_ref) {
24
+ var isSelected = _ref.isSelected,
25
+ testId = _ref.testId,
26
+ width = _ref.width;
27
+ return jsx("div", {
28
+ style: {
29
+ width: width
30
+ },
31
+ css: [containerStyles, isSelected ? selectedStyles : unselectedStyles],
32
+ "data-testid": testId
33
+ }, "Hello world");
34
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,5 @@
1
+ {
2
+ "name": "@atlaskit/link-create",
3
+ "version": "0.0.1",
4
+ "sideEffects": false
5
+ }
@@ -0,0 +1 @@
1
+ export { default } from './ui/link-create';
@@ -0,0 +1,4 @@
1
+ /** @jsx jsx */
2
+ import { jsx } from '@emotion/react';
3
+ import { LinkCreateProps } from './types';
4
+ export default function LinkCreate({ isSelected, testId, width, }: LinkCreateProps): jsx.JSX.Element;
@@ -0,0 +1,15 @@
1
+ export interface LinkCreateProps {
2
+ /**
3
+ * When `true` LinkCreate will appear selected.
4
+ */
5
+ isSelected?: boolean;
6
+ /**
7
+ * A `testId` prop is provided for specified elements, which is a unique
8
+ * string that appears as a data attribute `data-testid` in the rendered code,
9
+ * serving as a hook for automated tests */
10
+ testId?: string;
11
+ /**
12
+ * Width of LinkCreate.
13
+ */
14
+ width?: number;
15
+ }
package/package.json ADDED
@@ -0,0 +1,82 @@
1
+ {
2
+ "name": "@atlaskit/link-create",
3
+ "version": "0.0.1",
4
+ "description": "The driver component of meta creation flow",
5
+ "author": "Atlassian Pty Ltd",
6
+ "license": "Apache-2.0",
7
+ "publishConfig": {
8
+ "registry": "https://registry.npmjs.org/"
9
+ },
10
+ "atlassian": {
11
+ "team": "Linking Platform",
12
+ "inPublicMirror": false,
13
+ "releaseModel": "continuous",
14
+ "website": {
15
+ "name": "LinkCreate"
16
+ }
17
+ },
18
+ "repository": "https://bitbucket.org/atlassian/atlassian-frontend",
19
+ "main": "dist/cjs/index.js",
20
+ "module": "dist/esm/index.js",
21
+ "module:es2019": "dist/es2019/index.js",
22
+ "types": "dist/types/index.d.ts",
23
+ "sideEffects": false,
24
+ "atlaskit:src": "src/index.ts",
25
+ "af:exports": {
26
+ ".": "./src/index.ts"
27
+ },
28
+ "dependencies": {
29
+ "@atlaskit/theme": "^12.2.0",
30
+ "@atlaskit/tokens": "^1.1.0",
31
+ "@babel/runtime": "^7.0.0",
32
+ "@emotion/react": "^11.7.1"
33
+ },
34
+ "peerDependencies": {
35
+ "react": "^16.8.0"
36
+ },
37
+ "devDependencies": {
38
+ "@atlaskit/docs": "*",
39
+ "@atlaskit/ssr": "*",
40
+ "@atlaskit/visual-regression": "*",
41
+ "@atlaskit/webdriver-runner": "*",
42
+ "@atlassian/atlassian-frontend-prettier-config-1.0.0": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.0",
43
+ "@testing-library/react": "^12.1.5",
44
+ "react-dom": "^16.8.0",
45
+ "typescript": "4.5.5",
46
+ "wait-for-expect": "^1.2.0"
47
+ },
48
+ "techstack": {
49
+ "@atlassian/frontend": {
50
+ "code-structure": [
51
+ "tangerine-next"
52
+ ],
53
+ "import-structure": [
54
+ "atlassian-conventions"
55
+ ],
56
+ "circular-dependencies": [
57
+ "file-and-folder-level"
58
+ ]
59
+ },
60
+ "@repo/internal": {
61
+ "dom-events": "use-bind-event-listener",
62
+ "analytics": [
63
+ "analytics-next"
64
+ ],
65
+ "theming": [
66
+ "react-context",
67
+ "tokens"
68
+ ],
69
+ "ui-components": [
70
+ "lite-mode"
71
+ ],
72
+ "deprecation": [
73
+ "no-deprecated-imports"
74
+ ],
75
+ "styling": [
76
+ "static",
77
+ "emotion"
78
+ ]
79
+ }
80
+ },
81
+ "prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.0"
82
+ }
package/report.api.md ADDED
@@ -0,0 +1,50 @@
1
+ <!-- API Report Version: 2.3 -->
2
+
3
+ ## API Report File for "@atlaskit/link-create"
4
+
5
+ > Do not edit this file. This report is auto-generated using [API Extractor](https://api-extractor.com/).
6
+ > [Learn more about API reports](https://hello.atlassian.net/wiki/spaces/UR/pages/1825484529/Package+API+Reports)
7
+
8
+ ### Table of contents
9
+
10
+ - [Main Entry Types](#main-entry-types)
11
+ - [Peer Dependencies](#peer-dependencies)
12
+
13
+ ### Main Entry Types
14
+
15
+ <!--SECTION START: Main Entry Types-->
16
+
17
+ ```ts
18
+ import { jsx } from '@emotion/react';
19
+
20
+ // @public (undocumented)
21
+ function LinkCreate({
22
+ isSelected,
23
+ testId,
24
+ width,
25
+ }: LinkCreateProps): jsx.JSX.Element;
26
+ export default LinkCreate;
27
+
28
+ // @public (undocumented)
29
+ interface LinkCreateProps {
30
+ isSelected?: boolean;
31
+ testId?: string;
32
+ width?: number;
33
+ }
34
+
35
+ // (No @packageDocumentation comment for this package)
36
+ ```
37
+
38
+ <!--SECTION END: Main Entry Types-->
39
+
40
+ ### Peer Dependencies
41
+
42
+ <!--SECTION START: Peer Dependencies-->
43
+
44
+ ```json
45
+ {
46
+ "react": "^16.8.0"
47
+ }
48
+ ```
49
+
50
+ <!--SECTION END: Peer Dependencies-->
@@ -0,0 +1,22 @@
1
+ ## API Report File for "@atlaskit/link-create"
2
+
3
+ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
4
+
5
+ ```ts
6
+
7
+ import { jsx } from '@emotion/react';
8
+
9
+ // @public (undocumented)
10
+ function LinkCreate({ isSelected, testId, width, }: LinkCreateProps): jsx.JSX.Element;
11
+ export default LinkCreate;
12
+
13
+ // @public (undocumented)
14
+ interface LinkCreateProps {
15
+ isSelected?: boolean;
16
+ testId?: string;
17
+ width?: number;
18
+ }
19
+
20
+ // (No @packageDocumentation comment for this package)
21
+
22
+ ```