Skip to content

Commit

Permalink
Merge branch 'devel' into CB-5061-remove-mandatory-parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
dariamarutkina authored May 22, 2024
2 parents 4703dfc + 1e599fd commit 5a06f4c
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public void bindWiring(DBWBindingContext model) throws DBWebException {
return true;
})
.dataFetcher("authUpdateStatus", env -> getService(env).authUpdateStatus(
getWebSession(env),
getWebSession(env, false),
env.getArgument("authId"),
CommonUtils.toBoolean(env.getArgument("linkUser"))
))
Expand Down
1 change: 1 addition & 0 deletions webapp/packages/core-blocks/src/FormControls/Combobox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ export const Combobox: ComboboxType = observer(function Combobox({
placement: 'bottom-end',
currentId: null,
gutter: 4,
unstable_fixed: true,
});

if (readOnly) {
Expand Down
8 changes: 7 additions & 1 deletion webapp/packages/core-blocks/src/Menu/Menu.m.css
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
/*
* CloudBeaver - Cloud Database Manager
* Copyright (C) 2020-2024 DBeaver Corp and others
*
* Licensed under the Apache License, Version 2.0.
* you may not use this file except in compliance with the License.
*/
.menuButton {
composes: theme-ripple from global;
}
.menuButton {
background: none;
border: none;
outline: none !important;
color: inherit;
cursor: pointer;

Expand Down
1 change: 1 addition & 0 deletions webapp/packages/core-blocks/src/Menu/Menu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ export const Menu = observer<IMenuProps, HTMLButtonElement>(
placement,
visible,
rtl,
unstable_fixed: true,
});
const styles = useS(style);

Expand Down
15 changes: 13 additions & 2 deletions webapp/packages/core-blocks/src/Tree/TreeNode/TreeNodeExpand.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,11 @@ import { useContext } from 'react';

import { EventContext } from '@cloudbeaver/core-events';

import { Clickable } from '../../Clickable';
import { getComputed } from '../../getComputed';
import { Icon } from '../../Icon';
import { Loader } from '../../Loader/Loader';
import { useTranslate } from '../../localization/useTranslate';
import { s } from '../../s';
import { useS } from '../../useS';
import { useStateDelay } from '../../useStateDelay';
Expand All @@ -29,6 +31,7 @@ interface Props {
}

export const TreeNodeExpand = observer<Props>(function TreeNodeExpand({ leaf, big, filterActive, disabled, className }) {
const translate = useTranslate();
const styles = useS(style);
const context = useContext(TreeNodeContext);

Expand Down Expand Up @@ -85,14 +88,22 @@ export const TreeNodeExpand = observer<Props>(function TreeNodeExpand({ leaf, bi
}
}

const title = translate('ui_expand');

return (
<div
<Clickable
as="div"
role="button"
title={title}
aria-label={title}
className={s(styles, { treeNodeExpand: true, expanded: context.expanded, big }, className)}
focusable={expandable}
disabled={disabled || !expandable}
onClick={handleExpand}
onDoubleClick={handleDbClick}
>
{loading && <Loader small fullSize />}
{expandable && <Icon name={iconName} className={s(styles, { icon: true })} viewBox={viewBox} />}
</div>
</Clickable>
);
});
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { action, makeObservable, observable } from 'mobx';

import { ISyncExecutor, SyncExecutor } from '@cloudbeaver/core-executor';
import { ResultDataFormat, SqlResultRow, UpdateResultsDataBatchMutationVariables } from '@cloudbeaver/core-sdk';
import { isNull } from '@cloudbeaver/core-utils';

import type { IDatabaseDataSource } from '../../IDatabaseDataSource';
import type { IDatabaseResultSet } from '../../IDatabaseResultSet';
Expand Down Expand Up @@ -142,7 +143,7 @@ export class ResultSetEditAction extends DatabaseEditAction<IResultSetElementKey
const prevValue = update.source?.[key.column.index] as any;

if (isResultSetContentValue(prevValue) && !isResultSetComplexValue(value)) {
if ('text' in prevValue) {
if ('text' in prevValue && !isNull(value)) {
value = createResultSetContentValue({
text: String(value),
contentLength: String(value).length,
Expand Down
3 changes: 2 additions & 1 deletion webapp/packages/product-default/src/UpdateInstruction.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ import { Code } from '@cloudbeaver/core-blocks';
import type { InstructionComponent } from '@cloudbeaver/core-version-update';

export const UpdateInstruction: InstructionComponent = function UpdateInstruction({ version, containerId, className }) {
const id = containerId || 'cloudbeaver';
const id = '{your container id}';

return (
<div className={className}>
<Code>
Expand Down

0 comments on commit 5a06f4c

Please sign in to comment.