PromucFlow_constructor/app/client/src/pages/Applications/ForkModalStyles.ts

61 lines
1.2 KiB
TypeScript
Raw Normal View History

import styled from "styled-components";
import Button from "components/ads/Button";
import RadioComponent from "components/ads/Radio";
import { getTypographyByKey } from "constants/DefaultTheme";
import Dialog from "components/ads/DialogComponent";
import { Classes } from "@blueprintjs/core";
const TriggerButton = styled(Button)`
${(props) => getTypographyByKey(props, "btnLarge")}
height: 100%;
svg {
transform: rotate(-90deg);
}
`;
const StyledDialog = styled(Dialog)`
&& .${Classes.DIALOG_BODY} {
padding-top: 0px;
}
`;
const StyledRadioComponent = styled(RadioComponent)`
label {
font-size: 16px;
margin-bottom: 32px;
}
`;
Feature/import applications (#4483) * Added export option to app menu. TODO: call api to download app file * Added checkbox component and removed unused code * Added import app without filepicker. Opens modal * added ability to fetch the exported app * can download exported application as a json file * Updated the file picker component to accept other file formats * WIP import app * Added functionality to import application json file * minor fixes * Made the file type prop mandatory for file picker * added a test suite for export app * Test added to check if on import application click, it open a modal * added a dummy application file for cypress testing * Added end to end integration test suite to verify import app feature * added test to verify the export api status and download file. * added a linked btn to carry exporting. - according to latest BE changes * Removed old redux and saga mechanism for app export * updated cypress test to validate new flow * fixed minor linting errors * updated test case title * updated the test cases for import/export app feat * review changes * added prop to facilitate delayed upload * added new application file to fixtures. Minor fix to take care of loading state. * Removed export app modal. Added one click action, to download the file. * Updated File picker to work with all other files acc to the design. * Updated the import modal * updated the import application test * Added remove upload tooltip * updated the icons for import/export actions * removed unused logs * added hard coded feature flag to hide/show import export feature Co-authored-by: Pranav Kanade <pranav@appsmith.com>
2021-06-03 06:18:08 +00:00
const ForkButton = styled(Button)<{ disabled?: boolean }>`
height: 38px;
width: 203px;
Feature/import applications (#4483) * Added export option to app menu. TODO: call api to download app file * Added checkbox component and removed unused code * Added import app without filepicker. Opens modal * added ability to fetch the exported app * can download exported application as a json file * Updated the file picker component to accept other file formats * WIP import app * Added functionality to import application json file * minor fixes * Made the file type prop mandatory for file picker * added a test suite for export app * Test added to check if on import application click, it open a modal * added a dummy application file for cypress testing * Added end to end integration test suite to verify import app feature * added test to verify the export api status and download file. * added a linked btn to carry exporting. - according to latest BE changes * Removed old redux and saga mechanism for app export * updated cypress test to validate new flow * fixed minor linting errors * updated test case title * updated the test cases for import/export app feat * review changes * added prop to facilitate delayed upload * added new application file to fixtures. Minor fix to take care of loading state. * Removed export app modal. Added one click action, to download the file. * Updated File picker to work with all other files acc to the design. * Updated the import modal * updated the import application test * Added remove upload tooltip * updated the icons for import/export actions * removed unused logs * added hard coded feature flag to hide/show import export feature Co-authored-by: Pranav Kanade <pranav@appsmith.com>
2021-06-03 06:18:08 +00:00
pointer-events: ${(props) => (!!props.disabled ? "none" : "auto")};
`;
const OrganizationList = styled.div`
overflow: auto;
max-height: 250px;
margin-bottom: 10px;
margin-top: 20px;
`;
const ButtonWrapper = styled.div`
display: flex;
justify-content: flex-end;
`;
const SpinnerWrapper = styled.div`
display: flex;
justify-content: center;
`;
export {
TriggerButton,
StyledDialog,
StyledRadioComponent,
ForkButton,
OrganizationList,
ButtonWrapper,
SpinnerWrapper,
};