Skip to content

Dev -> Main v2.4.5 #1094

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

Merged
merged 59 commits into from
Aug 6, 2024
Merged
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
caa36ff
Style Control CHanges
MenamAfzal Jul 25, 2024
3159fc0
Add line Height in Said Components
MenamAfzal Jul 25, 2024
0cf5abd
Improved Translations
MenamAfzal Jul 25, 2024
470afcb
initial code
MenamAfzal Jul 25, 2024
4c8dd4e
Push for debug
MenamAfzal Jul 26, 2024
fb4f140
Increasing Version Numbers to release new SDK and Lowcoder Comps
Jul 26, 2024
9b4dedd
Increasing Version Number to release new SDK
Jul 26, 2024
6a1b7cc
double click handled
MenamAfzal Jul 26, 2024
c5640ad
added lineHeight as css property
MenamAfzal Jul 27, 2024
0bc663b
lineHeight icon added in right panel
MenamAfzal Jul 27, 2024
7459f78
lineHeight icon added in right panel
MenamAfzal Jul 27, 2024
32dc4ec
pull from origin
MenamAfzal Jul 27, 2024
1db61e7
pull from origin
MenamAfzal Jul 27, 2024
52305fe
latest changes
MenamAfzal Jul 27, 2024
35088b8
margin right added
MenamAfzal Jul 27, 2024
4c316ea
Merge branch 'dev' into fix/table-styles
MenamAfzal Jul 27, 2024
8288a82
Updating Stripe and introducing Lowcoder API as Datasource
Jul 27, 2024
d267998
finnal tweaks
MenamAfzal Jul 29, 2024
d52ac6f
Merge branch 'dev' into add/doubleClick
MenamAfzal Jul 29, 2024
4ab618b
Merge branch 'dev' into fix/table-styles
raheeliftikhar5 Jul 29, 2024
1828fba
Merge pull request #1070 from MenamAfzal/add/doubleClick
raheeliftikhar5 Jul 29, 2024
ecc5c8d
Merge branch 'dev' into fix/table-styles
raheeliftikhar5 Jul 29, 2024
df4df7d
Merge pull request #1071 from MenamAfzal/fix/table-styles
raheeliftikhar5 Jul 29, 2024
f8f2872
added app header settings in advanced settings
raheeliftikhar5 Jul 29, 2024
3e4fa6f
Merge branch 'dev' into add/lineHeight
raheeliftikhar5 Jul 29, 2024
7e3b1a9
Merge pull request #1069 from MenamAfzal/add/lineHeight
raheeliftikhar5 Jul 29, 2024
75a9714
fix: javascript queries not executing on page load
raheeliftikhar5 Jul 29, 2024
476943c
Renaming of old Strapi Specs file
Jul 29, 2024
fb90fe3
remove Console Logs in Node Server
Jul 29, 2024
4140a71
table expansion issue resolved
MenamAfzal Jul 30, 2024
fab46dd
shadow issue resolved
MenamAfzal Jul 30, 2024
a4bf6a9
added horizontalGridCells property in inner-grid based comps
raheeliftikhar5 Jul 30, 2024
acb1cb1
Merge branch 'dev' into fix/table
raheeliftikhar5 Jul 30, 2024
0069cbc
Merge pull request #1076 from MenamAfzal/fix/table
raheeliftikhar5 Jul 30, 2024
3ef0e4f
increase debounce time for input changes to avoid jumping cursor
raheeliftikhar5 Jul 31, 2024
4cd85cc
added dropdown type column in table
raheeliftikhar5 Jul 31, 2024
a739e2e
added tooltip option for table header
raheeliftikhar5 Jul 31, 2024
7129ccf
line height removed from single liner input fields
MenamAfzal Aug 1, 2024
e76fd45
added column separator option for downloaded table's csv
raheeliftikhar5 Aug 1, 2024
2ef23dd
added column tooltip in table
raheeliftikhar5 Aug 1, 2024
4e21471
removed tooltip from column types and placed in abstract level for al…
raheeliftikhar5 Aug 2, 2024
1bf4a84
Merge pull request #1083 from lowcoder-org/table-column-tooltip
FalkWolsky Aug 2, 2024
a62f1f2
Merge pull request #1082 from MenamAfzal/remove/lineHeight
FalkWolsky Aug 3, 2024
dfd71b5
Supabase Management API as Data Source
Aug 3, 2024
1c3716c
Cleaning up Data Sources Display
Aug 3, 2024
6043e8f
Sorting Database and Big Data
Aug 3, 2024
78dd346
Fixing Table Column Display Selector & Naming
Aug 3, 2024
11f4073
Reorganized icons - old icons to v1 folder
Aug 3, 2024
ee70a49
Fixing iframely Tag
Aug 3, 2024
6e98446
Fixing iframely Tag for Componet Display
Aug 3, 2024
c7f2c54
fix table scroll behaviour
raheeliftikhar5 Aug 5, 2024
a8f49d0
added horizontal/vertical scrollbar switches
raheeliftikhar5 Aug 6, 2024
f3e96ac
remove commented code
raheeliftikhar5 Aug 6, 2024
575755d
fix select input styles not applying
raheeliftikhar5 Aug 6, 2024
72e7419
fix tree select input styles not applying
raheeliftikhar5 Aug 6, 2024
23149c6
Merge pull request #1093 from lowcoder-org/table-scrollbars
FalkWolsky Aug 6, 2024
1a887bb
Setting Version for 2.4.5 and renaming local storage namespace
Aug 6, 2024
0e04061
fixed table scrollbar issues
raheeliftikhar5 Aug 6, 2024
c000da1
Increasing Versions for v2.4.5
Aug 6, 2024
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
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import {
hiddenPropertyView,
ChangeEventHandlerControl,
DragEventHandlerControl,
CalendarEventHandlerControl,
Section,
sectionNames,
dropdownControl,
Expand All @@ -45,7 +46,9 @@ import {
CalendarDeleteIcon,
Tooltip,
useMergeCompStyles,
} from "lowcoder-sdk";
EditorContext,
CompNameContext,
} from 'lowcoder-sdk';

