Skip to content

Conversation

@sergeyteleshev
Copy link
Contributor

@sergeyteleshev sergeyteleshev force-pushed the 7772-cb-remove-tooltips-from-context-menu branch from 6dd1f10 to 285b6b7 Compare January 6, 2026 12:26

const title = translate(label);
const textRef = useRef<HTMLDivElement | null>(null);
const truncatedLabel = useTruncatedTooltip(textRef, label);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we dont need this, tooltips are just fine

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also think so, we don't expect to have long tooltips or labels in the menu items, where we expect them, we should truncate them at the declaration point

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for example like here:

if (this.clipboardService.state === 'granted') {
const filters = supportedOperations
.filter(operation => !nullOperationsFilter(operation))
.map(operation => {
const val = this.clipboardService.clipboardValue || '';
const wrappedValue = wrapOperationArgument(operation.id, val);
const clippedValue = replaceMiddle(wrappedValue, ' ... ', 8, 30);
const label = `${columnLabel} ${operation.expression} ${clippedValue}`;
return new MenuBaseItem(
{ id: operation.id, icon: 'filter-clipboard', label },
{
onSelect: async () => {
const wrappedValue = wrapOperationArgument(operation.id, val);
await this.applyFilter(
model as unknown as IDatabaseDataModel<ResultSetDataSource>,
resultIndex,
key.column,
operation.id,
wrappedValue,
);
},
},
{ isDisabled: () => model.isLoading() },
);
});
result.push(...filters);
}


const title = translate(label);
const textRef = useRef<HTMLDivElement | null>(null);
const truncatedLabel = useTruncatedTooltip(textRef, label);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also think so, we don't expect to have long tooltips or labels in the menu items, where we expect them, we should truncate them at the declaration point


const title = translate(label);
const textRef = useRef<HTMLDivElement | null>(null);
const truncatedLabel = useTruncatedTooltip(textRef, label);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for example like here:

if (this.clipboardService.state === 'granted') {
const filters = supportedOperations
.filter(operation => !nullOperationsFilter(operation))
.map(operation => {
const val = this.clipboardService.clipboardValue || '';
const wrappedValue = wrapOperationArgument(operation.id, val);
const clippedValue = replaceMiddle(wrappedValue, ' ... ', 8, 30);
const label = `${columnLabel} ${operation.expression} ${clippedValue}`;
return new MenuBaseItem(
{ id: operation.id, icon: 'filter-clipboard', label },
{
onSelect: async () => {
const wrappedValue = wrapOperationArgument(operation.id, val);
await this.applyFilter(
model as unknown as IDatabaseDataModel<ResultSetDataSource>,
resultIndex,
key.column,
operation.id,
wrappedValue,
);
},
},
{ isDisabled: () => model.isLoading() },
);
});
result.push(...filters);
}

Wroud
Wroud previously approved these changes Jan 8, 2026
devnaumov
devnaumov previously approved these changes Jan 8, 2026
@sergeyteleshev sergeyteleshev dismissed stale reviews from devnaumov and Wroud via e0e4162 January 8, 2026 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants