mirror of
https://github.com/chinchang/web-maker.git
synced 2025-07-10 00:16:18 +02:00
fixes
This commit is contained in:
@ -124,7 +124,7 @@ export function Profile({ user, logoutBtnHandler }) {
|
|||||||
{user?.isPro && currentSubscription ? (
|
{user?.isPro && currentSubscription ? (
|
||||||
<img
|
<img
|
||||||
class="profile-modal__panda"
|
class="profile-modal__panda"
|
||||||
src="/assets/pro-panda.png"
|
src="assets/pro-panda.png"
|
||||||
width="300"
|
width="300"
|
||||||
style="position:absolute;bottom:-3rem; right: -7rem;"
|
style="position:absolute;bottom:-3rem; right: -7rem;"
|
||||||
/>
|
/>
|
||||||
|
@ -10,14 +10,16 @@ import { Text } from './Text';
|
|||||||
|
|
||||||
const FREE_PUBLIC_ITEM_COUNT = 1;
|
const FREE_PUBLIC_ITEM_COUNT = 1;
|
||||||
const BASE_URL = location.origin;
|
const BASE_URL = location.origin;
|
||||||
|
const TOGGLE_VISIBILITY_API = !window.location.origin.includes('localhost')
|
||||||
|
? 'http://127.0.0.1:5001/web-maker-app/us-central1/toggleVisibility'
|
||||||
|
: 'https://togglevisibility-ajhkrtmkaq-uc.a.run.app';
|
||||||
export function Share({ user, item, onVisibilityChange, onLoginBtnClick }) {
|
export function Share({ user, item, onVisibilityChange, onLoginBtnClick }) {
|
||||||
const [publicItemCount, setPublicItemCount] = useState(0);
|
const [publicItemCount, setPublicItemCount] = useState(0);
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (!user) return;
|
if (!user) return;
|
||||||
window.db.getPublicItemCount(user.uid).then(c => {
|
window.db.getPublicItemCount(user.uid).then(c => {
|
||||||
setPublicItemCount(c);
|
setPublicItemCount(c);
|
||||||
console.log('public items', c);
|
// console.log('public items', c);
|
||||||
});
|
});
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
@ -30,7 +32,7 @@ export function Share({ user, item, onVisibilityChange, onLoginBtnClick }) {
|
|||||||
let res;
|
let res;
|
||||||
try {
|
try {
|
||||||
res = await fetch(
|
res = await fetch(
|
||||||
`http://127.0.0.1:5001/web-maker-app/us-central1/toggleVisibility?token=${token}&itemId=${item.id}`
|
`${TOGGLE_VISIBILITY_API}?token=${token}&itemId=${item.id}`
|
||||||
);
|
);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
alertsService.add('Could not change visibility');
|
alertsService.add('Could not change visibility');
|
||||||
|
@ -1153,7 +1153,7 @@ body > #demo-frame {
|
|||||||
top: 0;
|
top: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
width: 35vw;
|
width: 35vw;
|
||||||
min-width: 35ch;
|
min-width: 40ch;
|
||||||
max-width: 60ch;
|
max-width: 60ch;
|
||||||
padding: 20px 30px;
|
padding: 20px 30px;
|
||||||
z-index: 6;
|
z-index: 6;
|
||||||
@ -2185,8 +2185,8 @@ while the theme CSS file is loading */
|
|||||||
.asset-manager__file-ext {
|
.asset-manager__file-ext {
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0.5rem;
|
||||||
right: 0;
|
left: 1.4rem;
|
||||||
letter-spacing: -1px;
|
letter-spacing: -1px;
|
||||||
font-weight: 800;
|
font-weight: 800;
|
||||||
display: none;
|
display: none;
|
||||||
|
Reference in New Issue
Block a user