mirror of
https://github.com/chinchang/web-maker.git
synced 2025-03-21 02:59:42 +01:00
fix assets pro btn
This commit is contained in:
parent
f27894a0f5
commit
f14f366b17
@ -9,7 +9,7 @@ import { LoaderWithText } from './Loader';
|
||||
import { Text } from './Text';
|
||||
import { Icon } from './Icons';
|
||||
|
||||
const Assets = () => {
|
||||
const Assets = ({ onProBtnClick }) => {
|
||||
const [files, setFiles] = useState([]);
|
||||
const [isFetchingFiles, setIsFetchingFiles] = useState(false);
|
||||
const [searchTerm, setSearchTerm] = useState('');
|
||||
@ -161,7 +161,7 @@ const Assets = () => {
|
||||
return (
|
||||
<VStack align="stretch" gap={2}>
|
||||
<p>Assets feature is available in PRO plan.</p>
|
||||
<button class="btn btn--primary ">
|
||||
<button class="btn btn--primary" onClick={onProBtnClick}>
|
||||
<HStack gap={1} fullWidth justify="center">
|
||||
Upgrade to <ProBadge />
|
||||
</HStack>
|
||||
|
@ -68,7 +68,7 @@ export function Pro({ user }) {
|
||||
style="gap:0.2rem"
|
||||
href={`https://web-maker.lemonsqueezy.com/checkout/buy/${
|
||||
checkoutIds[isAnnual ? 'annual' : 'monthly']
|
||||
}?embed=1&checkout[custom][userId]=${user.uid}`}
|
||||
}?embed=1&checkout[custom][userId]=${user?.uid}`}
|
||||
>
|
||||
Go <ProBadge />
|
||||
</A>
|
||||
|
@ -1776,7 +1776,12 @@ export default class App extends Component {
|
||||
show={this.state.isAssetsOpen}
|
||||
closeHandler={() => this.setState({ isAssetsOpen: false })}
|
||||
>
|
||||
<Assets />
|
||||
<Assets
|
||||
onProBtnClick={() => {
|
||||
this.proBtnClickHandler();
|
||||
this.setState({ isAssetsOpen: false });
|
||||
}}
|
||||
/>
|
||||
</Modal>
|
||||
<Modal
|
||||
show={this.state.isNotificationsModalOpen}
|
||||
|
Loading…
x
Reference in New Issue
Block a user