PluginProbe
Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News / 4.0.2
Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News v4.0.2
4.0.8 4.0.7 4.0.6 4.0.5 4.0.4 4.0.3 4.0.2 4.0.1 2.3.5 2.3.6 2.4.0 2.4.1 2.4.10 2.4.11 2.4.12 2.4.13 2.4.14 2.4.15 2.4.16 2.4.17 2.4.18 2.4.19 2.4.2 2.4.20 2.4.21 All 88 releases
post-carousel / src / components / inputControl / units.js

units.js in Smart Post – Post Grid, Post Carousel, Post Slider Gutenberg Blocks for Blog & News 4.0.2, at src/components/inputControl/units.js

24 lines 513 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 import { Button } from "@wordpress/components";
2
3 const Units = ({ units, onChange, activeUnit }) => {
4 return (
5 <div className="sp-smart-post-units">
6 <div className="sp-smart-post-units-btn">
7 {units?.map((item, i) => (
8 <Button
9 className={activeUnit === item.toLowerCase() ? "active" : ""}
10 key={i}
11 value={item}
12 onClick={(e) => onChange(e.target.value.toLowerCase())}
13 >
14 {" "}
15 {item}{" "}
16 </Button>
17 ))}
18 </div>
19 </div>
20 );
21 };
22
23 export default Units;
24