Skip to content

Commit

Permalink
Merge branch '#2039748_button_text' into 'main'
Browse files Browse the repository at this point in the history
feat: Changed the labels of a few OpenDialog buttons (#2039748)

See merge request plattform/designer/vscode-liquibase!44
  • Loading branch information
rH4rtinger committed Aug 8, 2024
2 parents 2abdda7 + 31e251b commit 392bee5
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 7 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ All notable changes to the "liquibase" extension will be documented in this file

The format is based on [Keep a Changelog](http://keepachangelog.com/) and and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Changed

- Changed the labels of a few OpenDialog buttons

## 1.0.0

### Added
Expand Down
2 changes: 1 addition & 1 deletion src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export const folderSelectionName = "folderSelection";
/**
* The label that should be used for the folder selection.
*/
export const selectOutputFolder = "Select output folder";
export const selectOutputFolder = "Save";

/**
* Name of the option to choose a custom changelog from the dialogs.
Expand Down
5 changes: 3 additions & 2 deletions src/convertFormats.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { getWorkFolder } from "./handleChangelogFileInput";
import * as vscode from "vscode";
import { createBasicArgsForLiquibaseCLI, executeJarAsync } from "./executeJar";
import { Logger } from "@aditosoftware/vscode-logging";
import { selectOutputFolder } from "./constants";

const inputKey = "input";
const outputKey = "output";
Expand All @@ -30,7 +31,7 @@ export async function convertFormats(convertFile: boolean, selectedFile?: vscode
canSelectFiles: convertFile,
canSelectFolders: !convertFile,
defaultUri: vscode.Uri.file(getWorkFolder()),
openLabel: `Select the ${convertFile ? "file" : "folder"} to convert`,
openLabel: `Submit ${convertFile ? "File" : "Folder"} for Conversion`,
filters: {
Changelog: ["json", "sql", "xml", "yml", "yaml"],
"All Files": ["*"],
Expand All @@ -46,7 +47,7 @@ export async function convertFormats(convertFile: boolean, selectedFile?: vscode
canSelectFiles: false,
canSelectFolders: true,
defaultUri: vscode.Uri.file(getWorkFolder()),
openLabel: "Select the output location",
openLabel: selectOutputFolder,
},
}),
new QuickPick({
Expand Down
2 changes: 1 addition & 1 deletion src/handleChangelogFileInput.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export class HandleChangelogFileInput {
canSelectFiles: true,
canSelectFolders: false,
canSelectMany: false,
openLabel: "Select the changelog",
openLabel: "Submit Changelog",
filters: {
Changelog: ["xml", "json", "yaml", "yml", "sql"],
"All Files": ["*"],
Expand Down
4 changes: 2 additions & 2 deletions src/settings/configurationCommands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ export async function addExistingLiquibaseConfiguration(): Promise<void> {
new OpenDialog({
name: locationKey,
openDialogOptions: {
openLabel: "Open properties file",
openLabel: "Append",
canSelectFiles: true,
canSelectFolders: false,
canSelectMany: false,
Expand Down Expand Up @@ -301,7 +301,7 @@ export const modifyOrAddDriver = (oldDriverValues?: CustomDriverData, oldDriverN
filters: {
"Driver File": ["jar"],
},
openLabel: "Select the driver file",
openLabel: "Submit Driver",
},
})
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ suite("configurationCommands", () => {
Sinon.assert.calledOnce(openDialog);
Sinon.assert.calledWith(openDialog, {
title: "Add existing configuration (Step 2 of 2)",
openLabel: "Open properties file",
openLabel: "Append",
canSelectFiles: true,
canSelectFolders: false,
canSelectMany: false,
Expand Down

0 comments on commit 392bee5

Please sign in to comment.