Skip to content

Commit

Permalink
feat(KeyValue): deprecate component
Browse files Browse the repository at this point in the history
chore: update exported paths

chore(docs): remove docs of deprecated components
  • Loading branch information
mainframev authored and DSil committed Oct 2, 2023
1 parent 9102bfb commit 8b30a98
Show file tree
Hide file tree
Showing 20 changed files with 19 additions and 177 deletions.
53 changes: 0 additions & 53 deletions docs/src/__examples__/KeyValue/DEFAULT.tsx

This file was deleted.

4 changes: 2 additions & 2 deletions docs/src/components/Footer.tsx
@@ -1,6 +1,6 @@
import React from "react";
import styled, { css } from "styled-components";
import { Text, Desktop, Stack, mediaQueries } from "@kiwicom/orbit-components";
import { Text, Stack, Hide, mediaQueries } from "@kiwicom/orbit-components";
import { Link, useStaticQuery, graphql } from "gatsby";

import Switch from "./Switch";
Expand Down Expand Up @@ -61,7 +61,7 @@ const StyledFooterLink = styled(Link)`
`;

function Dot() {
return <Desktop>·</Desktop>;
return <Hide on={["smallMobile", "mediumMobile", "largeMobile", "tablet"]}>·</Hide>;
}

export default function Footer() {
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

2 changes: 1 addition & 1 deletion packages/orbit-components/src/deprecated/Desktop/README.md
Expand Up @@ -3,7 +3,7 @@
To implement Desktop component into your project you'll need to add the import:

```jsx
import Desktop from "@kiwicom/orbit-components/lib/Desktop";
import Desktop from "@kiwicom/orbit-components/lib/deprecated/Desktop";
```

After adding import into your project you can use it simply like:
Expand Down
@@ -1,9 +1,9 @@
import * as React from "react";
import { text, select } from "@storybook/addon-knobs";

import Clock from "../icons/Clock";
import Stack from "../Stack";
import { SPACINGS } from "../utils/layout/consts";
import Clock from "../../icons/Clock";
import Stack from "../../Stack";
import { SPACINGS } from "../../utils/layout/consts";

import KeyValue from ".";

Expand Down
Expand Up @@ -3,7 +3,7 @@
To implement KeyValue component into your project you'll need to add the import:

```jsx
import KeyValue from "@kiwicom/orbit-components/lib/KeyValue";
import KeyValue from "@kiwicom/orbit-components/lib/deprecated/KeyValue";
```

After adding import into your project you can use it simply like:
Expand Down
@@ -1,6 +1,6 @@
import * as React from "react";

import { render, screen } from "../../test-utils";
import { render, screen } from "../../../test-utils";
import KeyValue from "..";

describe("KeyValue", () => {
Expand Down
@@ -1,8 +1,8 @@
// @flow
import * as React from "react";

import type { Globals } from "../common/common.js.flow";
import type { Spacing } from "../Stack/index.js.flow";
import type { Globals } from "../../common/common.js.flow";
import type { Spacing } from "../../Stack/index.js.flow";

export type Props = {|
+label?: React.Node,
Expand Down
Expand Up @@ -3,9 +3,9 @@
import * as React from "react";
import styled, { css } from "styled-components";

import defaultTheme from "../defaultTheme";
import { SPACINGS } from "../utils/layout/consts";
import Text from "../Text";
import defaultTheme from "../../defaultTheme";
import { SPACINGS } from "../../utils/layout/consts";
import Text from "../../Text";
import type { Props } from "./types";

const getSpacing = ({ theme }) => ({
Expand Down
Expand Up @@ -2,8 +2,8 @@
// Project: http://github.com/kiwicom/orbit
import type * as React from "react";

import type * as Common from "../common/types";
import type { Spacing } from "../Stack/types";
import type * as Common from "../../common/types";
import type { Spacing } from "../../Stack/types";

export interface Props extends Common.Globals {
readonly label?: React.ReactNode;
Expand Down
2 changes: 1 addition & 1 deletion packages/orbit-components/src/deprecated/Mobile/README.md
Expand Up @@ -3,7 +3,7 @@
To implement Mobile component into your project you'll need to add the import:

```jsx
import Mobile from "@kiwicom/orbit-components/lib/Mobile";
import Mobile from "@kiwicom/orbit-components/lib/deprecated/Mobile";
```

After adding import into your project you can use it simply like:
Expand Down
6 changes: 3 additions & 3 deletions packages/orbit-components/src/index.ts
Expand Up @@ -19,7 +19,7 @@ export { default as Checkbox } from "./Checkbox";
export { default as ChoiceGroup } from "./ChoiceGroup";
export { default as Collapse } from "./Collapse";
export { default as CountryFlag } from "./CountryFlag";
export { default as Desktop } from "./Desktop";
export { default as Desktop } from "./deprecated/Desktop";
export { default as Dialog } from "./Dialog";
export { default as FeatureIcon } from "./FeatureIcon";
export { default as NotificationBadge } from "./NotificationBadge";
Expand Down Expand Up @@ -74,11 +74,11 @@ export {
ItinerarySegmentStop,
ItinerarySegmentDetail,
} from "./Itinerary";
export { default as KeyValue } from "./KeyValue";
export { default as KeyValue } from "./deprecated/KeyValue";
export { default as List, ListItem } from "./List";
export { default as ListChoice } from "./ListChoice";
export { default as Loading } from "./Loading";
export { default as Mobile } from "./Mobile";
export { default as Mobile } from "./deprecated/Mobile";
export { default as Pagination } from "./Pagination";
export { default as Popover } from "./Popover";
export { default as Radio } from "./Radio";
Expand Down

0 comments on commit 8b30a98

Please sign in to comment.