import {
DefaultWithFreeViewOptions,
Expand Down Expand Up @@ -76,7 +79,7 @@ let childrenMap: any = {
resourcesEvents: jsonValueExposingStateControl("resourcesEvents", resourcesEventsDefaultData),
resources: jsonValueExposingStateControl("resources", resourcesDefaultData),
resourceName: withDefault(StringControl, trans("calendar.resourcesDefault")),
onEvent: ChangeEventHandlerControl,
onEvent: CalendarEventHandlerControl,
// onDropEvent: safeDragEventHandlerControl,
editable: withDefault(BoolControl, true),
showEventTime: withDefault(BoolControl, true),
Expand Down Expand Up @@ -120,6 +123,12 @@ let CalendarBasicComp = (function () {
currentFreeView?: string;
currentPremiumView?: string;
}, dispatch: any) => {

const comp = useContext(EditorContext).getUICompByName(
useContext(CompNameContext)
);
const onEventVal = comp?.toJsonValue().comp.onEvent;


const theme = useContext(ThemeContext);
const ref = createRef<HTMLDivElement>();
Expand Down Expand Up @@ -303,7 +312,12 @@ let CalendarBasicComp = (function () {
};
showModal(eventInfo, true);
} else {
showModal(editEvent.current, false);
if (onEventVal && onEventVal.some((e: any) => e.name === 'doubleClick')) {
// Check if 'doubleClick' is included in the array
props.onEvent('doubleClick');
} else {
showModal(editEvent.current as EventType, false);
}
}
};

Expand Down Expand Up @@ -433,7 +447,6 @@ let CalendarBasicComp = (function () {
props.onDropEvent("dropEvent");
}
};

return (
<Wrapper
ref={ref}
Expand Down
4 changes: 2 additions & 2 deletions client/packages/lowcoder/src/components/PageSkeleton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,12 @@ export default function PageSkeleton(props: IProps) {

return (
<Layout>
{!hideHeader && isHeaderReady && (
{/* {!hideHeader && isHeaderReady && (
<Header
headerStart={<StyledLogoWithName branding={true} />}
style={{ backgroundColor: brandingConfig?.headerColor, ...props.headStyle }}
/>
)}
)} */}
<Layout>
{!hideSideBar && <SideBar>{skeleton}</SideBar>}
<MainContent>{!hideContent && skeleton}</MainContent>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,7 @@ const TableWrapper = styled.div<{

.ant-table.ant-table-middle .ant-table-cell-with-append .ant-table-row-expand-icon {
top: 14px;
margin-right:5px;
}

.ant-table {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -700,6 +700,11 @@ export const DragEventHandlerControl = eventHandlerControl([
dropEvent,
] as const);

export const CalendarEventHandlerControl = eventHandlerControl([
changeEvent,
doubleClickEvent,
] as const);

export const ElementEventHandlerControl = eventHandlerControl([
openEvent,
editedEvent,
Expand Down
4 changes: 3 additions & 1 deletion client/packages/lowcoder/src/i18n/locales/de.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2079,7 +2079,9 @@ export const de: typeof en = {
"preloadLibsAddBtn": "Eine Bibliothek hinzufügen",
"saveSuccess": "Erfolgreich gerettet",
"AuthOrgTitle": "Willkommensbildschirm des Arbeitsbereichs",
"AuthOrgDescrition": "Die URL, unter der sich deine Nutzer beim aktuellen Arbeitsbereich anmelden können."
"AuthOrgDescrition": "Die URL, unter der sich deine Nutzer beim aktuellen Arbeitsbereich anmelden können.",
"showHeaderInPublicApps": "Kopfzeile öffentlich anzeigen",
"showHeaderInPublicAppsHelp": "Legen Sie die Sichtbarkeit des Headers in der öffentlichen Ansicht für alle Apps fest",
},
"branding": {
...en.branding,
Expand Down
5 changes: 3 additions & 2 deletions client/packages/lowcoder/src/i18n/locales/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2601,8 +2601,9 @@ export const en = {
"APIConsumption": "API Consumption",
"APIConsumptionDescription": "Here you can see the API Consumption for All Apps in the Current Workspace.",
"overallAPIConsumption": "Overall API Consumption in this Workspace till now",
"lastMonthAPIConsumption": "Last Month API Consumption, in this Workspace"

"lastMonthAPIConsumption": "Last Month API Consumption, in this Workspace",
"showHeaderInPublicApps": "Show Header In Public View",
"showHeaderInPublicAppsHelp": "Set visibility of header in public view for all apps",
},


Expand Down
4 changes: 3 additions & 1 deletion client/packages/lowcoder/src/i18n/locales/pt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2660,7 +2660,9 @@ export const pt: typeof en = {
"APIConsumption": "Consumo de API",
"APIConsumptionDescription": "Aqui você pode ver o consumo de API para todas as aplicações no espaço de trabalho atual.",
"overallAPIConsumption": "Consumo geral de API neste espaço de trabalho até o momento",
"lastMonthAPIConsumption": "Consumo de API do último mês, neste espaço de trabalho"
"lastMonthAPIConsumption": "Consumo de API do último mês, neste espaço de trabalho",
"showHeaderInPublicApps": "Mostrar cabeçalho em exibição pública",
"showHeaderInPublicAppsHelp": "Defina a visibilidade do cabeçalho em exibição pública para todos os aplicativos",
},


Expand Down
2 changes: 2 additions & 0 deletions client/packages/lowcoder/src/i18n/locales/zh.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2068,6 +2068,8 @@ export const zh: typeof en = {
"APIConsumptionDescription": "API 消耗是指当前工作空间中所有应用程序的 API 消耗情况,包括调用次数和调用时间.",
"overallAPIConsumption": "总体 API 消耗",
"lastMonthAPIConsumption": "上个月 API 消耗",
"showHeaderInPublicApps": "在公共视图中显示标题",
"showHeaderInPublicAppsHelp": "设置所有应用程序的标题在公共视图中的可见性",
},
branding: {
...en.branding,
Expand Down
5 changes: 3 additions & 2 deletions client/packages/lowcoder/src/pages/editor/editorView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ import {
} from "util/localStorageUtil";
import { isAggregationApp } from "util/appUtils";
import EditorSkeletonView from "./editorSkeletonView";
import { getCommonSettings } from "@lowcoder-ee/redux/selectors/commonSettingSelectors";

const LeftContent = lazy(
() => import('./LeftContent')
Expand Down Expand Up @@ -278,6 +279,7 @@ function EditorView(props: EditorViewProps) {
const editorState = useContext(EditorContext);
const { readOnly, hideHeader } = useContext(ExternalEditorContext);
const application = useSelector(currentApplication);
const commonSettings = useSelector(getCommonSettings);
const locationState = useLocation<UserGuideLocationState>().state;
const showNewUserGuide = locationState?.showNewUserGuide;
const showAppSnapshot = useSelector(showAppSnapshotSelector);
Expand Down Expand Up @@ -369,11 +371,10 @@ function EditorView(props: EditorViewProps) {
return () => window.removeEventListener(eventType, updateSize);
}, []);

const hideBodyHeader = useTemplateViewMode() || (isViewMode && !showHeaderInPublic);
const hideBodyHeader = useTemplateViewMode() || (isViewMode && (!showHeaderInPublic || !commonSettings.showHeaderInPublicApps));

// we check if we are on the public cloud
const isLowCoderDomain = window.location.hostname === 'app.lowcoder.cloud';

if (readOnly && hideHeader) {
return (
<CustomShortcutWrapper>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import { getGlobalSettings } from "comps/utils/globalSettings";
import { fetchJSLibrary } from "util/jsLibraryUtils";
import { evalFunc } from "lowcoder-core";
import { messageInstance } from "lowcoder-design/src/components/GlobalInstances";
import { default as Switch } from "antd/es/switch";

const CodeEditor = lazy(
() => import("base/codeEditor/codeEditor")
Expand Down Expand Up @@ -186,6 +187,34 @@ export function AdvancedSetting() {
{trans("advanced.saveBtn")}
</SaveButton>
</div>
<div className="section-title">{trans("advanced.showHeaderInPublicApps")}</div>
<HelpText style={{ marginBottom: 12 }}>{trans("advanced.showHeaderInPublicAppsHelp")}</HelpText>
<div className="section-content">
<Switch
style={{ marginBottom: 12 }}
checked={
settings.hasOwnProperty('showHeaderInPublicApps')
? settings.showHeaderInPublicApps
: true
}
onChange={(value: boolean) => {
setSettings((v) => ({ ...v, showHeaderInPublicApps: value }));
}}
/>
<SaveButton
buttonType="primary"
disabled={commonSettings.showHeaderInPublicApps === settings.showHeaderInPublicApps}
onClick={
() => handleSave("showHeaderInPublicApps")(
settings.hasOwnProperty('showHeaderInPublicApps')
? settings.showHeaderInPublicApps
: true
)
}
>
{trans("advanced.saveBtn")}
</SaveButton>
</div>
<div className="section-title">{trans("advanced.preloadJSTitle")}</div>
<HelpText style={{ marginBottom: 12 }}>{trans("advanced.preloadJSHelp")}</HelpText>
<div className="section-content">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ export interface CommonSettingsState {
preloadLibs?: string[] | null;
applyPreloadCSSToHomePage?: boolean | null;
runJavaScriptInHost?: boolean | null;
showHeaderInPublicApps?: boolean;
};
setResult: boolean;

Expand Down
2 changes: 2 additions & 0 deletions server/node-service/src/plugins/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import bigQueryPlugin from "./bigQuery";
import appConfigPlugin from "./appconfig";
import tursoPlugin from "./turso";
import postmanEchoPlugin from "./postmanEcho";
import lowcoderPlugin from "./lowcoder";

let plugins: (DataSourcePlugin | DataSourcePluginFactory)[] = [
s3Plugin,
Expand Down Expand Up @@ -73,6 +74,7 @@ let plugins: (DataSourcePlugin | DataSourcePluginFactory)[] = [
appConfigPlugin,
tursoPlugin,
postmanEchoPlugin,
lowcoderPlugin,
];

try {
Expand Down
75 changes: 75 additions & 0 deletions server/node-service/src/plugins/lowcoder/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
import { readYaml } from "../../common/util";
import _ from "lodash";
import path from "path";
import { OpenAPIV3, OpenAPI } from "openapi-types";
import { ConfigToType, DataSourcePlugin } from "lowcoder-sdk/dataSource";
import { runOpenApi } from "../openApi";
import { parseOpenApi, ParseOpenApiOptions } from "../openApi/parse";

import spec from './lowcoder.spec.json';

const dataSourceConfig = {
type: "dataSource",
params: [
{
key: "serverURL",
type: "textInput",
label: "Lowcoder API Service URL",
rules: [{ required: true }],
placeholder: "https://<your-lowcoder-api-service>:port",
tooltip: "Input the server url of your self-hosting instance or api-service.lowcoder.cloud if you are running your apps on the free public Community Edition Cloud Service.",
},
{
"type": "groupTitle",
"key": "API Key",
"label": "Api Key Auth"
},
{
type: "password",
key: "bearerAuth.value",
label: "Authorization",
"tooltip": "API Key Authentication with a Bearer token. Copy your API Key here. (e.g. 'Bearer eyJhbGciO...')",
"placeholder": "API Key Authentication with a Bearer token. Copy your API Key here. (e.g. 'Bearer eyJhbGciO...')"
}
]
} as const;

const parseOptions: ParseOpenApiOptions = {
actionLabel: (method: string, path: string, operation: OpenAPI.Operation) => {
return _.upperFirst(operation.operationId || "");
},
};

type DataSourceConfigType = ConfigToType<typeof dataSourceConfig>;

const lowcoderPlugin: DataSourcePlugin<any, DataSourceConfigType> = {
id: "lowcoder",
name: "Lowcoder API",
icon: "lowcoder.svg",
category: "api",
dataSourceConfig,
queryConfig: async () => {
const { actions, categories } = await parseOpenApi(spec as unknown as OpenAPI.Document, parseOptions);
return {
type: "query",
label: "Action",
categories: {
label: "Resources",
items: categories,
},
actions,
};
},
run: function (actionData, dataSourceConfig): Promise<any> {
const { serverURL, ...otherDataSourceConfig } = dataSourceConfig;
console.log("Lowcoder API Plugin: run", serverURL, otherDataSourceConfig);
const runApiDsConfig = {
url: "",
serverURL: serverURL,
dynamicParamsConfig: otherDataSourceConfig,
};
return runOpenApi(actionData, runApiDsConfig, spec as OpenAPIV3.Document);
},
};

export default lowcoderPlugin;
Loading
Loading