[PR #12426] [MERGED] fix: Conditionally hide export buttons #9706

Closed
opened 2025-11-11 18:29:25 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/open-webui/open-webui/pull/12426
Author: @silentoplayz
Created: 4/4/2025
Status: Merged
Merged: 4/5/2025
Merged by: @tjbck

Base: devHead: fix-feedback


📝 Commits (3)

  • 2b0d9c2 fix: don't show export button if nothing to export
  • 1366822 Update Feedbacks.svelte
  • 41b9ff9 fix: funcs, models, prompts, & tools conditional export button

📊 Changes

5 files changed (+125 additions, -120 deletions)

View changed files

📝 src/lib/components/admin/Evaluations/Feedbacks.svelte (+3 -2)
📝 src/lib/components/admin/Functions.svelte (+33 -31)
📝 src/lib/components/workspace/Models.svelte (+26 -25)
📝 src/lib/components/workspace/Prompts.svelte (+29 -26)
📝 src/lib/components/workspace/Tools.svelte (+34 -36)

📄 Description

Pull Request Checklist

  • Target branch: Please verify that the pull request targets the dev branch.
  • Description: Provide a concise description of the changes made in this pull request.
  • Changelog: Ensure a changelog entry following the format of Keep a Changelog is added at the bottom of the PR description.
  • Documentation: Have you updated relevant documentation Open WebUI Docs, or other documentation sources?
  • Dependencies: Are there any new dependencies? Have you updated the dependency versions in the documentation?
  • Testing: Have you written and run sufficient tests to validate the changes?
  • Code review: Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards?
  • Prefix: The prefix "fix" was used to categorize this pull request.

Changelog Entry

Description

  • Conditionally hide the Export button on the Models, Prompts, Functions, Tools, and Feedbacks pages when there is no existing content available to export. This improves the user interface by preventing users from seeing or clicking an action that cannot be performed due to the absence of data.

Changed

  • Updated UI components to only render the Export {content} button if the {content} array contains items.

Fixed

  • Fixed an issue where the Export button was displayed even when there was no {content} to export.

Additional Information

  • This is a minor UI refinement to enhance user experience.

Screenshots or Videos

Before:

image

After:

image


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/open-webui/open-webui/pull/12426 **Author:** [@silentoplayz](https://github.com/silentoplayz) **Created:** 4/4/2025 **Status:** ✅ Merged **Merged:** 4/5/2025 **Merged by:** [@tjbck](https://github.com/tjbck) **Base:** `dev` ← **Head:** `fix-feedback` --- ### 📝 Commits (3) - [`2b0d9c2`](https://github.com/open-webui/open-webui/commit/2b0d9c26eb137e49905150ce3fff921bd3e4915f) fix: don't show export button if nothing to export - [`1366822`](https://github.com/open-webui/open-webui/commit/1366822f99f7b10366d534d31f2ca9355d03799b) Update Feedbacks.svelte - [`41b9ff9`](https://github.com/open-webui/open-webui/commit/41b9ff9e00deba85917770d3bb78f6f4f2a9a4f9) fix: funcs, models, prompts, & tools conditional export button ### 📊 Changes **5 files changed** (+125 additions, -120 deletions) <details> <summary>View changed files</summary> 📝 `src/lib/components/admin/Evaluations/Feedbacks.svelte` (+3 -2) 📝 `src/lib/components/admin/Functions.svelte` (+33 -31) 📝 `src/lib/components/workspace/Models.svelte` (+26 -25) 📝 `src/lib/components/workspace/Prompts.svelte` (+29 -26) 📝 `src/lib/components/workspace/Tools.svelte` (+34 -36) </details> ### 📄 Description # Pull Request Checklist - [x] **Target branch:** Please verify that the pull request targets the `dev` branch. - [x] **Description:** Provide a concise description of the changes made in this pull request. - [x] **Changelog:** Ensure a changelog entry following the format of [Keep a Changelog](https://keepachangelog.com/) is added at the bottom of the PR description. - [x] **Documentation:** Have you updated relevant documentation [Open WebUI Docs](https://github.com/open-webui/docs), or other documentation sources? - [x] **Dependencies:** Are there any new dependencies? Have you updated the dependency versions in the documentation? - [x] **Testing:** Have you written and run sufficient tests to validate the changes? - [x] **Code review:** Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards? - [x] **Prefix:** The prefix "fix" was used to categorize this pull request. # Changelog Entry ### Description - Conditionally hide the `Export` button on the `Models`, `Prompts`, `Functions`, `Tools`, and `Feedbacks` pages when there is no existing content available to export. This improves the user interface by preventing users from seeing or clicking an action that cannot be performed due to the absence of data. ### Changed - Updated UI components to only render the `Export {content}` button if the {content} array contains items. ### Fixed - Fixed an issue where the `Export` button was displayed even when there was no {content} to export. --- ### Additional Information - This is a minor UI refinement to enhance user experience. ### Screenshots or Videos # `Before:` ![image](https://github.com/user-attachments/assets/0e676ad1-4eda-4fac-a68c-1f4086e49194) # `After:` ![image](https://github.com/user-attachments/assets/1b3d6b13-618a-4530-bf2c-bb9ad6493ae3) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-11 18:29:25 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#9706