Skip to content

Commit

Permalink
Publish v1.2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
yamankatby committed Nov 23, 2021
1 parent 1975cc6 commit 09131cc
Show file tree
Hide file tree
Showing 18 changed files with 12,610 additions and 8,992 deletions.
2 changes: 1 addition & 1 deletion core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@react-native-material/core",
"version": "1.2.1",
"version": "1.2.2",
"description": "Modular and customizable Material Design UI components for React Native",
"main": "lib/index.js",
"types": "lib/index.d.ts",
Expand Down
1 change: 1 addition & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.yarn
13 changes: 5 additions & 8 deletions docs/blog/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,9 @@ Then start using the power of Material Design in your React Native app.
import React from "react";
import { Button } from "@react-native-material/core";

export default function App() {
return (
<Button
title="Click Me"
style={{ alignSelf: "center", marginTop: 40 }}
/>
);
}
const App = () => (
<Button title="Click Me" style={{ alignSelf: "center", marginTop: 40 }}/>
);

export default App;
```
2 changes: 1 addition & 1 deletion docs/docs/api/activity-indicator.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import ActivityIndicator from "@react-native-material/core/ActivityIndicator";
## Props

```ts
interface ActivityIndicatorProps extends NativeActivityIndicatorProps {
interface ActivityIndicatorProps extends RNActivityIndicatorProps {
color?: PaletteColor;
}

Expand Down
6 changes: 5 additions & 1 deletion docs/docs/api/button.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import Button from "@react-native-material/core/Button";
## Props

```ts
interface ButtonProps extends SurfaceProps {
interface ButtonProps extends Omit<SurfaceProps, "hitSlop">, Omit<PressableProps, "style" | "children"> {
title: string | React.ReactElement | ((props: { color: string }) => React.ReactElement | null) | null;

leading?: React.ReactElement | ((props: { color: string; size: number }) => React.ReactElement | null) | null;
Expand All @@ -38,6 +38,10 @@ interface ButtonProps extends SurfaceProps {

loadingIndicatorPosition?: "leading" | "trailing" | "overlay";

pressableContainerStyle?: StyleProp<ViewStyle>;

contentContainerStyle?: PressableProps["style"];

titleStyle?: StyleProp<TextStyle>;

leadingContainerStyle?: StyleProp<ViewStyle>;
Expand Down
6 changes: 4 additions & 2 deletions docs/docs/api/fab.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import FAB from "@react-native-material/core/FAB";
## Props

```ts
interface FABProps extends SurfaceProps {
interface FABProps extends Omit<SurfaceProps, "hitSlop">, Omit<PressableProps, "style" | "children"> {
icon?: React.ReactElement | ((props: { color: string; size: number }) => React.ReactElement | null) | null;

label?: string | React.ReactElement | ((props: { color: string }) => React.ReactElement | null) | null;
Expand All @@ -34,7 +34,9 @@ interface FABProps extends SurfaceProps {

visible?: boolean;

contentContainerStyle?: StyleProp<ViewStyle>;
pressableContainerStyle?: StyleProp<ViewStyle>;

contentContainerStyle?: PressableProps["style"];

iconContainerStyle?: StyleProp<ViewStyle>;

Expand Down
4 changes: 3 additions & 1 deletion docs/docs/api/icon-button.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,12 @@ import IconButton from "@react-native-material/core/IconButton";
## Props

```ts
interface IconButtonProps extends TouchableProps {
interface IconButtonProps extends Omit<ViewProps, "hitSlop">, Omit<PressableProps, "style" | "children"> {
icon?: React.ReactElement;

color?: PaletteColor;

contentContainerStyle?: PressableProps["style"];
}

```
28 changes: 28 additions & 0 deletions docs/docs/api/pressable.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Pressable

API documentation for the React Native Pressable component. Learn about the available props.

## Import

```js
import { Pressable } from "@react-native-material/core";
// or
import Pressable from "@react-native-material/core/Pressable";
```

## Props

```ts
interface PressableProps extends RNPressableProps {
pressEffect?: "none" | "highlight" | "ripple" | "android-ripple";

pressEffectColor?: string;

onMouseEnter?: () => void;

onMouseLeave?: () => void;

style?: any;
}

```
4 changes: 2 additions & 2 deletions docs/docs/api/surface.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ import Surface from "@react-native-material/core/Surface";
## Props

```ts
interface SurfaceProps extends Omit<TouchableProps, "hitSlop"> {
interface SurfaceProps extends Omit<ViewProps, "style"> {
category?: ShapeCategory;

elevation?: Elevation;

hitSlop?: ViewProps["hitSlop"];
style?: Animated.WithAnimatedValue<StyleProp<ViewStyle>>;
}

```
5 changes: 4 additions & 1 deletion docs/docs/api/switch.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,8 @@ import Switch from "@react-native-material/core/Switch";
## Props

```ts
null
interface SwitchProps extends RNSwitchProps {
tintColor?: PaletteColor;
}

```
2 changes: 1 addition & 1 deletion docs/docs/api/text.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import Text from "@react-native-material/core/Text";
## Props

```ts
interface TextProps extends NativeTextProps {
interface TextProps extends RNTextProps {
variant?: TypographyVariant;
}

Expand Down
42 changes: 0 additions & 42 deletions docs/docs/api/touchable.md

This file was deleted.

24 changes: 11 additions & 13 deletions docs/docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,11 @@ Here's a quick example to get you started, **it's literally all you need**:
import React from "react";
import { Button } from "@react-native-material/core";

export default function App() {
return <Button title="Click Me" onPress={() => alert("🎉🎉🎉")}/>;
}
const App = () => (
<Button title="Click Me" onPress={() => alert("🎉🎉🎉")}/>
);

export default App;
```

Yes, this really is all you need to get started, as you can see in this live and interactive demo:
Expand All @@ -33,15 +35,11 @@ Yes, this really is all you need to get started, as you can see in this live and
import React from "react";
import { Button } from "@react-native-material/core";

export default function App() {
return (
<Button
title="Click Me"
style={{ alignSelf: "center", marginTop: 40 }}
onPress={() => alert("🎉🎉🎉")}
/>
);
}
const App = () => (
<Button title="Click Me" style={{ alignSelf: "center", marginTop: 40 }}/>
);

export default App;
```

## Community help
Expand Down Expand Up @@ -75,4 +73,4 @@ our contribution process.
## License

This library is licensed under the MIT License - see
the [LICENSE](https://github.com/yamankatby/react-native-material/blob/main/LICENSE) file for details.
the [LICENSE](https://github.com/yamankatby/react-native-material/blob/main/LICENSE) file for details.
4 changes: 2 additions & 2 deletions docs/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,9 @@ const darkCodeTheme = require('prism-react-renderer/themes/dracula');
},
{
type: 'dropdown',
label: 'v1.2.1',
label: 'v1.2.2',
items: [
{ label: 'v1.2.1', to: '/' },
{ label: 'v1.2.2', to: '/' },
{
label: 'v1.1.0',
href: 'https://react-native-material-38lpom7xc-yamankatby.vercel.app/docs/getting-started'
Expand Down
2 changes: 1 addition & 1 deletion docs/preview.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const defaults = {
name: "Example",
description: "Simple code example",
dependencies: "@react-native-material/[email protected].1",
dependencies: "@react-native-material/[email protected].2",
loading: "lazy",
supportedPlatforms: "mydevice,ios,android,web",
platform: "web",
Expand Down
Loading

2 comments on commit 09131cc

@vercel
Copy link

@vercel vercel bot commented on 09131cc Nov 23, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vercel
Copy link

@vercel vercel bot commented on 09131cc Nov 23, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.