Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(proposal): Improve Drop-in components styles to take 100% of available space #609

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions packages/sdk-drop-in/monite-app-demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,15 @@
html {
margin: 0;
padding: 0;
height: 100%;
width: 100%;
}
</style>
<title>Monite App Widget Label</title>
</head>
<body>
<monite-app
style="height: 100%; width: 100%"
disabled
entity-id="defer"
api-url="defer"
Expand Down Expand Up @@ -48,9 +51,9 @@

<script type="module">
import { createAPIClient } from '@monite/sdk-react';
import { createEntityUsersMyEntityRequestFn } from '@team-monite/sdk-demo';

import { getConfig } from './src/lib/ConfigLoader.tsx';
import { createEntityUsersMyEntityRequestFn } from '@team-monite/sdk-demo';
import { fetchTokenDev } from './src/lib/fetchTokenDev.ts';

window.fetchToken = fetchTokenDev;
Expand All @@ -72,7 +75,7 @@
const moniteAppNode = document.querySelector('monite-app');
moniteAppNode.setAttribute(
'component',
location.pathname.split('/')[2] ?? 'payables'
location.pathname.split('/')[2] ?? 'receivables'
);
moniteAppNode.setAttribute('api-url', apiUrl);
moniteAppNode.setAttribute('entity-id', id);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,14 @@ export abstract class MoniteAppElementBase<
<style>
:host {
display: block;
height: 100%;
width: 100%;
}
#monite-app-root {
display: flex;
flex-direction: column;
height: 100%;
width: 100%;
}
</style>
</div>
Expand Down
Loading