PluginProbe
BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot / 4.9.5
BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot v4.9.5
4.9.5 4.9.4 4.9.3 4.9.2 4.9.1 4.9.0 4.8.2 4.8.1 4.8.0 4.7.0 4.6.2 4.6.1 4.6.0 4.5.6 4.5.5 4.5.4 4.5.3 4.5.2 4.5.1 4.5.0 4.4.1 4.4.0 3.3.4 3.4.0 3.4.1 All 203 releases
betterdocs / react-src / admin / doc-categories / components / BulkActionsSelect.js

BulkActionsSelect.js in BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot 4.9.5, at react-src/admin/doc-categories/components/BulkActionsSelect.js

32 lines 1.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 import React from "react";
2 import { __ } from "@wordpress/i18n";
3 import Select from "react-select";
4
5 // Bulk-action picker shared by the Doc Categories & Doc Tags tables. Rendered
6 // with react-select — reusing the FAQ Builder "Order" dropdown styling
7 // (`betterdocs-dropdown` classNamePrefix) — so its open menu list matches the
8 // FAQ Builder instead of the browser's native, unstyleable <select> popup.
9 const BulkActionsSelect = ({ value, onChange }) => {
10 const options = [
11 { value: "", label: __("Bulk actions", "betterdocs") },
12 { value: "delete", label: __("Delete", "betterdocs") },
13 ];
14
15 return (
16 <div className="betterdocs-dropdown-wrapper bd-dc-bulk-order">
17 <Select
18 className="betterdocs-dropdown-select"
19 classNamePrefix="betterdocs-dropdown"
20 value={options.find((o) => o.value === value) || options[0]}
21 options={options}
22 onChange={(opt) => onChange(opt?.value || "")}
23 isSearchable={false}
24 isClearable={false}
25 menuPlacement="bottom"
26 />
27 </div>
28 );
29 };
30
31 export default BulkActionsSelect;
32