Skip to content

Commit 359d94d

Browse files
committed
change action button positions for TABS
1 parent 66365b3 commit 359d94d

File tree

3 files changed

+33
-30
lines changed

3 files changed

+33
-30
lines changed

client/packages/lowcoder/src/pages/setting/environments/components/AppsTab.tsx

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,17 @@ const AppsTab: React.FC<AppsTabProps> = ({ environment, workspaceId }) => {
195195
key: 'actions',
196196
render: (_: any, app: App) => (
197197
<Space onClick={(e) => e.stopPropagation()}>
198+
199+
<Tooltip title={!app.managed ? "App must be managed before it can be deployed" : "Deploy this app to another environment"}>
200+
<Button
201+
type="primary"
202+
icon={<CloudUploadOutlined />}
203+
onClick={() => openDeployModal(app, appsConfig, environment)}
204+
disabled={!app.managed}
205+
>
206+
Deploy
207+
</Button>
208+
</Tooltip>
198209
<Tooltip title="View Audit Logs">
199210
<Button
200211
icon={<AuditOutlined />}
@@ -207,16 +218,6 @@ const AppsTab: React.FC<AppsTabProps> = ({ environment, workspaceId }) => {
207218
Audit
208219
</Button>
209220
</Tooltip>
210-
<Tooltip title={!app.managed ? "App must be managed before it can be deployed" : "Deploy this app to another environment"}>
211-
<Button
212-
type="primary"
213-
icon={<CloudUploadOutlined />}
214-
onClick={() => openDeployModal(app, appsConfig, environment)}
215-
disabled={!app.managed}
216-
>
217-
Deploy
218-
</Button>
219-
</Tooltip>
220221
</Space>
221222
),
222223
}

client/packages/lowcoder/src/pages/setting/environments/components/DataSourcesTab.tsx

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,17 @@ const DataSourcesTab: React.FC<DataSourcesTabProps> = ({ environment, workspaceI
197197
key: 'actions',
198198
render: (_: any, dataSource: DataSource) => (
199199
<Space onClick={(e) => e.stopPropagation()}>
200+
201+
<Tooltip title={!dataSource.managed ? "Data source must be managed before it can be deployed" : "Deploy this data source to another environment"}>
202+
<Button
203+
type="primary"
204+
icon={<CloudUploadOutlined />}
205+
onClick={() => openDeployModal(dataSource, dataSourcesConfig, environment)}
206+
disabled={!dataSource.managed}
207+
>
208+
Deploy
209+
</Button>
210+
</Tooltip>
200211
<Tooltip title="View Audit Logs">
201212
<Button
202213
icon={<AuditOutlined />}
@@ -209,16 +220,6 @@ const DataSourcesTab: React.FC<DataSourcesTabProps> = ({ environment, workspaceI
209220
Audit
210221
</Button>
211222
</Tooltip>
212-
<Tooltip title={!dataSource.managed ? "Data source must be managed before it can be deployed" : "Deploy this data source to another environment"}>
213-
<Button
214-
type="primary"
215-
icon={<CloudUploadOutlined />}
216-
onClick={() => openDeployModal(dataSource, dataSourcesConfig, environment)}
217-
disabled={!dataSource.managed}
218-
>
219-
Deploy
220-
</Button>
221-
</Tooltip>
222223
</Space>
223224
),
224225
}

client/packages/lowcoder/src/pages/setting/environments/components/QueriesTab.tsx

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,17 @@ const QueriesTab: React.FC<QueriesTabProps> = ({ environment, workspaceId }) =>
215215
key: 'actions',
216216
render: (_: any, query: Query) => (
217217
<Space onClick={(e) => e.stopPropagation()}>
218+
219+
<Tooltip title={!query.managed ? "Query must be managed before it can be deployed" : "Deploy this query to another environment"}>
220+
<Button
221+
type="primary"
222+
icon={<CloudUploadOutlined />}
223+
onClick={() => openDeployModal(query, queryConfig, environment)}
224+
disabled={!query.managed}
225+
>
226+
Deploy
227+
</Button>
228+
</Tooltip>
218229
<Tooltip title="View Audit Logs">
219230
<Button
220231
icon={<AuditOutlined />}
@@ -227,16 +238,6 @@ const QueriesTab: React.FC<QueriesTabProps> = ({ environment, workspaceId }) =>
227238
Audit
228239
</Button>
229240
</Tooltip>
230-
<Tooltip title={!query.managed ? "Query must be managed before it can be deployed" : "Deploy this query to another environment"}>
231-
<Button
232-
type="primary"
233-
icon={<CloudUploadOutlined />}
234-
onClick={() => openDeployModal(query, queryConfig, environment)}
235-
disabled={!query.managed}
236-
>
237-
Deploy
238-
</Button>
239-
</Tooltip>
240241
</Space>
241242
),
242243
}

0 commit comments

Comments
 (0)