feat: Add custom breakpoint for laptop dimensions (1348px)

- Added a new breakpoint "laptop" with a width of 1348px to the Tailwind configuration.
- This breakpoint accommodates the dimensions of 1348px width for responsive designs.
This commit is contained in:
ISA
2025-01-22 13:10:55 +01:00
parent 2d8962eda3
commit 176624740b
4 changed files with 72 additions and 50 deletions

View File

@@ -100,7 +100,7 @@ function Dashboard() {
}; };
return ( return (
<div className="flex flex-col gap-4 p-4 2xl:h-full overflow-auto"> <div className="flex flex-col gap-4 p-4 2xl:h-full xl:h-full overflow-auto">
<div className="flex justify-between items-center w-full lg:w-2/3"> <div className="flex justify-between items-center w-full lg:w-2/3">
<div className="flex justify-between gap-1 "> <div className="flex justify-between gap-1 ">
<Icon <Icon

View File

@@ -4,38 +4,38 @@ import { Icon } from "@iconify/react";
function EinAusgaenge() { function EinAusgaenge() {
const digitalInputs = [ const digitalInputs = [
{ id: 1, status: "active", description: "100V-Ausfall" }, { id: 1, status: "active", description: "100V-Ausfall", isInverted: true },
{ id: 2, status: "inactive", description: "DE2" }, { id: 2, status: "inactive", description: "DE2", isInverted: false },
{ id: 3, status: "active", description: "DE3" }, { id: 3, status: "active", description: "DE3", isInverted: false },
{ id: 4, status: "inactive", description: "DE4" }, { id: 4, status: "inactive", description: "DE4", isInverted: false },
{ id: 5, status: "active", description: "DE5" }, { id: 5, status: "active", description: "DE5", isInverted: false },
{ id: 6, status: "inactive", description: "DE6" }, { id: 6, status: "inactive", description: "DE6", isInverted: false },
{ id: 7, status: "active", description: "DE7" }, { id: 7, status: "active", description: "DE7", isInverted: false },
{ id: 8, status: "inactive", description: "DE8" }, { id: 8, status: "inactive", description: "DE8", isInverted: false },
{ id: 9, status: "active", description: "DE9" }, { id: 9, status: "active", description: "DE9", isInverted: false },
{ id: 10, status: "inactive", description: "DE10" }, { id: 10, status: "inactive", description: "DE10", isInverted: false },
{ id: 11, status: "active", description: "DE11" }, { id: 11, status: "active", description: "DE11", isInverted: false },
{ id: 12, status: "inactive", description: "DE12" }, { id: 12, status: "inactive", description: "DE12", isInverted: false },
{ id: 13, status: "active", description: "DE13" }, { id: 13, status: "active", description: "DE13", isInverted: false },
{ id: 14, status: "inactive", description: "DE14" }, { id: 14, status: "inactive", description: "DE14", isInverted: false },
{ id: 15, status: "active", description: "DE15" }, { id: 15, status: "active", description: "DE15", isInverted: false },
{ id: 16, status: "inactive", description: "DE16" }, { id: 16, status: "inactive", description: "DE16", isInverted: false },
{ id: 17, status: "active", description: "DE17" }, { id: 17, status: "active", description: "DE17", isInverted: false },
{ id: 18, status: "inactive", description: "DE18" }, { id: 18, status: "inactive", description: "DE18", isInverted: false },
{ id: 19, status: "active", description: "DE19" }, { id: 19, status: "active", description: "DE19", isInverted: false },
{ id: 20, status: "inactive", description: "DE20" }, { id: 20, status: "inactive", description: "DE20", isInverted: false },
{ id: 21, status: "active", description: "DE21" }, { id: 21, status: "active", description: "DE21", isInverted: false },
{ id: 22, status: "inactive", description: "DE22" }, { id: 22, status: "inactive", description: "DE22", isInverted: false },
{ id: 23, status: "active", description: "DE23" }, { id: 23, status: "active", description: "DE23", isInverted: false },
{ id: 24, status: "inactive", description: "DE24" }, { id: 24, status: "inactive", description: "DE24", isInverted: false },
{ id: 25, status: "active", description: "DE25" }, { id: 25, status: "active", description: "DE25", isInverted: false },
{ id: 26, status: "inactive", description: "DE26" }, { id: 26, status: "inactive", description: "DE26", isInverted: false },
{ id: 27, status: "active", description: "DE27" }, { id: 27, status: "active", description: "DE27", isInverted: false },
{ id: 28, status: "inactive", description: "DE28" }, { id: 28, status: "inactive", description: "DE28", isInverted: false },
{ id: 29, status: "active", description: "DE29" }, { id: 29, status: "active", description: "DE29", isInverted: false },
{ id: 30, status: "inactive", description: "DE30" }, { id: 30, status: "inactive", description: "DE30", isInverted: false },
{ id: 31, status: "active", description: "DE31" }, { id: 31, status: "active", description: "DE31", isInverted: false },
{ id: 32, status: "inactive", description: "DE32" }, { id: 32, status: "inactive", description: "DE32", isInverted: false },
]; ];
const digitalOutputs = [ const digitalOutputs = [
@@ -51,7 +51,7 @@ function EinAusgaenge() {
const inputsGroup2 = digitalInputs.slice(16); const inputsGroup2 = digitalInputs.slice(16);
return ( return (
<div className="p-4 "> <div className="p-4">
<h1 className="text-lg font-semibold mb-4">Ein- und Ausgänge</h1> <h1 className="text-lg font-semibold mb-4">Ein- und Ausgänge</h1>
<div className="flex gap-4"> <div className="flex gap-4">
{/* Digitale Eingänge */} {/* Digitale Eingänge */}
@@ -67,16 +67,15 @@ function EinAusgaenge() {
<thead className="bg-gray-100 border-b"> <thead className="bg-gray-100 border-b">
<tr> <tr>
<th className="px-2 py-1 text-left">Eingang</th> <th className="px-2 py-1 text-left">Eingang</th>
<th className="px-2 py-1 text-left">Zustand</th> <th className="px-2 py-1 text-left">Zustand</th>
<th className="px-2 py-1 text-left">Bezeichnung</th> <th className="px-2 py-1 text-left">Bezeichnung</th>
<th className="px-2 py-1 text-left">Aktion</th> <th className="px-2 py-1 text-left">Aktion</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
{group.map((input) => ( {group.map((input) => (
<tr key={input.id} className="border-b "> <tr key={input.id} className="border-b">
<td className="flex p-2 xl:py-0 2xl:p-1"> <td className="flex items-center p-2 xl:py-0 2xl:p-1">
{" "}
<Icon <Icon
icon="mdi:input" icon="mdi:input"
className="text-black-500 mr-2 text-xl" className="text-black-500 mr-2 text-xl"
@@ -91,8 +90,15 @@ function EinAusgaenge() {
}`} }`}
> >
{input.status === "active" ? "●" : "⨉"} {input.status === "active" ? "●" : "⨉"}
{input.isInverted && (
<Icon
icon="mdi:swap-vertical"
className="text-red-500 ml-2 text-xl cursor-pointer"
title="Invertiert"
/>
)}
</td> </td>
<td className="p-2 xl:py-0 ">{input.description}</td> <td className="p-2 xl:py-0">{input.description}</td>
<td className="p-2 xl:py-0"> <td className="p-2 xl:py-0">
<Icon <Icon
icon="mdi:settings" icon="mdi:settings"
@@ -117,31 +123,31 @@ function EinAusgaenge() {
<table className="w-full text-sm border-collapse bg-white rounded-lg"> <table className="w-full text-sm border-collapse bg-white rounded-lg">
<thead className="bg-gray-100 border-b"> <thead className="bg-gray-100 border-b">
<tr> <tr>
<th className="px-2 py-1 text-left">Ausgang</th> <th className="px-2 py-1 text-left">Ausgang</th>
<th className="px-2 py-1 text-left">Bezeichnung</th> <th className="px-2 py-1 text-left">Bezeichnung</th>
<th className="px-2 py-1 text-left">Schalter</th> <th className="px-2 py-1 text-left">Schalter</th>
<th className="px-2 py-1 text-left">Aktion</th> <th className="px-2 py-1 text-left">Aktion</th>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
{digitalOutputs.map((output) => ( {digitalOutputs.map((output) => (
<tr key={output.id} className="border-b"> <tr key={output.id} className="border-b">
<td className="flex px-2 py-1"> <td className="flex items-center px-2 py-1">
<Icon <Icon
icon="mdi:output" icon="mdi:output"
className="text-black-500 mr-2 text-xl" className="text-black-500 mr-2 text-xl"
/> />
{output.id} {output.id}
</td> </td>
<td className="px-2 py-1">{output.description}</td> <td className="px-2 py-1">{output.description}</td>
<td className="px-2 py-1"> <td className="px-2 py-1">
<input <input
type="checkbox" type="checkbox"
checked={output.toggle} checked={output.toggle}
className="w-5 h-5" className="w-5 h-5"
/> />
</td> </td>
<td className="px-2 py-1"> <td className="px-2 py-1">
<Icon <Icon
icon="mdi:settings" icon="mdi:settings"
className="text-gray-400 text-lg cursor-pointer" className="text-gray-400 text-lg cursor-pointer"

View File

@@ -2,4 +2,11 @@ var win_de=[<%=DES80%>,<%=DES81%>,<%=DES82%>,<%=DES83%>];//Zustand des digitalen
//DESxx xx =Nr Eingang 1-32 81-84 = BGT 1 bis 4 //DESxx xx =Nr Eingang 1-32 81-84 = BGT 1 bis 4
var win_counter=[<%=DEC80%>,<%=DEC81%>,<%=DEC82%>,<%=DEC83%>];//Zählerstand var win_counter=[<%=DEC80%>,<%=DEC81%>,<%=DEC82%>,<%=DEC83%>];//Zählerstand
//DECxx xx =Nr Eingang 1-32 81-84 = BGT 1 bis 4 //DECxx xx =Nr Eingang 1-32 81-84 = BGT 1 bis 4
var win_flutter=[<%=DEF80%>,<%=DEF81%>,<%=DEF82%>,<%=DEF83%>];// noch nicht verwendet in Lastheft Oktober 2024 var win_flutter=[<%=DEF80%>,<%=DEF81%>,<%=DEF82%>,<%=DEF83%>];// noch nicht verwendet in Lastheft Oktober 2024
/* von https://10.10.0.222/CPL?Service/de.ACP
var de=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];
var counter=[0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000,0.000000];
var flutter=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];
*/

View File

@@ -10,6 +10,15 @@ module.exports = {
colors: { colors: {
"littwin-blue": "#00AEEF", // Definiere die Farbe mit dem gewünschten Hex-Wert "littwin-blue": "#00AEEF", // Definiere die Farbe mit dem gewünschten Hex-Wert
}, },
screens: {
sm: "640px",
md: "768px",
lg: "1024px",
xl: "1280px",
laptop: "1348px", // Neue Bildschirmgröße für Laptop
"2xl": "1600px",
"3xl": "1920px",
},
}, },
}, },
plugins: [], plugins: [],