Snippets Collections
<p class="nl-event-programme">AU PROGRAMME : <span style="text-transform:normal;font-size:18px;">cocktail, visite guidée du FabLab de la Fabrique de l’Innovation, expositions et démonstrations.</span></p>
<br />
<br />
<p class="nl-event-nb">La semaine &#34;Meet &amp; Fabrik&#34; est organisée par la Fabrique de l’Innovation de la ComUE Université de Lyon et se déroulera du 5 au 9 juin 2023.</p>
<a title="programme" href="/fr/">
<table width="100%" cellspacing="0" cellpadding="0" border="0">
    <tbody>
        <tr>
            <td>
            <table cellspacing="0" cellpadding="0" border="0" align="center">
                <tbody>
                    <tr align="center">
                        <td style="padding: 12px 18px 12px 18px; border-radius:3px" bgcolor="#ffb71c" align="center"><a href="/fr/" class="nl-event-button prog" target="_blank" style="font-size: 18px; font-weight: bold; color: #ffffff; text-decoration: none; display: inline-block;">  Voir le programme complet</a></td>
                    </tr>
                </tbody>
            </table>
            </td>
        </tr>
    </tbody>
</table>
</a> <!--[if mso]><p>&nbsp;</p><!-- <![endif]-->
import React from "react";
import {
  BodyText,
  Conditional,
  H2,
  HeadingLink,
  IntroText,
  Loading,
  MinimalPage,
  PageHeading,
  PrimaryButton,
  Tooltip,
  TooltipContent,
  TooltipProvider,
  TooltipTrigger,
} from "ui";
import Link from "next/link";
import { CommandInterface } from "@/components";
import { useShiftTable } from "@/hooks";
import { timeSince } from "@/functions";
import dayjs from "dayjs";

type User = {
  shift_start: string | null;
  break_start: string | null;
  user: any;
  image: string;
  fullName: string;
  group: string | null;
  users_view?: {
    email?: string;
    raw_user_meta_data?: {
      avatar_url?: string;
      full_name?: string;
    };
  };
  email: string;
};

const ShiftTable = () => {
  const { data, isLoading, error, isError } = useShiftTable();

  const countUsersInGroups = (users: User[]): Record<string, number> => {
    return users.reduce<Record<string, number>>((acc, user) => {
      const groupName = user.group || "No Group";
      acc[groupName] = (acc[groupName] || 0) + 1;
      return acc;
    }, {});
  };

  const usersOnShiftCounts = countUsersInGroups(data?.onShift ?? []);
  const usersOffShiftCounts = countUsersInGroups(data?.offShift ?? []);

  const sortUsers = (users: User[]) => {
    return users
      .slice()
      .sort((a, b) => a.fullName.localeCompare(b.fullName))
      .sort((a, b) => {
        const shiftA = a.shift_start ? new Date(a.shift_start).getTime() : 0;
        const shiftB = b.shift_start ? new Date(b.shift_start).getTime() : 0;
        return shiftA - shiftB;
      });
  };

  return (
    <MinimalPage
      pageTitle="Shift Table | Email Interface"
      pageDescription="Spot Ship Email Interface | Shift Table"
      commandPrompt
    >
      <CommandInterface />
      <div className="hidden">
        <PageHeading text="Homepage" />
      </div>
      <div className="w-full pl-1 pt-1">
        <HeadingLink icon="back" text="Home" href="/secure/home" />
        <PageHeading text="Spot Ship Shift Table" />
        <Conditional
          condition={!isLoading}
          elseChildren={
            <Loading style="grid" size="large" colour="#AAAAAA50" />
          }
        >
          <Conditional
            condition={!isError}
            elseChildren={<p className="text-red-500">{`${error?.message}`}</p>}
          >
            <div className="mb-4 text-center text-sm text-gray-400">
              Users currently on shift:{" "}
              {Object.entries(usersOnShiftCounts)
                .map(([group, count]) => `${group}: ${count}`)
                .join(", ")}
            </div>
            <RenderUsersGrid
              title="Data Analysts"
              users={sortUsers(
                data?.onShift?.filter(
                  (user) => user.group === "Data Analyst",
                ) ?? [],
              )}
            />
            <RenderUsersGrid
              title="Senior Data Analysts"
              users={sortUsers(
                data?.onShift?.filter(
                  (user) => user.group === "Senior Data Analyst",
                ) ?? [],
              )}
            />
            <RenderUsersGrid
              title="Data Team Managers"
              users={sortUsers(
                data?.onShift?.filter(
                  (user) => user.group === "Data Team Manager",
                ) ?? [],
              )}
            />
            <RenderUsersGrid
              title="Europe Team"
              users={sortUsers(
                data?.onShift?.filter((user) => user.group === "Europe Team") ??
                  [],
              )}
            />
            <div className="mb-4 text-center text-sm text-gray-400">
              Offline users:{" "}
              {Object.entries(usersOffShiftCounts)
                .map(([group, count]) => `${group}: ${count}`)
                .join(", ")}
            </div>
            <RenderUsersGrid
              title="Offline Data Analysts"
              users={sortUsers(
                data?.offShift?.filter(
                  (user) => user.group === "Data Analyst",
                ) ?? [],
              )}
              showShiftStart={false}
              dim={true}
            />
            <RenderUsersGrid
              title="Offline Senior Data Analysts"
              users={sortUsers(
                data?.offShift?.filter(
                  (user) => user.group === "Senior Data Analyst",
                ) ?? [],
              )}
              showShiftStart={false}
              dim={true}
            />
            <RenderUsersGrid
              title="Offline Data Team Managers"
              users={sortUsers(
                data?.offShift?.filter(
                  (user) => user.group === "Data Team Manager",
                ) ?? [],
              )}
              showShiftStart={false}
              dim={true}
            />
            <RenderUsersGrid
              title="Offline Europe Team"
              users={sortUsers(
                data?.offShift?.filter(
                  (user) => user.group === "Europe Team",
                ) ?? [],
              )}
              showShiftStart={false}
              dim={true}
            />
          </Conditional>
        </Conditional>
      </div>
    </MinimalPage>
  );
};
const RenderUsersGrid = ({
  title,
  users = [],
  showShiftStart = true,
  dim = false,
}: {
  title: string;
  users?: User[];
  showShiftStart?: boolean;
  dim?: boolean;
}) => {
  return (
    <div
      className={`overflow-hidden overflow-x-auto rounded-lg shadow ${
        dim ? "opacity-50" : ""
      }`}
    >
      <H2 className="text-center ">{title}</H2>
      <div className="grid grid-cols-4 gap-4 p-4">
        {users.map((user, index) => (
          <div
            key={index}
            className={`relative flex flex-col items-center justify-center rounded-lg bg-gray-200 p-4 dark:bg-gray-800 ${
              dim ? "bg-opacity-50" : ""
            }`}
          >
            <div className="relative h-12 w-12">
              <img
                src={user.image || "/avatar_url.png"}
                alt={user.fullName}
                className="h-full w-full rounded-full object-cover"
              />
              <span
                className={`absolute bottom-0 right-0 block h-5 w-5 rounded-full border border-white/20 dark:border-black ${
                  user.shift_start === null
                    ? "bg-gray-400"
                    : user.break_start === null
                      ? "bg-green-400"
                      : "bg-yellow-400"
                }`}
              />
            </div>
            <Conditional condition={user.email !== ""}>
              <div className="mt-2">
                <Link
                  href={`/secure/review/email?filename=${user.email}`}
                  passHref
                  rel="noopener noreferrer"
                  target="_blank"
                >
                  <PrimaryButton size="small">Working on Email</PrimaryButton>
                </Link>
              </div>
            </Conditional>
            <IntroText className="mt-2">{user.fullName}</IntroText>
            <Conditional condition={showShiftStart && !!user.shift_start}>
              <TooltipProvider>
                <Tooltip>
                  <TooltipTrigger>
                    <BodyText>
                      {user.shift_start
                        ? `On shift for: ${timeSince(new Date(user.shift_start))}`
                        : ""}
                    </BodyText>
                  </TooltipTrigger>
                  <TooltipContent>
                    <p>
                      {dayjs(user.shift_start).format("DD-MM-YYYY | HH:mm")}
                    </p>
                  </TooltipContent>
                </Tooltip>
              </TooltipProvider>
            </Conditional>
            <Conditional condition={showShiftStart && !!user.break_start}>
              <TooltipProvider>
                <Tooltip>
                  <TooltipTrigger>
                    <BodyText>
                      {user.break_start
                        ? `On break for: ${timeSince(
                            new Date(user.break_start),
                          )}`
                        : ""}
                    </BodyText>
                  </TooltipTrigger>
                  <TooltipContent>
                    <p>
                      {dayjs(user.break_start).format("DD-MM-YYYY | HH:mm")}
                    </p>
                  </TooltipContent>
                </Tooltip>
              </TooltipProvider>
            </Conditional>
          </div>
        ))}
      </div>
    </div>
  );
};

export default ShiftTable;
import type { NextPage } from "next";
import {
  CommandInterface,
  EmailUtitlities,
  EmailViewer,
  ScoreCargoResults,
  ScoreClassificationResults,
  ScoreLineupResults,
  ScorePositionResults,
  UserAutocomplete,
} from "@/components";
import {
  Content,
  DataTable,
  DialogButton,
  DisclosureButton,
  FormCheckboxField,
  FormDateTimeRangeField,
  HeadingLink,
  If,
  IfElse,
  MinimalPage,
  PageHeading,
  Subheading,
  ToolTip,
} from "ui";
import { useState } from "react";
import type { Json, User } from "@/types";
import type { DateValueType } from "react-tailwindcss-datepicker/dist/types";
import { useGetEmail, useGetEmailStatus, useUserHistory } from "@/hooks";
import type { ColumnDef } from "@tanstack/react-table";
import dayjs from "dayjs";

interface historyDetails {
  email?: string;
  cargo?: string;
  position?: string;
  classification?: string;
  broker?: string;
  source?: string;
  duration?: string;
}

const UsersScores: NextPage = () => {
  const [user, setUser] = useState<User>({ id: null, email: null });
  const [timeRange, setTimeRange] = useState<DateValueType>({
    startDate: dayjs(new Date()).startOf("day").toDate(),
    endDate: dayjs(new Date()).endOf("day").toDate(),
  });
  const [event, setEvent] = useState<{
    created_at: string | null;
    action: string;
    detail: historyDetails;
  }>({
    created_at: "",
    action: "",
    detail: {},
  });
  const [isOpen, setIsOpen] = useState<boolean>(false);
  const [filters, setFilters] = useState({
    read: true,
    classified: true,
    positions: true,
    cargos: true,
    lineups: true,
    pause: true,
    addVessel: true,
    editVessel: true,
    addPort: true,
    shiftStatus: true,
    breakStatus: true,
  });
  const { data: history } = useUserHistory(user, timeRange);
  const { data: email } = useGetEmail(event.detail?.email ?? "", false);
  const { data: emailStatus } = useGetEmailStatus(
    event.detail?.email ?? "",
    false,
  );

  const emptyResults = {
    read: 0,
    classified: 0,
    positions: 0,
    cargos: 0,
    lineups: 0,
    pause: 0,
    addVessel: 0,
    editVessel: 0,
    addPort: 0,
    shiftStatus: 0,
    breakStatus: 0,
  };

  const results =
    history?.reduce((count, event) => {
      switch (event.action) {
        case "READ":
          return { ...count, read: count.read + 1 };
        case "CLASSIFICATION":
          return { ...count, classified: count.classified + 1 };
        case "CARGO":
          return { ...count, cargos: count.cargos + 1 };
        case "LINE-UP":
          return { ...count, lineups: count.lineups + 1 };
        case "POSITION":
          return { ...count, positions: count.positions + 1 };
        case "PAUSE":
          return { ...count, pause: count.pause + 1 };
        case "ADD_VESSEL":
          return { ...count, addVessel: count.addVessel + 1 };
        case "EDIT_VESSEL":
          return { ...count, editVessel: count.editVessel + 1 };
        case "ADD_PORT":
          return { ...count, addPort: count.addPort + 1 };
        case "SHIFT START":
        case "SHIFT END":
          return { ...count, shiftStatus: count.shiftStatus + 1 };
        case "BREAK START":
        case "BREAK END":
          return { ...count, breakStatus: count.breakStatus + 1 };
        default:
          return count;
      }
    }, emptyResults) ?? emptyResults;

  const filteredHistory =
    history?.filter((event) => {
      switch (event.action) {
        case "READ":
          return filters.read;
        case "CLASSIFICATION":
          return filters.classified;
        case "CARGO":
          return filters.cargos;
        case "LINE-UP":
          return filters.lineups;
        case "POSITION":
          return filters.positions;
        case "PAUSE":
          return filters.pause;
        case "ADD_VESSEL":
          return filters.addVessel;
        case "EDIT_VESSEL":
          return filters.editVessel;
        case "ADD_PORT":
          return filters.addPort;
        case "SHIFT START":
        case "SHIFT END":
          return filters.shiftStatus;
        case "BREAK START":
        case "BREAK END":
          return filters.breakStatus;
        default:
          return true;
      }
    }) ?? [];

  const columns: ColumnDef<{
    created_at: string | null;
    action: string;
    detail: Json;
  }>[] = [
    {
      accessorKey: "created_at",
      header: "Time",
      cell: ({ row }) => {
        const request = row.original;
        return (
          <ToolTip text={request.created_at ?? ""}>
            <div>
              <Content
                text={
                  request.created_at
                    ? new Date(request.created_at).toLocaleString("en-GB", {
                        year: "numeric",
                        month: "short",
                        day: "numeric",
                        hour: "2-digit",
                        minute: "2-digit",
                        second: "2-digit",
                      })
                    : ""
                }
              />
            </div>
          </ToolTip>
        );
      },
    },
    {
      accessorKey: "action",
      header: "Action",
    },
    {
      accessorKey: "detail",
      header: "Details",
      cell: ({ row }) => {
        const request = row.original;
        if (request.detail === null) return;
        const details = request.detail as historyDetails;
        return (
          <div>
            <If
              condition={
                request.action !== "SHIFT END" && request.action !== "BREAK END"
              }
            >
              <Content text={`Email ID: ${details.email ?? ""}`} />
            </If>
            <If condition={details.broker !== undefined}>
              <Content text={`Broker: ${details.broker ?? ""}`} />
            </If>
            <If condition={details.source !== undefined}>
              <Content text={`Source: ${details.source ?? ""}`} />
            </If>
            <If condition={details.classification !== undefined}>
              <Content
                text={`Classification: ${details.classification ?? ""}`}
              />
            </If>
            <If condition={details.position !== undefined}>
              <Content text={`Position Report ID: ${details.position ?? ""}`} />
            </If>
            <If condition={details.cargo !== undefined}>
              <Content text={`Cargo Report ID: ${details.cargo ?? ""}`} />
            </If>
            <If
              condition={
                request.action === "SHIFT END" && details.duration !== undefined
              }
            >
              <Content text={`Shift Duration: ${details.duration}`} />
            </If>
            <If
              condition={
                request.action === "BREAK END" && details.duration !== undefined
              }
            >
              <Content text={`Break Duration: ${details.duration}`} />
            </If>
          </div>
        );
      },
    },
  ];

  const ModalContent = () => {
    const details = event.detail as historyDetails;
    return (
      <div className="grid grid-cols-2 justify-items-center gap-4">
        <div className="w-full">
          <div className="pb-4">
            <Subheading text={`User Event: ${event.action}`} />
            <DisclosureButton buttonText="Email Status" colour="Primary">
              <Content
                text={`Classifications: ${emailStatus?.classification}`}
              />
              <Content text={`Priority: ${emailStatus?.priority}`} />
              <IfElse
                condition={emailStatus?.complete ?? false}
                elseChildren={<Content text="Completed: No" />}
              >
                <Content
                  text={`Completed: ${
                    emailStatus?.completed_by
                      ? emailStatus.completed_by
                      : "UNKNOWN"
                  } at ${emailStatus?.completed_at}`}
                />
              </IfElse>
              <If
                condition={
                  emailStatus?.classification
                    ?.split(",")
                    .includes("POSITION") ?? false
                }
              >
                <Content
                  text={`Position Reports: ${emailStatus?.position_reports.length}`}
                />
              </If>
              <If
                condition={
                  emailStatus?.classification?.split(",").includes("CARGO") ??
                  false
                }
              >
                <Content
                  text={`Cargo Reports: ${emailStatus?.cargo_reports.length}`}
                />
              </If>
            </DisclosureButton>
          </div>
          <EmailViewer
            email={email}
            historyNeedsUpdating={false}
            allowNextEmail={false}
          />
        </div>
        <If condition={event.action === "CLASSIFICATION"}>
          <ScoreClassificationResults
            classification={event.detail.classification}
            emailId={details.email}
            user={user.id ?? undefined}
          />
        </If>
        <If condition={event.action === "POSITION"}>
          <div className="flex w-4/5 flex-col items-center">
            <Subheading text="Score Position Reports" />
            <div className="flex w-4/5 flex-col gap-4">
              {emailStatus?.position_reports.map((report) => {
                return (
                  <DisclosureButton
                    key={report.id}
                    buttonText={`Report: ${report.id}`}
                    colour={
                      `${report.id}` == details.position ? "Success" : "Accent"
                    }
                  >
                    <ScorePositionResults
                      report={report}
                      emailId={details.email}
                    />
                  </DisclosureButton>
                );
              })}
            </div>
          </div>
        </If>
        <If condition={event.action === "CARGO"}>
          <div className="flex w-4/5 flex-col items-center">
            <div className="flex w-4/5 flex-col gap-4">
              {emailStatus?.cargo_reports.map((report) => {
                return (
                  <DisclosureButton
                    key={report.id}
                    buttonText={`Report: ${report.id}`}
                    colour={
                      `${report.id}` == details.position ? "Success" : "Accent"
                    }
                  >
                    <ScoreCargoResults
                      report={report}
                      emailId={details.email}
                    />
                  </DisclosureButton>
                );
              })}
            </div>
          </div>
        </If>
        <If condition={event.action === "LINE-UP"}>
          <div className="flex w-4/5 flex-col items-center">
            <div className="flex w-4/5 flex-col gap-4">
              {emailStatus?.lineup_reports.map((report) => {
                return (
                  <DisclosureButton
                    key={report.id}
                    buttonText={`Report: ${report.id}`}
                    colour={
                      `${report.id}` == details.position ? "Success" : "Accent"
                    }
                  >
                    <ScoreLineupResults
                      report={report}
                      emailId={details.email}
                    />
                  </DisclosureButton>
                );
              })}
            </div>
          </div>
        </If>
        <div className="col-span-2 w-full">
          <EmailUtitlities />
        </div>
      </div>
    );
  };

  return (
    <MinimalPage
      pageTitle={"Review Users | Email Interface"}
      pageDescription={"Spot Ship Email Interface | Review Users"}
      commandPrompt
    >
      <CommandInterface />
      <div className="w-full">
        <HeadingLink icon={"back"} text={"Home"} href={`/secure/home`} />
      </div>
      <div>
        <PageHeading text="User Scores" />
      </div>
      <div className="w-full p-8">
        <UserAutocomplete
          id="user"
          label="Who:"
          labelWidth="w-52"
          value={user}
          onChange={(data) => {
            if (data) setUser(data);
          }}
        />
        <FormDateTimeRangeField
          id="date"
          label="Time Frame"
          labelWidth="w-52"
          value={timeRange}
          onChange={(date: DateValueType) => {
            setTimeRange(date);
          }}
          warning
          warningDaysInPast={30}
          warningDaysInFuture={1}
          pastWarning={"should be no earlier than 30 days from now"}
        />
        <DisclosureButton
          buttonText={`Results: ${history?.length}${
            history?.length === 1000
              ? "Max results reached, narrow time range"
              : ""
          }`}
          colour="Primary"
        >
          <Subheading text="Include Events" />
          <div className="mb-2 grid gap-1 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-6 xl:grid-cols-8">
            <FormCheckboxField
              id="filter-read"
              label="READ"
              caption={`Emails Read: ${results.read}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    read: enabled,
                  };
                });
              }}
              defaultState={filters.read}
            />
            <FormCheckboxField
              id="filter-classifications"
              label="CLASSIFICATION"
              caption={`Classifications: ${results.classified}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    classified: enabled,
                  };
                });
              }}
              defaultState={filters.classified}
            />
            <FormCheckboxField
              id="filter-positions"
              label="POSITION"
              caption={`Position Submissions: ${results.positions}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    positions: enabled,
                  };
                });
              }}
              defaultState={filters.positions}
            />
            <FormCheckboxField
              id="filter-cargos"
              label="CARGO"
              caption={`Cargo Submissions: ${results.cargos}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    cargos: enabled,
                  };
                });
              }}
              defaultState={filters.cargos}
            />
            <FormCheckboxField
              id="filter-lineups"
              label="LINE-UP"
              caption={`Line Up Submissions: ${results.lineups}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    lineups: enabled,
                  };
                });
              }}
              defaultState={filters.lineups}
            />
            <FormCheckboxField
              id="filter-pause"
              label="PAUSE"
              caption={`Pauses: ${results.pause}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    pause: enabled,
                  };
                });
              }}
              defaultState={filters.pause}
            />
            <FormCheckboxField
              id="filter-add-vessel"
              label="ADD_VESSEL"
              caption={`Added Vessels: ${results.addVessel}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    addVessel: enabled,
                  };
                });
              }}
              defaultState={filters.addVessel}
            />
            <FormCheckboxField
              id="filter-edit-vessel"
              label="EDIT_VESSEL"
              caption={`Edited Vessels: ${results.editVessel}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    editVessel: enabled,
                  };
                });
              }}
              defaultState={filters.editVessel}
            />
            <FormCheckboxField
              id="filter-add-port"
              label="ADD_PORT"
              caption={`Added Ports : ${results.addPort}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    addPort: enabled,
                  };
                });
              }}
              defaultState={filters.addPort}
            />
            <FormCheckboxField
              id="filter-shift-status"
              label="SHIFT STATUS"
              caption={`Shift Status Events: ${results.shiftStatus}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    shiftStatus: enabled,
                  };
                });
              }}
              defaultState={filters.shiftStatus}
            />
            <FormCheckboxField
              id="filter-break-status"
              label="BREAK STATUS"
              caption={`Break Status Events: ${results.breakStatus}`}
              action={(enabled: boolean) => {
                setFilters((prevState) => {
                  return {
                    ...prevState,
                    breakStatus: enabled,
                  };
                });
              }}
              defaultState={filters.breakStatus}
            />
          </div>
          <div className="max-h-[600px] w-full gap-8 overflow-scroll p-8">
            <DataTable
              action={(obj: {
                created_at: string | null;
                action: string;
                detail: historyDetails;
              }) => {
                setEvent(obj);
                if (obj.detail && obj.detail.email !== undefined) {
                  setIsOpen(true);
                }
              }}
              showFilterInput
              filterValue="created_at"
              data={filteredHistory}
              columns={columns}
            />
          </div>
        </DisclosureButton>
        <DialogButton action={() => setIsOpen(false)} isOpen={isOpen}>
          <ModalContent />
        </DialogButton>
      </div>
    </MinimalPage>
  );
};

export default UsersScores;
import React, { useState } from "react";
import { useSupabaseClient } from "@supabase/auth-helpers-react";
import {
  ButtonContent,
  CaptionText,
  Conditional,
  dateToTimeString,
  PrimaryButton,
  SecondaryButton,
} from "ui";
import { useUserShiftStart } from "../../hooks";
import { useQueryClient } from "react-query";
import { CirclePlay, CircleStop } from "lucide-react";

interface ShiftStatus {
  isOnShift: boolean;
  onShiftSince: string | null | undefined;
  isOnBreak: boolean;
  onBreakSince: string | null | undefined;
}

export const UserShiftStateButton = () => {
  const {
    data: shiftStatus,
    isError,
    error: loadShiftStatusError,
  } = useUserShiftStart();
  const [error, setError] = useState<string>();
  const supabaseClient = useSupabaseClient();
  const queryClient = useQueryClient();

  const logUserAction = async (
    action: string,
    details: object | null,
    userId: string,
  ) => {
    const { error: insertError } = await supabaseClient
      .from("UserHistory")
      .insert([{ user: userId, action, detail: details }]);
    if (insertError) {
      setError("Failed to log user action");
    }
  };

  const toggleShiftStatus = async () => {
    const { data: sessionData } = await supabaseClient.auth.getSession();
    if (sessionData?.session) {
      const userId = sessionData.session.user.id;
      const now = new Date().toISOString();
      let newStatus: string;
      let details: { duration?: string; start?: string; end?: string } | null =
        null;

      if (shiftStatus?.isOnShift && shiftStatus.onShiftSince) {
        const shiftStart = new Date(shiftStatus.onShiftSince);
        const shiftEnd = new Date();
        const shiftDuration = shiftEnd.getTime() - shiftStart.getTime();
        details = {
          duration: dateToTimeString(shiftDuration),
          start: shiftStart.toISOString(),
          end: shiftEnd.toISOString(),
        };
        newStatus = "SHIFT END";

        if (shiftStatus.isOnBreak && shiftStatus.onBreakSince) {
          const breakStart = new Date(shiftStatus.onBreakSince);
          const breakEnd = new Date();
          const breakDuration = breakEnd.getTime() - breakStart.getTime();
          const breakDetails = {
            duration: dateToTimeString(breakDuration),
            start: breakStart.toISOString(),
            end: breakEnd.toISOString(),
          };
          await logUserAction("BREAK END", breakDetails, userId);
        }
      } else {
        newStatus = "SHIFT START";
      }

      const { error: updateError } = await supabaseClient
        .from("UserLastWorkedOn")
        .update({
          shift_start: shiftStatus?.isOnShift ? null : now,
          break_start: null,
        })
        .eq("user", userId);

      if (updateError) {
        setError("Failed to toggle shift status");
        return;
      }

      await logUserAction(newStatus, details, userId);
      queryClient.invalidateQueries({ queryKey: ["userShiftStatus"] });
    }
  };

  const toggleBreakStatus = async () => {
    const { data: sessionData } = await supabaseClient.auth.getSession();
    if (sessionData?.session) {
      const userId = sessionData.session.user.id;
      const now = new Date().toISOString();
      let newStatus: string;
      let details: { duration?: string; start?: string; end?: string } | null =
        null;

      if (shiftStatus?.isOnBreak && shiftStatus.onBreakSince) {
        const breakStart = new Date(shiftStatus.onBreakSince);
        const breakEnd = new Date();
        const breakDuration = breakEnd.getTime() - breakStart.getTime();
        details = {
          duration: dateToTimeString(breakDuration),
          start: breakStart.toISOString(),
          end: breakEnd.toISOString(),
        };
        newStatus = "BREAK END";
      } else {
        newStatus = "BREAK START";
      }

      const { error: updateError } = await supabaseClient
        .from("UserLastWorkedOn")
        .update({
          break_start: shiftStatus?.isOnBreak ? null : now,
        })
        .eq("user", userId);

      if (updateError) {
        setError("Failed to toggle break status");
        return;
      }

      await logUserAction(newStatus, details, userId);
      queryClient.invalidateQueries({ queryKey: ["userShiftStatus"] });
    }
  };

  return (
    <Conditional
      condition={!isError}
      elseChildren={
        <CaptionText>
          Error: {isError ? `${loadShiftStatusError}` : ""}
          {error}
        </CaptionText>
      }
    >
      <CaptionText className="mt-1">
        You are {shiftStatus?.isOnShift ? "On" : "Off"} shift
      </CaptionText>
      <PrimaryButton
        onClick={toggleShiftStatus}
        className="min-w-32 rounded-none rounded-bl-md rounded-tl-md"
      >
        <ButtonContent className="gap-2">
          <div>{shiftStatus?.isOnShift ? "End" : "Start"} Shift</div>
          <Conditional
            condition={!shiftStatus?.isOnShift}
            elseChildren={<CircleStop size={16} />}
          >
            <CirclePlay size={16} />
          </Conditional>
        </ButtonContent>
      </PrimaryButton>
      <SecondaryButton
        onClick={toggleBreakStatus}
        disabled={!shiftStatus?.isOnShift}
        className="min-w-32 rounded-none rounded-br-md rounded-tr-md"
      >
        <ButtonContent className="gap-2">
          <div>{shiftStatus?.isOnBreak ? "End" : "Start"} Break</div>
          <Conditional
            condition={!shiftStatus?.isOnBreak}
            elseChildren={<CircleStop size={16} />}
          >
            <CirclePlay size={16} />
          </Conditional>
        </ButtonContent>
      </SecondaryButton>
    </Conditional>
  );
};
    #[Test]
    public function title_is_required()
    {
        Livewire::test(CreatePost::class)
            ->set('title', '')
            ->call('save')
            // It checks if the validation rule 'required' is triggered for the 'title' empty string field after the form submission.
            ->assertHasErrors(['title' => 'required'])
            // It checks if the validation rule 'min:4' is triggered for the empty 'title' field after the form submission.
            ->assertHasErrors(['title' => 'min:4']);
    }
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Taste of India Menu</title>
    <link rel="stylesheet" href="styles.css">
    <style>
        /* Additional styles for menu.html */
        body {
            font-family: Arial, sans-serif;
            background-color: #fff;
            color: #333;
            margin: 0;
            padding: 0;
        }

        h1 {
            text-align: center;
            color: #ff5733; /* Match the title color with the menu-section h2 color */
            margin: 20px 0; /* Ensure margin around the title */
        }

        .menu-container {
            display: flex;
            flex-wrap: wrap;
            justify-content: space-between;
            margin: 20px auto; /* Adjust margin to ensure visibility */
            width: 90%; /* Set a fixed width to center content */
        }

        .menu-column {
            width: 15%; /* Adjust width to ensure six columns fit well */
            margin-bottom: 20px;
        }

        .menu-section {
            margin-bottom: 20px;
        }

        .menu-section h2 {
            font-size: 24px;
            color: #ff5733; /* Set color to orange */
            margin-bottom: 10px;
        }

        .menu-item {
            font-size: 18px;
            margin-bottom: 10px;
            color: #FFDAB9; /* Set color to peach */
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .price {
            float: right;
            color: #333; /* Set color to dark gray */
        }

        .quantity-container {
            display: flex;
            align-items: center;
        }

        .quantity-button {
            width: 20px;
            height: 20px;
            font-size: 14px;
            margin: 0 3px; /* Adjust the margin */
            background-color: #ff5733;
            color: #fff;
            border: none;
            border-radius: 70%; /* Decrease the border-radius */
            cursor: pointer;
            display: flex;
            justify-content: center;
            align-items: center;
        }
    </style>
</head>
<body>
    <h1>Taste of India</h1>
    <div class="menu-container">
        <div class="menu-column">
            <div class="menu-section">
                <h2>BIRYANIS</h2>
                <div class="menu-item">
                    <span>Chicken Biryani</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Mutton Biryani</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Veg Biryani</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Egg Biryani</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Fish Biryani</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>PRICE</h2>
                <div class="menu-item">$8.99</div><br><br>
                <div class="menu-item">$9.99</div><br>
                <div class="menu-item">$6.99</div><br>
                <div class="menu-item">$7.99</div><br>
                <div class="menu-item">$10.99</div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>DESSERT</h2>
                <div class="menu-item">
                    <span>Kajur sweet</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Rasa gulla</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Kulfi  </span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Kajuu sweet</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Jalebi sweet</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Barfii sweet</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>PRICE</h2>
                <div class="menu-item">$4.99</div>
		<br><br>
                <div class="menu-item">$3.99</div>
		<br>
                <div class="menu-item">$2.99</div>
		<br>
                <div class="menu-item">$5.49</div>
		<br>
                <div class="menu-item">$6.99</div>
		<br>
		<div class="menu-item">$5.99</div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>DRINKS</h2>
                <div class="menu-item">
                    <span>Mango Lassi</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Masala Chai</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Lemon Soda</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Thand Lassi</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Butter milk</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>PRICE</h2>
                <div class="menu-item">$3.99</div><br><br>
                <div class="menu-item">$2.49</div><br>
                <div class="menu-item">$1.99</div><br>
                <div class="menu-item">$4.49</div><br>
                <div class="menu-item">$2.99</div>
            </div>
        </div>
    </div>
    <button class="back-button" onclick="window.location.href='menu.html'">Back</button>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Taste of India Menu</title>
    <link rel="stylesheet" href="styles.css">
    <style>
        /* Additional styles for menu.html */
        body {
            font-family: Arial, sans-serif;
            background-color: #fff;
            color: #333;
            margin: 0;
            padding: 0;
        }

        h1 {
            text-align: center;
            color: #ff5733; /* Match the title color with the menu-section h2 color */
            margin: 20px 0; /* Ensure margin around the title */
        }

        .menu-container {
            display: flex;
            flex-wrap: wrap;
            justify-content: space-between;
            margin: 20px auto; /* Adjust margin to ensure visibility */
            width: 90%; /* Set a fixed width to center content */
        }

        .menu-column {
            width: 15%; /* Adjust width to ensure six columns fit well */
            margin-bottom: 20px;
        }

        .menu-section {
            margin-bottom: 20px;
        }

        .menu-section h2 {
            font-size: 24px;
            color: #ff5733; /* Set color to orange */
            margin-bottom: 10px;
        }

        .menu-item {
            font-size: 18px;
            margin-bottom: 10px;
            color: #FFDAB9; /* Set color to peach */
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .price {
            float: right;
            color: #333; /* Set color to dark gray */
        }

        .quantity-container {
            display: flex;
            align-items: center;
        }

        .quantity-button {
            width: 20px;
            height: 20px;
            font-size: 14px;
            margin: 0 3px; /* Adjust the margin */
            background-color: #ff5733;
            color: #fff;
            border: none;
            border-radius: 70%; /* Decrease the border-radius */
            cursor: pointer;
            display: flex;
            justify-content: center;
            align-items: center;
        }
    </style>
</head>
<body>
    <h1>Taste of India</h1>
    <div class="menu-container">
        <div class="menu-column">
            <div class="menu-section">
                <h2>SOUPS</h2>
                <div class="menu-item">
                    <span>VegThai soup</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Eggdrop soup</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Chicken soup</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Wonton soup</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Prawns soup</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>PRICE</h2>
                <div class="menu-item">$8.99</div><br><br>
                <div class="menu-item">$9.99</div><br>
                <div class="menu-item">$6.99</div><br>
                <div class="menu-item">$7.99</div><br>
                <div class="menu-item">$10.99</div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>STARTERS</h2>
                <div class="menu-item">
                    <span>Onion Pakoda</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Panner fry</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Crispy Panner </span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>chicken 65</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>chicken Pakodi</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>chicken Kabab</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>PRICE</h2>
                <div class="menu-item">$4.99</div>
		<br><br>
                <div class="menu-item">$3.99</div>
		<br>
                <div class="menu-item">$2.99</div>
		<br>
                <div class="menu-item">$5.49</div>
		<br>
                <div class="menu-item">$6.99</div>
		<br>
		<div class="menu-item">$5.99</div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>Main Course</h2>
                <div class="menu-item">
                    <span>Rajma masala</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Panner Masala</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>EggFry</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Butter chicken</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
                <div class="menu-item">
                    <span>Prawns curry</span>
                    <div class="quantity-container">
                        <button class="quantity-button" onclick="decrement(this)">-</button>
                        <span class="quantity">0</span>
                        <button class="quantity-button" onclick="increment(this)">+</button>
                    </div>
                </div>
            </div>
        </div>
        <div class="menu-column">
            <div class="menu-section">
                <h2>PRICE</h2>
                <div class="menu-item">$3.99</div><br><br>
                <div class="menu-item">$2.49</div><br>
                <div class="menu-item">$1.99</div><br>
                <div class="menu-item">$4.49</div><br>
                <div class="menu-item">$2.99</div>
            </div>
        </div>
    </div>
   <div class="button-container">
        <button class="back-button" onclick="window.location.href='customer.html'">Back</button>
        <button class="next-button" onclick="window.location.href='menu2.html'">Next Page</button>
    </div>

</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Taste of India</title>
    <link rel="stylesheet" href="styles.css">
    <style>
        /* Additional styles for customer.html */
        body {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            height: 100vh; /* Ensure full height */
            margin: 0; /* Remove default margin */
            padding: 0; /* Remove default padding */
        }

        .button-container {
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            gap: 20px;
            margin-top: 20px;
        }

        .table-button {
            padding: 15px 30px;
            font-size: 16px;
            cursor: pointer;
            border: none;
            border-radius: 5px;
            background-color: #007bff;
            color: white;
            font-weight: bold;
        }

        .table-button:hover {
            background-color: #0056b3;
        }

        .back-button {
            margin-top: 20px;
        }
    </style>
</head>
<body>
    <h1>TASTE OF INDIA</h1>
    <div class="info-container">
        <p>
            Welcome to Taste of India! We serve delicious Indian cuisine that will tantalize your taste buds and leave you wanting more. Our dishes are made with fresh, high-quality ingredients, bursting with flavor and spices that will awaken your senses. Whether you're craving savory curries, aromatic biryanis, or crispy samosas, we have something for everyone. Come and experience the authentic taste of India with us!
        </p>
    </div>
    <div class="button-container">
        <button class="table-button" onclick="window.location.href='menu.html'">Table 1</button>
        <button class="table-button" onclick="window.location.href='menu.html'">Table 2</button>
        <button class="table-button" onclick="window.location.href='menu.html'">Table 3</button>
        <button class="table-button" onclick="window.location.href='menu.html'">Table 4</button>
        <button class="table-button" onclick="window.location.href='menu.html'">Table 5</button>
        <button class="table-button" onclick="window.location.href='menu.html'">Table 6</button>
        <button class="table-button" onclick="window.location.href='menu.html'">Table 7</button>
    </div>
    <button class="back-button" onclick="window.location.href='index.html'">Back</button>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Administration</title>
    <link rel="stylesheet" href="styles.css">
    <style>
        .input-container {
            display: flex;
            flex-direction: column;
            align-items: center;
            margin-bottom: 20px;
        }
        .input-container input {
            padding: 10px;
            margin-bottom: 10px;
            width: 200px;
            border-radius: 5px;
            border: 1px solid #ccc;
        }
    </style>
</head>
<body>
    <h1>ADMINISTRATION</h1>
    <div class="input-container">
        <input type="text" placeholder="Username">
        <input type="password" placeholder="Password">
    </div>
    <div class="button-container">
        <button onclick="window.location.href='index.html'">BACK</button>
    </div>
</body>
</html>
/* Global styles */
body {
    font-family: Arial, sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: url('backgroundimage1.jpg') no-repeat center center fixed;
    background-size: cover;
    height: 100vh;
    margin: 0;
}

h1 {
    color: #ff5733;
    font-size: 48px; /* Increased font size */
    margin-bottom: 50px;
}

.button-container {
    display: flex;
    gap: 20px;
}

button {
    padding: 15px 30px;
    font-size: 16px;
    cursor: pointer;
    border: none;
    border-radius: 5px;
    background-color: #007bff;
    color: white;
    font-weight: bold; /* Make text bold */
}

button:hover {
    background-color: #0056b3;
}

button:nth-of-type(1) {
    color: black; /* Black color for "ADMINISTRATION" button */
}

button:nth-of-type(2) {
    color: gold; /* Gold color for "CUSTOMER" button */
}

/* Specific styles for customer.html */
.info-container p {
    color: gold; /* Maroon color for paragraph text */
    font-weight: bold; /* Make paragraph text bold */
    font-size: 18px; /* Increased font size for paragraph text */
}

/* Specific styles for customer.html */
.button-container .table-button:nth-of-type(2) {
    color: black; /* Black text color for Table 2 button */
}

/* Set text color to black for Table 3 to Table 7 buttons */
.button-container .table-button:nth-of-type(n+1) {
    color: black;
}
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Taste of India</title>
    <link rel="stylesheet" href="styles.css">
</head>
<body>
    <h1>TASTE OF INDIA</h1>
    <div class="button-container">
        <button onclick="window.location.href='administration.html'">ADMINISTRATION</button>
        <button onclick="window.location.href='customer.html'">CUSTOMER</button>
    </div>
</body>
</html>
<?php

namespace Tests\Feature\Livewire;

use App\Livewire\CreatePost;
use App\Models\Post;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Foundation\Testing\WithFaker;
use Livewire\Livewire;
use PHPUnit\Framework\Attributes\Test;
use Tests\TestCase;

class CreatePostTest extends TestCase
{
    #[Test]
    public function renders_successfully()
    {
        Livewire::test(CreatePost::class)
            ->assertStatus(200);
    }

    #[Test]
    public function can_create_new_post()
    {
        //delete the user if present
        Post::whereTitle('hello tashi')->delete();
        //to test if the title hello tashi is there or not
        //if returns a value test fails since no such data in the database
        $post = Post::whereTitle('hello tashi')->first();
        //should return null --> test successs
        $this->assertNull($post);

        //create a post with the title hello tenzin
        Livewire::test(CreatePost::class)
            ->set('title', 'hello tashi')
            ->set('content', 'hello tenzin content')
            ->call('save');

        //gettign the post just created with title hello tenzin
        $post = Post::whereTitle('hello tashi')->first();

        //to test it should return true since now there is a post with title hello tenzin
        $this->assertNotNull($post);
        //if the $post title not equals to hello tashi -- the test should fail
        $this->assertEquals('hello tashi', $post->title);
        //same same above
        $this->assertEquals('hello tenzin content', $post->content);
    }
}
extends CharacterBody3D

signal health_changed(health_value)

@onready var camera = $Camera3D
@onready var anim_player = $AnimationPlayer
@onready var muzzle_flash = $Camera3D/gun/MuzzleFlash
@onready var raycast = $Camera3D/RayCast3D

@onready var health = 5

const SPEED = 10.0
const JUMP_VELOCITY = 10.0

# Get the gravity from the project settings to be synced with RigidBody nodes.
var gravity = 20.0

func _enter_tree():
	set_multiplayer_authority(str(name).to_int())

func _ready():
	if not is_multiplayer_authority(): return
	
	Input.mouse_mode = Input.MOUSE_MODE_CAPTURED
	camera.current = true

func _unhandled_input(event):
	if not is_multiplayer_authority(): return
	
	if event is InputEventMouseMotion:
		rotate_y(-event.relative.x * .005)
		camera.rotate_x(-event.relative.y * .005)
		camera.rotation.x = clamp(camera.rotation.x, -PI/2, PI/2)
	
	if Input.is_action_just_pressed("shoot") \
			and anim_player.current_animation != "shoot":
		play_shoot_effects.rpc()
		if raycast.is_colliding():
			var hit_player = raycast.get_collider()
			hit_player.receive_damage.rpc_id(hit_player.get_multiplayer_authority())

func _physics_process(delta):
	if not is_multiplayer_authority(): return
	
	# Add the gravity.
	if not is_on_floor():
		velocity.y -= gravity * delta

	# Handle Jump.
	if Input.is_action_just_pressed("ui_accept") and is_on_floor():
		velocity.y = JUMP_VELOCITY

	# Get the input direction and handle the movement/deceleration.
	# As good practice, you should replace UI actions with custom gameplay actions.
	var input_dir = Input.get_vector("left", "right", "up", "down")
	var direction = (transform.basis * Vector3(input_dir.x, 0, input_dir.y)).normalized()
	if direction:
		velocity.x = direction.x * SPEED
		velocity.z = direction.z * SPEED
	else:
		velocity.x = move_toward(velocity.x, 0, SPEED)
		velocity.z = move_toward(velocity.z, 0, SPEED)

	if anim_player.current_animation == "shoot":
		pass
	elif input_dir != Vector2.ZERO and is_on_floor():
		anim_player.play("move")
	else:
		anim_player.play("idle")

	move_and_slide()

@rpc("call_local")
func play_shoot_effects():
	anim_player.stop()
	anim_player.play("shoot")
	muzzle_flash.restart()
	muzzle_flash.emitting = true

@rpc("any_peer")
func receive_damage():
	health -= 1
	if health <= 0:
		health = 3
		position = Vector3.ZERO
	health_changed.emit(health)

func _on_animation_player_animation_finished(anim_name):
	if anim_name == "shoot":
		anim_player.play("idle")
SHA 256 Hash	Subject	NotBefore	NotAfter
55926084ec963a64b96e2abe01ce0ba86a64fbfebcc7aab5afc155b37fd76066	CN=Actalis Authentication Root CA,O=Actalis S.p.A./03358520967,L=Milan,C=IT	2011-09-22	2030-09-22
18ce6cfe7bf14e60b2e347b8dfe868cb31d02ebb3ada271569f50343b46db3a4	CN=Amazon Root CA 3,O=Amazon,C=US	2015-05-26	2040-05-26
1ba5b2aa8c65401a82960118f80bec4f62304d83cec4713a19c39c011ea46db4	CN=Amazon Root CA 2,O=Amazon,C=US	2015-05-26	2040-05-26
8ecde6884f3d87b1125ba31ac3fcb13d7016de7f57cc904fe1cb97c6ae98196e	CN=Amazon Root CA 1,O=Amazon,C=US	2015-05-26	2038-01-17
e35d28419ed02025cfa69038cd623962458da5c695fbdea3c22b0bfb25897092	CN=Amazon Root CA 4,O=Amazon,C=US	2015-05-26	2040-05-26
5c58468d55f58e497e743982d2b50010b6d165374acf83a7d4a32db768c4408e	CN=Certum Trusted Network CA,OU=Certum Certification Authority,O=Unizeto Technologies S.A.,C=PL	2008-10-22	2029-12-31
b676f2eddae8775cd36cb0f63cd1d4603961f49e6265ba013a2f0307b6d0b804	CN=Certum Trusted Network CA 2,OU=Certum Certification Authority,O=Unizeto Technologies S.A.,C=PL	2011-10-06	2046-10-06
f356bea244b7a91eb35d53ca9ad7864ace018e2d35d5f8f96ddf68a6f41aa474	CN=Atos TrustedRoot 2011,O=Atos,C=DE	2011-07-07	2030-12-31
57de0583efd2b26e0361da99da9df4648def7ee8441c3b728afa9bcde0f9b26a	CN=Autoridad de Certificacion Firmaprofesional CIF A62634068,C=ES	2014-09-23	2036-05-05
9a114025197c5bb95d94e63d55cd43790847b646b23cdf11ada4a00eff15fb48	CN=Buypass Class 2 Root CA,O=Buypass AS-983163327,C=NO	2010-10-26	2040-10-26
edf7ebbca27a2a384d387b7d4010c666e2edb4843e4c29b4ae1d5b9332e6b24d	CN=Buypass Class 3 Root CA,O=Buypass AS-983163327,C=NO	2010-10-26	2040-10-26
657cfe2fa73faa38462571f332a2363a46fce7020951710702cdfbb6eeda3305	OU=certSIGN ROOT CA G2,O=CERTSIGN SA,C=RO	2017-02-06	2042-02-06
eaa962c4fa4a6bafebe415196d351ccd888d4f53f3fa8ae6d7c466a94e6042bb	OU=certSIGN ROOT CA,O=certSIGN,C=RO	2006-07-04	2031-07-04
5cc3d78e4e1d5e45547a04e6873e64f90cf9536d1ccc2ef800f355c4c5fd70fd	CN=CFCA EV ROOT,O=China Financial Certification Authority,C=CN	2012-08-08	2029-12-31
c0a6f4dc63a24bfdcf54ef2a6a082a0a72de35803e2ff5ff527ae5d87206dfd5	OU=ePKI Root Certification Authority,O=Chunghwa Telecom Co., Ltd.,C=TW	2004-12-20	2034-12-20
bf0feefb9e3a581ad5f9e9db7589985743d261085c4d314f6f5d7259aa421612	CN=SecureSign RootCA11,O=Japan Certification Services, Inc.,C=JP	2009-04-08	2029-04-08
49e7a442acf0ea6287050054b52564b650e4f49e42e348d6aa38e039e957b1c1	CN=D-TRUST Root Class 3 CA 2 2009,O=D-Trust GmbH,C=DE	2009-11-05	2029-11-05
eec5496b988ce98625b934092eec2908bed0b0f316c2d4730c84eaf1f3d34881	CN=D-TRUST Root Class 3 CA 2 EV 2009,O=D-Trust GmbH,C=DE	2009-11-05	2029-11-05
91e2f5788d5810eba7ba58737de1548a8ecacd014598bc0b143e041b17052552	CN=T-TeleSec GlobalRoot Class 2,OU=T-Systems Trust Center,O=T-Systems Enterprise Services GmbH,C=DE	2008-10-01	2033-10-01
fd73dad31c644ff1b43bef0ccdda96710b9cd9875eca7e31707af3e96d522bbd	CN=T-TeleSec GlobalRoot Class 3,OU=T-Systems Trust Center,O=T-Systems Enterprise Services GmbH,C=DE	2008-10-01	2033-10-01
d48d3d23eedb50a459e55197601c27774b9d7b18c94d5a059511a10250b93168	CN=Certigna Root CA,OU=0002 48146308100036,O=Dhimyotis,C=FR	2013-10-01	2033-10-01
e3b6a2db2ed7ce48842f7ac53241c7b71d54144bfb40c11f3f1d0b42f5eea12d	CN=Certigna,O=Dhimyotis,C=FR	2007-06-29	2027-06-29
16af57a9f676b0ab126095aa5ebadef22ab31119d644ac95cd4b93dbf3f26aeb	CN=Baltimore CyberTrust Root,OU=CyberTrust,O=Baltimore,C=IE	2000-05-12	2025-05-12
31ad6648f8104138c738f39ea4320133393e3a18cc02296ef97c2ac9ef6731d0	CN=DigiCert Global Root G3,OU=www.digicert.com,O=DigiCert Inc,C=US	2013-08-01	2038-01-15
3e9099b5015e8f486c00bcea9d111ee721faba355a89bcf1df69561e3dc6325c	CN=DigiCert Assured ID Root CA,OU=www.digicert.com,O=DigiCert Inc,C=US	2006-11-10	2031-11-10
4348a0e9444c78cb265e058d5e8944b4d84f9662bd26db257f8934a443c70161	CN=DigiCert Global Root CA,OU=www.digicert.com,O=DigiCert Inc,C=US	2006-11-10	2031-11-10
552f7bdcf1a7af9e6ce672017f4f12abf77240c78e761ac203d1d9d20ac89988	CN=DigiCert Trusted Root G4,OU=www.digicert.com,O=DigiCert Inc,C=US	2013-08-01	2038-01-15
7431e5f4c3c1ce4690774f0b61e05440883ba9a01ed00ba6abd7806ed3b118cf	CN=DigiCert High Assurance EV Root CA,OU=www.digicert.com,O=DigiCert Inc,C=US	2006-11-10	2031-11-10
7d05ebb682339f8c9451ee094eebfefa7953a114edb2f44949452fab7d2fc185	CN=DigiCert Assured ID Root G2,OU=www.digicert.com,O=DigiCert Inc,C=US	2013-08-01	2038-01-15
7e37cb8b4c47090cab36551ba6f45db840680fba166a952db100717f43053fc2	CN=DigiCert Assured ID Root G3,OU=www.digicert.com,O=DigiCert Inc,C=US	2013-08-01	2038-01-15
cb3ccbb76031e5e0138f8dd39a23f9de47ffc35e43c1144cea27d46a5ab1cb5f	CN=DigiCert Global Root G2,OU=www.digicert.com,O=DigiCert Inc,C=US	2013-08-01	2038-01-15
e23d4a036d7b70e9f595b1422079d2b91edfbb1fb651a0633eaa8a9dc5f80703	CN=CA Disig Root R2,O=Disig a.s.,L=Bratislava,C=SK	2012-07-19	2042-07-19
125609aa301da0a249b97a8239cb6a34216f44dcac9f3954b14292f2e8c8608f	CN=emSign Root CA - C1,OU=emSign PKI,O=eMudhra Inc,C=US	2018-02-18	2043-02-18
40f6af0346a99aa1cd1d555a4e9cce62c7f9634603ee406615833dc8c8d00367	CN=emSign Root CA - G1,OU=emSign PKI,O=eMudhra Technologies Limited,C=IN	2018-02-18	2043-02-18
86a1ecba089c4a8d3bbe2734c612ba341d813e043cf9e8a862cd5c57a36bbe6b	CN=emSign ECC Root CA - G3,OU=emSign PKI,O=eMudhra Technologies Limited,C=IN	2018-02-18	2043-02-18
bc4d809b15189d78db3e1d8cf4f9726a795da1643ca5f1358e1ddb0edc0d7eb3	CN=emSign ECC Root CA - C3,OU=emSign PKI,O=eMudhra Inc,C=US	2018-02-18	2043-02-18
02ed0eb28c14da45165c566791700d6451d7fb56f0b2ab1d3b8eb070e56edff5	CN=Entrust Root Certification Authority - EC1,OU=See www.entrust.net/legal-terms+OU=(c) 2012 Entrust, Inc. - for authorized use only,O=Entrust, Inc.,C=US	2012-12-18	2037-12-18
0376ab1d54c5f9803ce4b2e201a0ee7eef7b57b636e8a93c9b8d4860c96f5fa7	CN=AffirmTrust Commercial,O=AffirmTrust,C=US	2010-01-29	2030-12-31
0a81ec5a929777f145904af38d5d509f66b5e2c58fcdb531058b0e17f3f0b41b	CN=AffirmTrust Networking,O=AffirmTrust,C=US	2010-01-29	2030-12-31
43df5774b03e7fef5fe40d931a7bedf1bb2e6b42738c4e6d3841103d3aa7f339	CN=Entrust Root Certification Authority - G2,OU=See www.entrust.net/legal-terms+OU=(c) 2009 Entrust, Inc. - for authorized use only,O=Entrust, Inc.,C=US	2009-07-07	2030-12-07
6dc47172e01cbcb0bf62580d895fe2b8ac9ad4f873801e0c10b9c837d21eb177	CN=Entrust.net Certification Authority (2048),OU=www.entrust.net/CPS_2048 incorp. by ref. (limits liab.)+OU=(c) 1999 Entrust.net Limited,O=Entrust.net	1999-12-24	2029-07-24
70a73f7f376b60074248904534b11482d5bf0e698ecc498df52577ebf2e93b9a	CN=AffirmTrust Premium,O=AffirmTrust,C=US	2010-01-29	2040-12-31
73c176434f1bc6d5adf45b0e76e727287c8de57616c1e6e6141a2b2cbc7d8e4c	CN=Entrust Root Certification Authority,OU=www.entrust.net/CPS is incorporated by reference+OU=(c) 2006 Entrust, Inc.,O=Entrust, Inc.,C=US	2006-11-27	2026-11-27
bd71fdf6da97e4cf62d1647add2581b07d79adf8397eb4ecba9c5e8488821423	CN=AffirmTrust Premium ECC,O=AffirmTrust,C=US	2010-01-29	2040-12-31
db3517d1f6732a2d5ab97c533ec70779ee3270a62fb4ac4238372460e6f01e88	CN=Entrust Root Certification Authority - G4,OU=See www.entrust.net/legal-terms+OU=(c) 2015 Entrust, Inc. - for authorized use only,O=Entrust, Inc.,C=US	2015-05-27	2037-12-27
bfff8fd04433487d6a8aa60c1a29767a9fc2bbb05e420f713a13b992891d3893	CN=GDCA TrustAUTH R5 ROOT,O=GUANG DONG CERTIFICATE AUTHORITY CO.,LTD.,C=CN	2014-11-26	2040-12-31
179fbc148a3dd00fd24ea13458cc43bfa7f59c8182d783a513f6ebec100c8924	CN=GlobalSign,OU=GlobalSign ECC Root CA - R5,O=GlobalSign	2012-11-13	2038-01-19
2cabeafe37d06ca22aba7391c0033d25982952c453647349763a3ab5ad6ccf69	CN=GlobalSign,OU=GlobalSign Root CA - R6,O=GlobalSign	2014-12-10	2034-12-10
cbb522d7b7f127ad6a0113865bdf1cd4102e7d0759af635a7cf4720dc963c53b	CN=GlobalSign,OU=GlobalSign Root CA - R3,O=GlobalSign	2009-03-18	2029-03-18
ebd41040e4bb3ec742c9e381d31ef2a41a48b6685c96e7cef3c1df6cd4331c99	CN=GlobalSign Root CA,OU=Root CA,O=GlobalSign nv-sa,C=BE	1998-09-01	2028-01-28
1465fa205397b876faa6f0a9958e5590e40fcc7faa4fb7c2c8677521fb5fb658	OU=Starfield Class 2 Certification Authority,O=Starfield Technologies, Inc.,C=US	2004-06-29	2034-06-29
2ce1cb0bf9d2f9e102993fbe215152c3b2dd0cabde1c68e5319b839154dbb7f5	CN=Starfield Root Certificate Authority - G2,O=Starfield Technologies, Inc.,L=Scottsdale,ST=Arizona,C=US	2009-09-01	2037-12-31
45140b3247eb9cc8c5b4f0d7b53091f73292089e6e5a63e2749dd3aca9198eda	CN=Go Daddy Root Certificate Authority - G2,O=GoDaddy.com, Inc.,L=Scottsdale,ST=Arizona,C=US	2009-09-01	2037-12-31
c3846bf24b9e93ca64274c0ec67c1ecc5e024ffcacd2d74019350e81fe546ae4	OU=Go Daddy Class 2 Certification Authority,O=The Go Daddy Group, Inc.,C=US	2004-06-29	2034-06-29
34d8a73ee208d9bcdb0d956520934b4e40e69482596e8b6f73c8426b010a6f48	CN=GTS Root R3,O=Google Trust Services LLC,C=US	2016-06-22	2036-06-22
d947432abde7b7fa90fc2e6b59101b1280e0e1c7e4e40fa3c6887fff57a7f4cf	CN=GTS Root R1,O=Google Trust Services LLC,C=US	2016-06-22	2036-06-22
349dfa4058c5e263123b398ae795573c4e1313c83fe68f93556cd5e8031b3c7d	CN=GTS Root R4,O=Google Trust Services LLC,C=US	2016-06-22	2036-06-22
b085d70b964f191a73e4af0d54ae7a0e07aafdaf9b71dd0862138ab7325a24a2	CN=GlobalSign,OU=GlobalSign ECC Root CA - R4,O=GlobalSign	2012-11-13	2038-01-19
8d25cd97229dbf70356bda4eb3cc734031e24cf00fafcfd32dc76eb5841c7ea8	CN=GTS Root R2,O=Google Trust Services LLC,C=US	2016-06-22	2036-06-22
5a2fc03f0c83b090bbfa40604b0988446c7636183df9846e17101a447fb8efd6	CN=Hongkong Post Root CA 3,O=Hongkong Post,L=Hong Kong,ST=Hong Kong,C=HK	2017-06-03	2042-06-03
9a6ec012e1a7da9dbe34194d478ad7c0db1822fb071df12981496ed104384113	CN=ACCVRAIZ1,OU=PKIACCV,O=ACCV,C=ES	2011-05-05	2030-12-31
ebc5570c29018c4d67b1aa127baf12f703b4611ebc17b7dab5573894179b93fa	OU=AC RAIZ FNMT-RCM,O=FNMT-RCM,C=ES	2008-10-29	2030-01-01
46edc3689046d53a453fb3104ab80dcaec658b2660ea1629dd7e867990648716	CN=TUBITAK Kamu SM SSL Kok Sertifikasi - Surum 1,OU=Kamu Sertifikasyon Merkezi - Kamu SM,O=Turkiye Bilimsel ve Teknolojik Arastirma Kurumu - TUBITAK,L=Gebze - Kocaeli,C=TR	2013-11-25	2043-10-25
44b545aa8a25e65a73ca15dc27fc36d24c1cb9953a066539b11582dc487b4833	CN=Hellenic Academic and Research Institutions ECC RootCA 2015,O=Hellenic Academic and Research Institutions Cert. Authority,L=Athens,C=GR	2015-07-07	2040-06-30
a040929a02ce53b4acf4f2ffc6981ce4496f755e6d45fe0b2a692bcd52523f36	CN=Hellenic Academic and Research Institutions RootCA 2015,O=Hellenic Academic and Research Institutions Cert. Authority,L=Athens,C=GR	2015-07-07	2040-06-30
30d0895a9a448a262091635522d1f52010b5867acae12c78ef958fd4f4389f2f	CN=IdenTrust Public Sector Root CA 1,O=IdenTrust,C=US	2014-01-16	2034-01-16
5d56499be4d2e08bcfcad08a3e38723d50503bde706948e42f55603019e528ae	CN=IdenTrust Commercial Root CA 1,O=IdenTrust,C=US	2014-01-16	2034-01-16
96bcec06264976f37460779acf28c5a7cfe8a3c0aae11a8ffcee05c0bddf08c6	CN=ISRG Root X1,O=Internet Security Research Group,C=US	2015-06-04	2035-06-04
2530cc8e98321502bad96f9b1fba1b099e2d299e0f4548bb914f363bc0d4531f	CN=Izenpe.com,O=IZENPE S.A.,C=ES	2007-12-13	2037-12-13
a1339d33281a0b56e557d3d32b1ce7f9367eb094bd5fa72a7e5004c8ded7cafe	CN=SZAFIR ROOT CA2,O=Krajowa Izba Rozliczeniowa S.A.,C=PL	2015-10-19	2035-10-19
3c5f81fea5fab82c64bfa2eaecafcde8e077fc8620a7cae537163df36edbf378	CN=Microsec e-Szigno Root CA 2009,O=Microsec Ltd.,L=Budapest,C=HU,1.2.840.113549.1.9.1=#0c10696e666f40652d737a69676e6f2e6875	2009-06-16	2029-12-30
beb00b30839b9bc32c32e4447905950641f26421b15ed089198b518ae2ea1b99	CN=e-Szigno Root CA 2017,O=Microsec Ltd.,L=Budapest,C=HU,2.5.4.97=#130e56415448552d3233353834343937	2017-08-22	2042-08-22
358df39d764af9e1b766e9c972df352ee15cfac227af6ad1d70e8e4a6edcba02	CN=Microsoft ECC Root Certificate Authority 2017,O=Microsoft Corporation,C=US	2019-12-18	2042-07-18
c741f70f4b2a8d88bf2e71c14122ef53ef10eba0cfa5e64cfa20f418853073e0	CN=Microsoft RSA Root Certificate Authority 2017,O=Microsoft Corporation,C=US	2019-12-18	2042-07-18
6c61dac3a2def031506be036d2a6fe401994fbd13df9c8d466599274c446ec98	CN=NetLock Arany (Class Gold) Főtanúsítvány,OU=Tanúsítványkiadók (Certification Services),O=NetLock Kft.,L=Budapest,C=HU	2008-12-11	2028-12-06
6b9c08e86eb0f767cfad65cd98b62149e5494a67f5845e7bd1ed019f27b86bd6	CN=OISTE WISeKey Global Root GB CA,OU=OISTE Foundation Endorsed,O=WISeKey,C=CH	2014-12-01	2039-12-01
8560f91c3624daba9570b5fea0dbe36ff11a8323be9486854fb3f34a5571198d	CN=OISTE WISeKey Global Root GC CA,OU=OISTE Foundation Endorsed,O=WISeKey,C=CH	2017-05-09	2042-05-09
18f1fc7f205df8adddeb7fe007dd57e3af375a9c4d8d73546bf4f1fed1e18d35	CN=QuoVadis Root CA 3,O=QuoVadis Limited,C=BM	2006-11-24	2031-11-24
85a0dd7dd720adb7ff05f83d542b209dc7ff4528f7d677b18389fea5e5c49e86	CN=QuoVadis Root CA 2,O=QuoVadis Limited,C=BM	2006-11-24	2031-11-24
88ef81de202eb018452e43f864725cea5fbd1fc2d9d205730709c5d8b8690f46	CN=QuoVadis Root CA 3 G3,O=QuoVadis Limited,C=BM	2012-01-12	2042-01-12
8a866fd1b276b57e578e921c65828a2bed58e9f2f288054134b7f1f4bfc9cc74	CN=QuoVadis Root CA 1 G3,O=QuoVadis Limited,C=BM	2012-01-12	2042-01-12
8fe4fb0af93a4d0d67db0bebb23e37c71bf325dcbcdd240ea04daf58b47e1840	CN=QuoVadis Root CA 2 G3,O=QuoVadis Limited,C=BM	2012-01-12	2042-01-12
513b2cecb810d4cde5dd85391adfc6c2dd60d87bb736d2b521484aa47a0ebef6	OU=Security Communication RootCA2,O=SECOM Trust Systems CO.,LTD.,C=JP	2009-05-29	2029-05-29
e75e72ed9f560eec6eb4800073a43fc3ad19195a392282017895974a99026b6c	OU=Security Communication RootCA1,O=SECOM Trust.net,C=JP	2003-09-30	2023-09-30
1a0d20445de5ba1862d19ef880858cbce50102b36e8f0a040c3c69e74522fe6e	CN=COMODO Certification Authority,O=COMODO CA Limited,L=Salford,ST=Greater Manchester,C=GB	2011-01-01	2030-12-31
1793927a0614549789adce2f8f34f7f0b66d0f3ae3a3b84d21ec15dbba4fadc7	CN=COMODO ECC Certification Authority,O=COMODO CA Limited,L=Salford,ST=Greater Manchester,C=GB	2008-03-06	2038-01-18
4ff460d54b9c86dabfbcfc5712e0400d2bed3fbc4d4fbdaa86e06adcd2a9ad7a	CN=USERTrust ECC Certification Authority,O=The USERTRUST Network,L=Jersey City,ST=New Jersey,C=US	2010-02-01	2038-01-18
52f0e1c4e58ec629291b60317f074671b85d7ea80d5b07273463534b32b40234	CN=COMODO RSA Certification Authority,O=COMODO CA Limited,L=Salford,ST=Greater Manchester,C=GB	2010-01-19	2038-01-18
d7a7a0fb5d7e2731d771e9484ebcdef71d5f0c3e0a2948782bc83ee0ea699ef4	CN=AAA Certificate Services,O=Comodo CA Limited,L=Salford,ST=Greater Manchester,C=GB	2004-01-01	2028-12-31
e793c9b02fd8aa13e21c31228accb08119643b749c898964b1746d46c3d4cbd2	CN=USERTrust RSA Certification Authority,O=The USERTRUST Network,L=Jersey City,ST=New Jersey,C=US	2010-02-01	2038-01-18
4200f5043ac8590ebb527d209ed1503029fbcbd41ca1b506ec27f15ade7dac69	CN=Secure Global CA,O=SecureTrust Corporation,C=US	2006-11-07	2029-12-31
55903859c8c0c3ebb8759ece4e2557225ff5758bbd38ebd48276601e1bd58097	CN=Trustwave Global ECC P384 Certification Authority,O=Trustwave Holdings, Inc.,L=Chicago,ST=Illinois,C=US	2017-08-23	2042-08-23
945bbc825ea554f489d1fd51a73ddf2ea624ac7019a05205225c22a78ccfa8b4	CN=Trustwave Global ECC P256 Certification Authority,O=Trustwave Holdings, Inc.,L=Chicago,ST=Illinois,C=US	2017-08-23	2042-08-23
97552015f5ddfc3c8788c006944555408894450084f100867086bc1a2bb58dc8	CN=Trustwave Global Certification Authority,O=Trustwave Holdings, Inc.,L=Chicago,ST=Illinois,C=US	2017-08-23	2042-08-23
cecddc905099d8dadfc5b1d209b737cbe2c18cfb2c10c0ff0bcf0d3286fc1aa2	CN=XRamp Global Certification Authority,OU=www.xrampsecurity.com,O=XRamp Security Services Inc,C=US	2004-11-01	2035-01-01
f1c1b50ae5a20dd8030ec9f6bc24823dd367b5255759b4e71b61fce9f7375d73	CN=SecureTrust CA,O=SecureTrust Corporation,C=US	2006-11-07	2029-12-31
9bea11c976fe014764c1be56a6f914b5a560317abd9988393382e5161aa0493c	CN=UCA Global G2 Root,O=UniTrust,C=CN	2016-03-11	2040-12-31
d43af9b35473755c9684fc06d7d8cb70ee5c28e773fb294eb41ee71722924d24	CN=UCA Extended Validation Root,O=UniTrust,C=CN	2015-03-13	2038-12-31
22a2c1f7bded704cc1e701b5f408c310880fe956b5de2a4a44f99c873a25a7c8	CN=SSL.com EV Root Certification Authority ECC,O=SSL Corporation,L=Houston,ST=Texas,C=US	2016-02-12	2041-02-12
2e7bf16cc22485a7bbe2aa8696750761b0ae39be3b2fe9d0cc6d4ef73491425c	CN=SSL.com EV Root Certification Authority RSA R2,O=SSL Corporation,L=Houston,ST=Texas,C=US	2017-05-31	2042-05-30
3417bb06cc6007da1b961c920b8ab4ce3fad820e4aa30b9acbc4a74ebdcebc65	CN=SSL.com Root Certification Authority ECC,O=SSL Corporation,L=Houston,ST=Texas,C=US	2016-02-12	2041-02-12
85666a562ee0be5ce925c1d8890a6f76a87ec16d4d7d5f29ea7419cf20123b69	CN=SSL.com Root Certification Authority RSA,O=SSL Corporation,L=Houston,ST=Texas,C=US	2016-02-12	2041-02-12
62dd0be9b9f50a163ea0f8e75c053b1eca57ea55c8688f647c6881f2c8357b95	CN=SwissSign Gold CA - G2,O=SwissSign AG,C=CH	2006-10-25	2036-10-25
be6c4da2bbb9ba59b6f3939768374246c3c005993fa98f020d1dedbed48a81d5	CN=SwissSign Silver CA - G2,O=SwissSign AG,C=CH	2006-10-25	2036-10-25
59769007f7685d0fcd50872f9f95d5755a5b2b457d81f3692b610a98672f0e1b	CN=TWCA Global Root CA,OU=Root CA,O=TAIWAN-CA,C=TW	2012-06-27	2030-12-31
bfd88fe1101c41ae3e801bf8be56350ee9bad1a6b9bd515edc5c6d5b8711ac44	CN=TWCA Root Certification Authority,OU=Root CA,O=TAIWAN-CA,C=TW	2008-08-28	2030-12-31
dd6936fe21f8f077c123a1a521c12224f72255b73e03a7260693e8a24b0fa389	CN=TeliaSonera Root CA v1,O=TeliaSonera	2007-10-18	2032-10-18
6b328085625318aa50d173c98d8bda09d57e27413d114cf787a0f5d06c030cf6	CN=Certum EC-384 CA,OU=Certum Certification Authority,O=Asseco Data Systems S.A.,C=PL	2018-03-26	2043-03-26
fe7696573855773e37a95e7ad4d9cc96c30157c15d31765ba9b15704e1ae78fd	CN=Certum Trusted Root CA,OU=Certum Certification Authority,O=Asseco Data Systems S.A.,C=PL	2018-03-16	2043-03-16
e59aaa816009c22bff5b25bad37df306f049797c1f81d85ab089e657bd8f0044	CN=D-TRUST BR Root CA 1 2020,O=D-Trust GmbH,C=DE	2020-02-11	2035-02-11
08170d1aa36453901a2f959245e347db0c8d37abaabc56b81aa100dc958970db	CN=D-TRUST EV Root CA 1 2020,O=D-Trust GmbH,C=DE	2020-02-11	2035-02-11
cbb9c44d84b8043e1050ea31a69f514955d7bfd2e2c6b49301019ad61d9f5058	CN=GlobalSign Root E46,O=GlobalSign nv-sa,C=BE	2019-03-20	2046-03-20
4fa3126d8d3a11d1c4855a4f807cbad6cf919d3a5a88b03bea2c6372d93c40c9	CN=GlobalSign Root R46,O=GlobalSign nv-sa,C=BE	2019-03-20	2046-03-20
9a296a5182d1d451a2e37f439b74daafa267523329f90f9a0d2007c334e23c9a	CN=GLOBALTRUST 2020,O=e-commerce monitoring GmbH,C=AT	2020-02-10	2040-06-10
3f99cc474acfce4dfed58794665e478d1547739f2e780f1bb4ca9b133097d401	CN=HARICA TLS ECC Root CA 2021,O=Hellenic Academic and Research Institutions CA,C=GR	2021-02-19	2045-02-13
d95d0e8eda79525bf9beb11b14d2100d3294985f0c62d9fabd9cd999eccb7b1d	CN=HARICA TLS RSA Root CA 2021,O=Hellenic Academic and Research Institutions CA,C=GR	2021-02-19	2045-02-13
f015ce3cc239bfef064be9f1d2c417e1a0264a0a94be1f0c8d121864eb6949cc	CN=HiPKI Root CA - G1,O=Chunghwa Telecom Co., Ltd.,C=TW	2019-02-22	2037-12-31
69729b8e15a86efc177a57afb7171dfc64add28c2fca8cf1507e34453ccb1470	CN=ISRG Root X2,O=Internet Security Research Group,C=US	2020-09-04	2040-09-17
88f438dcf8ffd1fa8f429115ffe5f82ae1e06e0c70c375faad717b34a49e7265	CN=NAVER Global Root Certification Authority,O=NAVER BUSINESS PLATFORM Corp.,C=KR	2017-08-18	2037-08-18
242b69742fcb1e5b2abf98898b94572187544e5b4d9911786573621f6a74b82c	CN=Telia Root CA v2,O=Telia Finland Oyj,C=FI	2018-11-29	2043-11-29
018e13f0772532cf809bd1b17281867283fc48c6e13be9c69812854a490c1b05	CN=DigiCert TLS ECC P384 Root G5,O=DigiCert, Inc.,C=US	2021-01-15	2046-01-14
371a00dc0533b3721a7eeb40e8419e70799d2b0a0f2c1d80693165f7cec4ad75	CN=DigiCert TLS RSA4096 Root G5,O=DigiCert, Inc.,C=US	2021-01-15	2046-01-14
b4585f22e4ac756a4e8612a1361c5d9d031a93fd84febb778fa3068b0fc42dc2	CN=Certainly Root E1,O=Certainly,C=US	2021-04-01	2046-04-01
77b82cd8644c4305f7acc5cb156b45675004033d51c60c6202a8e0c33467d3a0	CN=Certainly Root R1,O=Certainly,C=US	2021-04-01	2046-04-01
554153b13d2cf9ddb753bfbe1a4e0ae08d0aa4187058fe60a2b862b2e4b87bcb	CN=AC RAIZ FNMT-RCM SERVIDORES SEGUROS,OU=Ceres,O=FNMT-RCM,C=ES,2.5.4.97=#130f56415445532d51323832363030344a	2018-12-20	2043-12-20
fb8fec759169b9106b1e511644c618c51304373f6c0643088d8beffd1b997599	SERIALNUMBER=G63287510,CN=ANF Secure Server Root CA,OU=ANF CA Raiz,O=ANF Autoridad de Certificacion,C=ES	2019-09-04	2039-08-30
e74fbda55bd564c473a36b441aa799c8a68e077440e8288b9fa1e50e4bbaca11	CN=Security Communication ECC RootCA1,O=SECOM Trust Systems CO.,LTD.,C=JP	2016-06-16	2038-01-18
2e44102ab58cb85419451c8e19d9acf3662cafbc614b6a53960a30f7d0e2eb41	CN=TunTrust Root CA,O=Agence Nationale de Certification Electronique,C=TN	2019-04-26	2044-04-26
30fbba2c32238e2a98547af97931e550428b9b3f1c8eeb6633dcfa86c5b27dd3	CN=vTrus ECC Root CA,O=iTrusChina Co.,Ltd.,C=CN	2018-07-31	2043-07-31
8a71de6559336f426c26e53880d00d88a18da4c6a91f0dcb6194e206c5c96387	CN=vTrus Root CA,O=iTrusChina Co.,Ltd.,C=CN	2018-07-31	2043-07-31
b2fae53e14ccd7ab9212064701ae279c1d8988facb775fa8a008914e663988a8	CN=Atos TrustedRoot Root CA ECC TLS 2021,O=Atos,C=DE	2021-04-22	2041-04-17
81a9088ea59fb364c548a6f85559099b6f0405efbf18e5324ec9f457ba00112f	CN=Atos TrustedRoot Root CA RSA TLS 2021,O=Atos,C=DE	2021-04-22	2041-04-17
c90f26f0fb1b4018b22227519b5ca2b53e2ca5b3be5cf18efe1bef47380c5383	CN=Sectigo Public Server Authentication Root E46,O=Sectigo Limited,C=GB	2021-03-22	2046-03-21
7bb647a62aeeac88bf257aa522d01ffea395e0ab45c73f93f65654ec38f25a06	CN=Sectigo Public Server Authentication Root R46,O=Sectigo Limited,C=GB	2021-03-22	2046-03-21
c32ffd9f46f936d16c3673990959434b9ad60aafbb9e7cf33654f144cc1ba143	CN=SSL.com TLS ECC Root CA 2022,O=SSL Corporation,C=US	2022-08-25	2046-08-19
8faf7d2e2cb4709bb8e0b33666bf75a5dd45b5de480f8ea8d4bfe6bebc17f2ed	CN=SSL.com TLS RSA Root CA 2022,O=SSL Corporation,C=US	2022-08-25	2046-08-19
Powered by Gitiles| Privacy| Terms
int setBit(int n)
    {
        // Write Youwhile(r Code here
        int count=0;
        while((n%2)!=0)
    {
        n=n>>1;
        count++;
    }
    n=n+1;
    for(int i=0;i<count;++i)
    {
        n=n*2+1;
    }
        return n;
    }
int setBit(int n)
    {
        // Write Youwhile(r Code here
        int count=0;
        while((n%2)!=0)
    {
        n=n>>1;
        count++;
    }
    n=n+1;
    for(int i=0;i<count;++i)
    {
        n=n*2+1;
    }
        return n;
    }
// Holds the state of the button
int buttonState = 0;

void setup() {
  // Open a serial connection to display values
  Serial.begin(9600);

  // Set the LED pins as outputs
  pinMode(3, OUTPUT);
  pinMode(4, OUTPUT);
  pinMode(5, OUTPUT);

  // Setting the button as input
  pinMode(2, INPUT);  
}

void loop() {
  // Read value of button
  buttonState = digitalRead(2);

  // If button is not pressed, then the green LED is turned on while the other red LEDs are not
  if (buttonState == LOW) {
    Serial.println("Engaging Hyperdrive");
    digitalWrite(3, HIGH);
    digitalWrite(4, LOW);
    digitalWrite(5, LOW);
  }

  // Else if button is pressed, then both of the red LEDs are turned on while the green LED is turned off
  else {
    Serial.println("Firing Lasers");
    digitalWrite(3, LOW);
    digitalWrite(4, LOW);
    digitalWrite(5, HIGH);

    delay(250);
    digitalWrite(4, HIGH);
    digitalWrite(5, LOW);
    delay(250);

  }

}
int removeDuplicates(vector<int>& nums) {
        int size = nums.size();

        int right =1,left = 0;
        while (right < size)
        {
            if ((nums[left] != nums[right]) && (right - left == 1))
            {
            left++;
            right++;
            }
            else if (nums[left] == nums[right])
            {
            right++;
            }
            else
            {
            nums[++left] = nums[right++];
            }
        }


    return left + 1;
        
    }
let
    Source = Csv.Document(File.Contents("C:\Users\Marchand.Olivier\Desktop\PLT_BYTEL_PROJETS_DEMANDE_SDL_20240523_062724.csv"),[Delimiter="¤", Encoding=1252]),
    #"En-têtes promus" = Table.PromoteHeaders(Source, [PromoteAllScalars=true]),
    #"Type modifié" = Table.TransformColumnTypes(#"En-têtes promus",{{"NUM_PROJET", type text}, {"NUM_TACHE", type text}, {"NUM_DO", type text}, {"NUM_DEMANDE_SDL", type text}, {"TYPE_LIEN", type text}, {"CSG", type text}})
in
    #"Type modifié"
let
    Source = Folder.Files("\\demasriis14\bytelimportscript\output\success"),
    #"Lignes filtrées" = Table.SelectRows(Source, each Text.StartsWith([Name], "PLT_BYTEL_NODE")),
    #"Lignes filtrées1" = Table.SelectRows(#"Lignes filtrées", let latest = List.Max(#"Lignes filtrées"[Date created]) in each [Date created] = latest),
    #"Fichiers masqués filtrés1" = Table.SelectRows(#"Lignes filtrées1", each [Attributes]?[Hidden]? <> true),
    #"Appeler une fonction personnalisée1" = Table.AddColumn(#"Fichiers masqués filtrés1", "Transformer le fichier", each #"Transformer le fichier"([Content])),
    #"Colonnes renommées1" = Table.RenameColumns(#"Appeler une fonction personnalisée1", {"Name", "Source.Name"}),
    #"Autres colonnes supprimées1" = Table.SelectColumns(#"Colonnes renommées1", {"Source.Name", "Transformer le fichier"}),
    #"Colonne de tables développée1" = Table.ExpandTableColumn(#"Autres colonnes supprimées1", "Transformer le fichier", Table.ColumnNames(#"Transformer le fichier"(#"Exemple de fichier")))
in
    #"Colonne de tables développée1"
%%[
set @language = System_Language__c
Set @FRvalue= "fr_" 
/* Does it match; ; if no match, output of IndexOf(1,2) will be "0" */ 


if @language == "French" OR IndexOf(@language,@FRvalue) > 0 then 
Set @subjectline = "Vous êtes sur la liste pour recevoir les dernières nouvelles concernant Cat® Vantage" 
else 
Set @subjectline = "You're on the list for the latest news for Cat® Vantage Rewards!"
endif

]%%
The tech- industry is evolving and software development is constantly astonishing its path due to the emergence of new technologies, various factors, and frequent upgrades in societal demands. Let’s see a few trendsetting software development trends that will enhance your business technologically.

Artificial Intelligence (AI) and Machine learning
Progressive Web Apps (PWAs)
Internet of Things (IoT)
Edge computing
5G Technology
Blockchain 
Cyber security
Cloud Computing
Quantum Computing
 Low code/No code Development

With these booming trendsetters, you can formulate digital acceleration in your business software, to drive remarkable results. Get started to empower your business, by incorporating these cutting-edge technological stacks.

If you are confused about how to opt for the right technology for your business software, then get started with the right software consulting company for conventional direction or you may hire suitable software consultants in the industry. check out >> https://maticz.com/software-consulting-services

bundle exec rails db < my_db.sql
optimizer = tf.keras.optimizers.Adam()

# Define your loss function (e.g., Mean Squared Error)
mse_loss_fn = tf.keras.losses.MeanSquaredError()

# Compile the model
cvae_model.compile(optimizer=optimizer, loss=mse_loss_fn)

# Train the model
cvae_model.fit([data, clusters], data, epochs=10, batch_size=32)
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

sk-proj-FrAcuJSTxPSFr9DNpCc6T3BlbkFJxsg70pKZaJdlDMscfBhL


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

sk-proj-cwkoOcKTTpuwjPgVbU9AT3BlbkFJ4o2iDTsWWLckZhIkX1Zt

https://go.microsoft.com/fwlink/?linkid=2213926

curl https://YOUR_RESOURCE_NAME.openai.azure.com/openai/deployments/YOUR_DEPLOYMENT_NAME/extensions/chat/completions?api-version=2023-12-01-preview \
  -H "Content-Type: application/json" \
  -H "api-key: YOUR_API_KEY" \
  -d '{"enhancements":{"ocr":{"enabled":true},"grounding":{"enabled":true}},"dataSources":[{"type":"AzureComputerVision","parameters":{"endpoint":" <Computer Vision Resource Endpoint> ","key":"<Computer Vision Resource Key>"}}],"messages":[{"role":"system","content":"You are a helpful assistant."},{"role":"user","content":[{"type":"text","text":"Describe this picture:"},{"type":"image_url","image_url":"https://learn.microsoft.com/azure/ai-services/computer-vision/media/quickstarts/presentation.png"}]}]}'
root@kali:~# above -h
                                        
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@   @   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@   @@@   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@  @@@@@@@@@  @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@                                         @@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@@@   @@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@  @@@@@@@@@@@@@@@@@@@@@@@@@@@@@  @@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@                                     @@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
                                        
                       Invisible network protocol sniffer
                 Designed for pentesters and security engineers
              Version 2.4, Codename: My Own Summer (Shove It)
               Author: Magama Bazarov, <caster@exploit.org>
usage: above [-h] [--interface INTERFACE] [--timer TIMER]
             [--output-pcap OUTPUT_FILE] [--input-pcap INPUT_FILE]

options:
  -h, --help            show this help message and exit
  --interface INTERFACE
                        Specify the interface
  --timer TIMER         Specify the timer value (seconds)
  --output-pcap OUTPUT_FILE
                        Specify the output pcap file to record traffic (hot
                        mode)
  --input-pcap INPUT_FILE
                        Specify the input pcap file to analyze traffic (cold
                        mode)
root@kali:~# 7zr -h

7-Zip (r) 23.01 (x64) : Igor Pavlov : Public domain : 2023-06-20
 64-bit locale=C.UTF-8 Threads:8 OPEN_MAX:1024

Usage: 7zr <command> [<switches>...] <archive_name> [<file_names>...] [@listfile]

<Commands>
  a : Add files to archive
  b : Benchmark
  d : Delete files from archive
  e : Extract files from archive (without using directory names)
  h : Calculate hash values for files
  i : Show information about supported formats
  l : List contents of archive
  rn : Rename files in archive
  t : Test integrity of archive
  u : Update files to archive
  x : eXtract files with full paths

<Switches>
  -- : Stop switches and @listfile parsing
  -ai[r[-|0]]{@listfile|!wildcard} : Include archives
  -ax[r[-|0]]{@listfile|!wildcard} : eXclude archives
  -ao{a|s|t|u} : set Overwrite mode
  -an : disable archive_name field
  -bb[0-3] : set output log level
  -bd : disable progress indicator
  -bs{o|e|p}{0|1|2} : set output stream for output/error/progress line
  -bt : show execution time statistics
  -i[r[-|0]]{@listfile|!wildcard} : Include filenames
  -m{Parameters} : set compression Method
    -mmt[N] : set number of CPU threads
    -mx[N] : set compression level: -mx1 (fastest) ... -mx9 (ultra)
  -o{Directory} : set Output directory
  -p{Password} : set Password
  -r[-|0] : Recurse subdirectories for name search
  -sa{a|e|s} : set Archive name mode
  -scc{UTF-8|WIN|DOS} : set charset for console input/output
  -scs{UTF-8|UTF-16LE|UTF-16BE|WIN|DOS|{id}} : set charset for list files
  -scrc[CRC32|CRC64|SHA1|SHA256|*] : set hash function for x, e, h commands
  -sdel : delete files after compression
  -seml[.] : send archive by email
  -sfx[{name}] : Create SFX archive
  -si[{name}] : read data from stdin
  -slp : set Large Pages mode
  -slt : show technical information for l (List) command
  -snh : store hard links as links
  -snl : store symbolic links as links
  -sni : store NT security information
  -sns[-] : store NTFS alternate streams
  -so : write data to stdout
  -spd : disable wildcard matching for file names
  -spe : eliminate duplication of root folder for extract command
  -spf[2] : use fully qualified file paths
  -ssc[-] : set sensitive case mode
  -sse : stop archive creating, if it can't open some input file
  -ssp : do not change Last Access Time of source files while archiving
  -ssw : compress shared files
  -stl : set archive timestamp from the most recently modified file
  -stm{HexMask} : set CPU thread affinity mask (hexadecimal number)
  -stx{Type} : exclude archive type
  -t{Type} : Set type of archive
  -u[-][p#][q#][r#][x#][y#][z#][!newArchiveName] : Update options
  -v{Size}[b|k|m|g] : Create volumes
  -w[{path}] : assign Work directory. Empty path means a temporary directory
  -x[r[-|0]]{@listfile|!wildcard} : eXclude filenames
  -y : assume Yes on all queries
http://rpc.pingomatic.com
http://rpc.twingly.com
http://www.blogdigger.com/RPC2
http://ping.blo.gs/
http://ping.feedburner.com
http://rpc.weblogs.com/RPC2
http://www.pingmyblog.com
root@kali:~# wifite -h
   .               .    
 .´  ·  .     .  ·  `.  wifite2 2.7.0
 :  :  :  (¯)  :  :  :  a wireless auditor by derv82
 `.  ·  ` /¯\ ´  ·  .´  maintained by kimocoder
   `     /¯¯¯\     ´    https://github.com/kimocoder/wifite2

options:
  -h, --help                                 show this help message and exit

SETTINGS:
  -v, --verbose                              Shows more options (-h -v). Prints commands and outputs. (default:
                                             quiet)
  -i [interface]                             Wireless interface to use, e.g. wlan0mon (default: ask)
  -c [channel]                               Wireless channel to scan e.g. 1,3-6 (default: all 2Ghz channels)
  -inf, --infinite                           Enable infinite attack mode. Modify scanning time with -p (default:
                                             off)
  -mac, --random-mac                         Randomize wireless card MAC address (default: off)
  -p [scan_time]                             Pillage: Attack all targets after scan_time (seconds)
  --kill                                     Kill processes that conflict with Airmon/Airodump (default: off)
  -pow [min_power], --power [min_power]      Attacks any targets with at least min_power signal strength
  --skip-crack                               Skip cracking captured handshakes/pmkid (default: off)
  -first [attack_max], --first [attack_max]  Attacks the first attack_max targets
  -ic, --ignore-cracked                      Hides previously-cracked targets. (default: off)
  --clients-only                             Only show targets that have associated clients (default: off)
  --nodeauths                                Passive mode: Never deauthenticates clients (default: deauth targets)
  --daemon                                   Puts device back in managed mode after quitting (default: off)

WEP:
  --wep                                      Show only WEP-encrypted networks
  --require-fakeauth                         Fails attacks if fake-auth fails (default: off)
  --keep-ivs                                 Retain .IVS files and reuse when cracking (default: off)

WPA:
  --wpa                                      Show only WPA-encrypted networks (includes WPS)
  --new-hs                                   Captures new handshakes, ignores existing handshakes in hs (default:
                                             off)
  --dict [file]                              File containing passwords for cracking (default: /usr/share/dict/wordlist-
                                             probable.txt)

WPS:
  --wps                                      Show only WPS-enabled networks
  --wps-only                                 Only use WPS PIN & Pixie-Dust attacks (default:
                                             off)
  --bully                                    Use bully program for WPS PIN & Pixie-Dust attacks (default:
                                             reaver)
  --reaver                                   Use reaver program for WPS PIN & Pixie-Dust attacks (default:
                                             reaver)
  --ignore-locks                             Do not stop WPS PIN attack if AP becomes locked (default:
                                             stop)

PMKID:
  --pmkid                                    Only use PMKID capture, avoids other WPS & WPA attacks (default:
                                             off)
  --no-pmkid                                 Don't use PMKID capture (default: off)
  --pmkid-timeout [sec]                      Time to wait for PMKID capture (default: 300 seconds)

COMMANDS:
  --cracked                                  Print previously-cracked access points
  --check [file]                             Check a .cap file (or all hs/*.cap files) for WPA handshakes
  --crack                                    Show commands to crack a captured handshake
		blueprint_details = invokeurl
		[
			url: "https://www.zohoapis.com/crm/v5/Deals/"+DealID+"/actions/blueprint"
			type: GET
			connection:"zoho_crm"
		];
	// 	info blueprint_details;
		blueprint = Map();
		blueprint.put("transition_id","6051205000002261178");
	// 	blueprint.put("data",dataMap);
		blueprintList = List();
		blueprintList.add(blueprint);
		param = Map();
		param.put("blueprint",blueprintList);
		update_blueprint_stage = invokeurl
		[
		url :"https://www.zohoapis.com/crm/v5/Deals/" + DealID + "/actions/blueprint"
		type :PUT
		parameters:param.toString()
		connection:"zoho_crm"
		];
		info update_blueprint_stage;
{
  // You probably don't need to set anything in the configuration,
  // we infer a lot of information from the repo. One value that's worth
  // setting is your default sandbox ids to fork for a PR. It's easier to test
  // on a sandbox that includes some test cases already.
  // This is also optional, we default to 'vanilla' if it isn't set.
  "sandboxes": ["new", "vanilla"]
}
{
  // You probably don't need to set anything in the configuration,
  // we infer a lot of information from the repo. One value that's worth
  // setting is your default sandbox ids to fork for a PR. It's easier to test
  // on a sandbox that includes some test cases already.
  // This is also optional, we default to 'vanilla' if it isn't set.
  "sandboxes": ["new", "vanilla"]
}
{
  // You probably don't need to set anything in the configuration,
  // we infer a lot of information from the repo. One value that's worth
  // setting is your default sandbox ids to fork for a PR. It's easier to test
  // on a sandbox that includes some test cases already.
  // This is also optional, we default to 'vanilla' if it isn't set.
  "sandboxes": ["new", "vanilla"]
}
{
  // You probably don't need to set anything in the configuration,
  // we infer a lot of information from the repo. One value that's worth
  // setting is your default sandbox ids to fork for a PR. It's easier to test
  // on a sandbox that includes some test cases already.
  // This is also optional, we default to 'vanilla' if it isn't set.
  "sandboxes": ["new", "vanilla"]
}
function onOpen() {
  var ui = SpreadsheetApp.getUi();
  ui.createMenu('Custom Menu')
      .addItem('Update Master Summary', 'updateMasterSummaryBasedOnConfiguration')
      .addItem('Update Configuration', 'updateConfiguration')
      .addItem('Update Consolidated Master', 'updateConsolidatedMaster')
       .addItem('Update Consolidated Rejected', 'updateConsolidatedRejected')
      .addToUi();
}

function updateMasterSummaryBasedOnConfiguration() {
  var statusNames = ["RFQ SENT", "PART NUMBER SET UP", "SOURCED", "DEVELOPING", "AWAITING SAMPLE", "SAMPLE RECEIVED", "PIES COLLECTION", "PIES APPROVED", "PIES REJECTED", "PM APPROVED", "PRICING", "COMPLETE", "TERMINATED"];

  var spreadsheet = SpreadsheetApp.getActiveSpreadsheet();
  var masterSheet = spreadsheet.getSheetByName("Master Summary");
  var configSheet = spreadsheet.getSheetByName("Configuration");

  // Clear existing content in Master Summary sheet excluding the first column
  var rangeToClear = masterSheet.getRange("B:ZZ");
  rangeToClear.clear();

  // Get tab names and their statuses from the Configuration sheet
  var rangeData = configSheet.getRange("A:B").getValues();
  var tabNames = [];
  var tabStatuses = [];

  // Populate tabNames and tabStatuses arrays
  for (var i = 0; i < rangeData.length; i++) {
    var tabName = rangeData[i][0];
    var status = rangeData[i][1];
    if (tabName && status) { // Ensure both tab name and status exist
      tabNames.push(tabName);
      tabStatuses.push(status.toLowerCase()); // Convert status to lowercase for consistency
    }
  }

  // Set the headers for active tabs and count status for each tab
  var activeTabs = tabNames.filter(function(_, index) {
    return tabStatuses[index] === "active";
  });

  // Set the headers for active tabs in Master Summary
  var headerRowData = ['Status', 'Total Parts Count'].concat(activeTabs);
  masterSheet.getRange(1, 1, 1, headerRowData.length).setValues([headerRowData]);

  // Create a 2D array to hold all the data to be written to the Master Summary sheet
  var outputData = statusNames.map(function(statusName) {
    return [statusName, 0].concat(new Array(activeTabs.length).fill(0));
  });

  // Add a row for the total counts
  var totalCountsRow = ['TotTotal Parts Count', 0].concat(new Array(activeTabs.length).fill(0));
  outputData.push(totalCountsRow);

  // Iterate over active tabs and count the statuses
  activeTabs.forEach(function(tabName, tabIndex) {
    var sheet = spreadsheet.getSheetByName(tabName);
    if (sheet) {
      var values = sheet.getRange("A:A").getValues().flat();
      var statusCounts = statusNames.reduce(function(counts, status) {
        counts[status] = 0;
        return counts;
      }, {});

      // Count the statuses
      values.forEach(function(value) {
        var upperValue = value.toString().toUpperCase();
        if (statusCounts.hasOwnProperty(upperValue)) {
          statusCounts[upperValue]++;
        }
      });

      // Fill the outputData array with counts
      statusNames.forEach(function(statusName, statusIndex) {
        var count = statusCounts[statusName] || 0;
        outputData[statusIndex][tabIndex + 2] = count; // Insert count into corresponding column
        outputData[statusIndex][1] += count; // Add count to the total column
        totalCountsRow[tabIndex + 2] += count; // Add count to the total row
      });
      totalCountsRow[1] += totalCountsRow[tabIndex + 2]; // Add total of current tab to the grand total
    }
  });

  // Write the collected data to the sheet in one operation
  masterSheet.getRange(2, 1, outputData.length, outputData[0].length).setValues(outputData);
}

function updateConfiguration() {
  var spreadsheet = SpreadsheetApp.getActiveSpreadsheet();
  var configSheet = spreadsheet.getSheetByName("Configuration");

  // Fetch existing sheet names from Configuration sheet
  var existingSheetNames = configSheet.getRange("A2:A").getValues().flat().filter(function(name) {
    return name; // Filter out empty values
  });

  // Fetch all sheet names excluding "Configuration" and "Master Summary"
  var allSheetNames = spreadsheet.getSheets().map(function(sheet) {
    return sheet.getName();
  }).filter(function(name) {
    return name !== "Configuration" && name !== "Master Summary";
  });

  // Filter out existing sheet names from all sheet names
  var newSheetNames = allSheetNames.filter(function(name) {
    return !existingSheetNames.includes(name);
  });

  // Append new sheet names to the Configuration sheet
  if (newSheetNames.length > 0) {
    var startRow = existingSheetNames.length + 2;
    configSheet.getRange(startRow, 1, newSheetNames.length, 1).setValues(newSheetNames.map(function(name) {
      return [name];
    }));

    // Calculate status for new sheet names
    var statusNames = ["RFQ SENT", "PART NUMBER SET UP", "SOURCED", "DEVELOPING", "AWAITING SAMPLE", "SAMPLE RECEIVED", "PIES COLLECTION", "PIES APPROVED", "PIES REJECTED", "PM APPROVED", "PRICING", "COMPLETE", "TERMINATED"];

    for (var k = 0; k < newSheetNames.length; k++) {
      var tabName = newSheetNames[k];
      var isActive = false;

      // Check each status for the current sheet
      for (var i = 0; i < statusNames.length; i++) {
        var status = statusNames[i];
        var count = getCountForStatusInSheet(status, tabName);
        if (count > 0) {
          isActive = true;
          break;
        }
      }

      // Set the status for the current sheet in the Configuration sheet
      var statusCell = configSheet.getRange(startRow + k, 2);
      statusCell.setValue(isActive ? "Active" : "Inactive");
      var statusValidationRule = SpreadsheetApp.newDataValidation()
          .requireValueInList(["Active", "Inactive"], true)
          .build();
      statusCell.setDataValidation(statusValidationRule);
      statusCell.setFontColor(isActive ? "#00FF00" : "#FF0000");
    }
  }
}

function getCountForStatusInSheet(status, sheetName) {
  var sheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName(sheetName);
  
  // Return 0 if sheet doesn't exist
  if (!sheet) {
    return 0;
  }

  var statusColumn = sheet.getRange("A:A").getValues().flat(); // Assuming statuses are in column A

  // Count occurrences of status
  var count = statusColumn.filter(function(value) {
    return value === status;
  }).length;

  return count;
}

 
function updateConsolidatedMaster() {
  var statusNames = ["RFQ SENT", "PART NUMBER SET UP", "SOURCED", "DEVELOPING", "AWAITING SAMPLE", "SAMPLE RECEIVED", "PIES COLLECTION", "PIES APPROVED", "PIES REJECTED", "PM APPROVED", "PRICING", "COMPLETE"];
  var columnsToCopy = ["Status", "Start Date", "Part Type", "HOL P/N", "OE#", "ALT OE", "MAM Status (change to Dev)", "FP Status (Change to Electronically Announced)", "PartCat Status (Changed to Electronically Announced)", "Interchange", "Interchange Completion", "Parts List/RFQ Submitted to Warren", "Parts List/RFQ Returned to Holstein", "Production Sourced Part is requested from Warren", "ETA of Sample", "Date Prod Sample Delivered to Holstein", "Factory Code"];

  var spreadsheet = SpreadsheetApp.getActiveSpreadsheet();

  try {
    var masterSheet = spreadsheet.getSheetByName("Consolidated Master");
    var configSheet = spreadsheet.getSheetByName("Configuration");

    // Clear existing content in Consolidated Master sheet
    masterSheet.clear();

    // Get active tab names and their statuses from the Configuration sheet
    var rangeData = configSheet.getRange("A:B").getValues();
    var activeTabs = rangeData.filter(function(row) {
      return row[1] && row[1].toLowerCase() === "active";
    }).map(function(row) {
      return row[0];
    });

    // Initialize variables
    var allData = [];
    var rowIndex = 2;

    // Insert headers
    allData.push(columnsToCopy.concat("MOQ")); // Add MOQ to the header row
    masterSheet.getRange(1, 1, 1, allData[0].length).setValues([allData[0]]);

    // Iterate through active tabs
    activeTabs.forEach(function(tabName) {
      var sheet = spreadsheet.getSheetByName(tabName);
      if (sheet) {
        var sheetData = sheet.getDataRange().getValues();

        // Get column names
        var columnNames = sheetData[1];

        // Iterate through rows (excluding header rows)
        sheetData.slice(2).forEach(function(row) {
          var status = row[0];

          // Check if status is in the list and copy relevant data
          if (statusNames.includes(status)) {
            var rowData = [status];
            columnsToCopy.forEach(function(col) {
              var colIndex = columnNames.indexOf(col);
              if (colIndex !== -1) {
                rowData.push(row[colIndex]);
              }
            });

            // Find MOQ column index and convert date to "1" if found
            var moqIndex = columnNames.indexOf("MOQ");
            if (moqIndex !== -1) {
              var moqValue = row[moqIndex];
              if (typeof moqValue === 'object' && moqValue instanceof Date) {
                rowData.push("1");
              } else {
                rowData.push(moqValue);
              }
            } else {
              rowData.push(""); // Add empty string if MOQ column not found
            }
            allData.push(rowData);
          }
        });
      }
    });

    // Insert all data at once
    if (allData.length > 1) { // Check if there's data to insert
      masterSheet.getRange(rowIndex, 1, allData.length - 1, allData[0].length).setValues(allData.slice(1));
    }
  } catch (error) {
    // Handle errors gracefully (e.g., log error or display message to user)
    console.error("Error occurred:", error);
  }
}


function updateConsolidatedRejected() {
  var statusNames = ["PIES REJECTED"];
  var columnsToCopy = ["STATUS", "Part Type", "HOL P/N", "OE#", "QC Inspection/PIES Collection", "HOL Feedback Sent", "New Sample Requested", "New Sample Received"];
 
  var spreadsheet = SpreadsheetApp.getActiveSpreadsheet();
  var masterSheet = spreadsheet.getSheetByName("Consolidated Rejected");
  var configSheet = spreadsheet.getSheetByName("Configuration");
 
  // Clear existing content in Consolidated Rejected sheet
  masterSheet.clear();
 
  // Get tab names and their statuses from the Configuration sheet
  var rangeData = configSheet.getRange("A:B").getValues();
  var activeTabs = rangeData.filter(function(row) {
    return row[1] && row[1].toLowerCase() === "active";
  }).map(function(row) {
    return row[0];
  });
 
  // Initialize a variable to keep track of the row to insert data into
  var rowIndex = 2;
 
  // Insert headers for the Consolidated Rejected sheet
  var headers = columnsToCopy;
  masterSheet.getRange(1, 1, 1, headers.length).setValues([headers]);
 
  // Iterate through each active tab
  activeTabs.forEach(function(tabName) {
    var sheet = spreadsheet.getSheetByName(tabName);
    if (sheet) {
      var sheetData = sheet.getDataRange().getValues();
 
      // Get the column names from the second row
      var columnNames = sheetData[1];
 
      // Iterate through each row in the sheet
      sheetData.forEach(function(row, rowIdx) {
        if (rowIdx === 0 || rowIdx === 1) return; // Skip the header rows
 
        var status = row[0]; // Assuming status is in the first column (A)
 
        // If the status is "TERMINATED" or "PIES REJECTED", add it to the Consolidated Rejected sheet
        if (statusNames.includes(status)) {
          var rowData = [];
 
          // Insert the data into the Consolidated Rejected sheet
          columnsToCopy.forEach(function(col) {
            var colIndexInSheet = columnNames.indexOf(col);
            if (colIndexInSheet !== -1) {
              rowData.push(row[colIndexInSheet]);
            } else if (col === "STATUS") {
              rowData.push(status); // Add status directly for the STATUS column
            } else {
              rowData.push(''); // Fill in with an empty string if the column is not found
            }
          });
 
          masterSheet.getRange(rowIndex, 1, 1, rowData.length).setValues([rowData]);
          rowIndex++;
        }
      });
    }
  });
}


from fastapi import FastAPI


db = [
 {'api_key': '437af89f-38ba-44f1-9eda-924f370193d4',
  'tokens': 3,
  'user_id': '6ddf9779-4be7-449c-a70d-51e81c19dd0b'},
 {'api_key': '48762b59-e968-459e-b28d-50e7a1ad37a4', 
  'tokens': 3,
  'user_id': 'daf36850-68ab-40fc-86af-e6093b6797dd'},
 {'api_key': 'dabbd875-acbd-4b98-a47f-a526075d41b4', 
  'tokens': 3,
  'user_id': '5750957f-a246-4290-a35e-2dec83bcfcea'},
 {'api_key': '604d5fe2-f7ce-4560-8137-eeae32091738',
  'tokens': 3,
  'user_id': '2d4ac462-b118-48d7-897e-163c2e8327aa'},
 {'api_key': '8540cbef-de3e-4cbd-83bc-f66297a7f407',
  'tokens': 3,
  'user_id': 'bb435e7e-b5da-4a8c-b860-e43a8e765f67'}
]



app = FastAPI()

def update_tokens_for_user(user_id, api_key):
    for user in db:
        if user['user_id'] == user_id and user['api_key'] == api_key:
            tokens = user['tokens']
            if tokens > 0:
                tokens = tokens - 1
                user['tokens'] = tokens

                return {'tokens': tokens}
            
            else:
                return {'tokens': tokens, 'msg': 'you need to get more tokens'}


@app.get('/test')
def test(user_id : str, api_key: str):
    result = update_tokens_for_user(user_id, api_key)
    if result:
        return result
    else:
        return {'msg': 'api key or user id is not found'}
import pprint

data = {'email': 'test@test.com', 'password': '123'}

print(data, type(data))

# convert dict to str
result = pprint.pformat(data)

print(result, type(result))
{
  // You probably don't need to set anything in the configuration,
  // we infer a lot of information from the repo. One value that's worth
  // setting is your default sandbox ids to fork for a PR. It's easier to test
  // on a sandbox that includes some test cases already.
  // This is also optional, we default to 'vanilla' if it isn't set.
  "sandboxes": ["new", "vanilla"]
}
{
  // You probably don't need to set anything in the configuration,
  // we infer a lot of information from the repo. One value that's worth
  // setting is your default sandbox ids to fork for a PR. It's easier to test
  // on a sandbox that includes some test cases already.
  // This is also optional, we default to 'vanilla' if it isn't set.
  "sandboxes": ["new", "vanilla"]
}
from peewee import Model, SqliteDatabase, CharField, IntegerField, UUIDField
from uuid import uuid4
from faker import Faker
from random import randint

fake = Faker()

db = SqliteDatabase('mydb.db')

class User(Model):
    name = CharField(max_length = 25)
    email = CharField(max_length = 25)
    age = IntegerField()
    password = CharField(max_length = 100)
    user_id = UUIDField(primary_key = True, default = uuid4)

    class Meta:
        database = db


db.connect()
db.create_tables([User])

for i in range(20):
    new_user = User.create(**{
        'name': fake.name(),
        'email': fake.email(),
        'age': randint(12, 45),
        'password': fake.password()
    })

    new_user.save()

db.commit()
<div id="<%= dom_id(question) %>"
  class="grid-stack-item"
  gs-id="<%= question.id %>"
  gs-y="<%= question.position %>"
  gs-x="0"
  gs-w="12"
  gs-h="<%= question.new_record? && 2 %>"
  data-controller="questionnaire-question removable"
  data-action="item:added->questionnaire-question#openEdit questionnaire-question:saved->questionnaire#questionSaved"
  data-questionnaire-target="question"
  data-cy="<%= question.new_record? ? "new-" : "" %>questionnaire-question-<%= question.value_type %>">
  <div class="relative flex items-stretch overflow-visible grid-stack-item-content">
    <div class="flex flex-grow group-[.is-container]:hidden flex-1 items-center cursor-pointer space-x-3 py-1.5 px-4 bg-white rounded-lg dark:bg-gray-800 shadow-light dark:shadow-dark dark:hover:shadow-dark-hover">
      <%= inline_svg_tag "fields/#{question.value_type}.svg", class: "h-4 w-4" %>
      <span class="text-xs font-medium leading-6 text-gray-800 dark:text-gray-200">
        <%= t("value_type_#{question.value_type}", scope: "simple_form.labels.field") %>
      </span>
    </div>
    <div class="hidden group-[.is-container]:flex flex-col w-full">
      <div class="absolute right-5 flex items-center space-x-2.5 top-1/2 -mt-2 z-100">
        <%= render SlideoverComponent.new(title: t(".form_title_#{question.persisted?}"), size: questionnaire_question_slideover_size(question), toggle_actions: ["slideover#close", ("removable#remove" if question.new_record?)].compact) do |component| %>
          <% component.with_button do %>
            <%= button_tag type: "button", class: "h-4", data: {action: "slideover#open", questionnaire_question_target: "edit", cy: "edit-question"} do %>
              <%= heroicon "pencil-square", variant: "outline", options: {class: "w-4 h-4 text-gray-400 hover:text-gray-800 dark:hover:text-gray-200"} %>
            <% end %>
          <% end %>
          <%= render "form", question: %>
        <% end %>
        <%= render ConfirmationModalComponent.new(
          title: t(".delete_title"),
          message: t(".delete_message"),
          form_options: {url: [:settings, question.business_process, question], method: :delete, html: {data: {action: "removable#remove:passive", questionnaire_question_target: "deleteForm"}}}
        ) do |component| %>
          <% component.with_button(class: "h-4", data: {cy: "delete-question"}) do %>
            <%= heroicon "trash", variant: "outline", options: {class: "w-4 h-4 text-gray-400 hover:text-gray-800 dark:hover:text-gray-200"} %>
          <% end %>
        <% end %>
      </div>
      <div class="flex items-center h-full gridstack-draggable-handle">
        <div class="flex-1 rounded-lg grid-stack-item-content-container bg-white/60 dark:bg-gray-400/8 shadow-light dark:shadow-dark dark:hover:shadow-dark-hover">
          <% if question.value_type == "spreadsheet" %>
            <div class="flex-1 pt-3 pr-16 min-h-14">
              <div class="pl-4">
                <%= render "name", question: %>
              </div>
              <div class="relative px-1">
                <%= render "settings/questionnaire_questions/placeholders/#{question.value_type}" %>
              </div>
            </div>
          <% else %>
            <div class="flex items-center flex-1 py-2.5 px-4 min-h-14">
              <div class="w-1/2">
                <%= render "name", question: %>
              </div>
              <div class="relative flex-1 pr-16">
                <%= render "settings/questionnaire_questions/placeholders/#{question.value_type}" %>
              </div>
            </div>
          <% end %>
        </div>
      </div>
    </div>
  </div>
</div>
star

Fri May 24 2024 11:30:55 GMT+0000 (Coordinated Universal Time)

@webmasterUdL

star

Fri May 24 2024 09:53:56 GMT+0000 (Coordinated Universal Time) https://jitsi.github.io/handbook/docs/dev-guide/dev-guide-iframe/

@shookthacr3ator

star

Fri May 24 2024 09:21:12 GMT+0000 (Coordinated Universal Time)

@rafal_rydz

star

Fri May 24 2024 09:20:25 GMT+0000 (Coordinated Universal Time)

@rafal_rydz

star

Fri May 24 2024 09:19:33 GMT+0000 (Coordinated Universal Time)

@rafal_rydz

star

Fri May 24 2024 09:00:01 GMT+0000 (Coordinated Universal Time) https://blocksentinels.com/decentralized-exchange-development-company

@harsha98 #dex #decentralized

star

Fri May 24 2024 05:08:19 GMT+0000 (Coordinated Universal Time)

@tsesang

star

Fri May 24 2024 05:02:10 GMT+0000 (Coordinated Universal Time)

@dsce

star

Fri May 24 2024 05:01:20 GMT+0000 (Coordinated Universal Time)

@dsce

star

Fri May 24 2024 04:59:43 GMT+0000 (Coordinated Universal Time)

@dsce

star

Fri May 24 2024 04:59:05 GMT+0000 (Coordinated Universal Time)

@dsce

star

Fri May 24 2024 04:58:21 GMT+0000 (Coordinated Universal Time)

@dsce

star

Fri May 24 2024 04:57:45 GMT+0000 (Coordinated Universal Time)

@dsce

star

Fri May 24 2024 04:54:38 GMT+0000 (Coordinated Universal Time)

@tsesang

star

Thu May 23 2024 23:33:13 GMT+0000 (Coordinated Universal Time)

@azariel #glsl

star

Thu May 23 2024 22:12:24 GMT+0000 (Coordinated Universal Time) https://chromium.googlesource.com/chromium/src/+/main/net/data/ssl/chrome_root_store/root_store.md

@curtisbarry

star

Thu May 23 2024 21:06:20 GMT+0000 (Coordinated Universal Time)

@ayushg103 #c++

star

Thu May 23 2024 21:05:55 GMT+0000 (Coordinated Universal Time)

@ayushg103 #c++

star

Thu May 23 2024 18:01:38 GMT+0000 (Coordinated Universal Time)

@ReynaldJr

star

Thu May 23 2024 17:30:22 GMT+0000 (Coordinated Universal Time) https://leetcode.com/problems/remove-duplicates-from-sorted-array/submissions/

@TILAK_CODE_NOW

star

Thu May 23 2024 15:38:09 GMT+0000 (Coordinated Universal Time)

@omcm

star

Thu May 23 2024 15:19:10 GMT+0000 (Coordinated Universal Time)

@omcm

star

Thu May 23 2024 14:57:07 GMT+0000 (Coordinated Universal Time)

@kathrynhefner

star

Thu May 23 2024 12:31:13 GMT+0000 (Coordinated Universal Time) https://maticz.com/software-consulting-services

@Floralucy #inventorymanagement #inventory #warehousemanagement #inventorysoftware

star

Thu May 23 2024 10:23:19 GMT+0000 (Coordinated Universal Time)

@jakaria

star

Thu May 23 2024 05:21:03 GMT+0000 (Coordinated Universal Time) https://codepen.io/Gurken-Glas/pen/PovNoJx

@radeguzvic #undefined

star

Thu May 23 2024 03:29:38 GMT+0000 (Coordinated Universal Time) https://chatgpt.com/?oai-dm

@kris96tian #python

star

Thu May 23 2024 02:10:20 GMT+0000 (Coordinated Universal Time)

@manhmd #java

star

Thu May 23 2024 00:34:15 GMT+0000 (Coordinated Universal Time) https://www.kali.org/tools/above/

@Mad_Hatter

star

Thu May 23 2024 00:33:06 GMT+0000 (Coordinated Universal Time) https://www.kali.org/tools/7zip/

@Mad_Hatter

star

Thu May 23 2024 00:27:20 GMT+0000 (Coordinated Universal Time) https://developer.wordpress.org/advanced-administration/wordpress/update-services/

@radeguzvic

star

Thu May 23 2024 00:21:14 GMT+0000 (Coordinated Universal Time) https://www.kali.org/tools/wifite/

@Mad_Hatter

star

Thu May 23 2024 00:11:49 GMT+0000 (Coordinated Universal Time) https://www.kali.org/tools/villain/

@Mad_Hatter #linux #kali #tools

star

Wed May 22 2024 22:55:14 GMT+0000 (Coordinated Universal Time) https://learn.microsoft.com/en-us/windows/terminal/distributions

@Mad_Hatter

star

Wed May 22 2024 21:12:56 GMT+0000 (Coordinated Universal Time) https://onlinehtmleditor.dev/

@ami #undefined

star

Wed May 22 2024 21:11:26 GMT+0000 (Coordinated Universal Time) https://onlinehtmleditor.dev/

@ami #undefined

star

Wed May 22 2024 18:16:31 GMT+0000 (Coordinated Universal Time)

@RehmatAli2024 #deluge

star

Wed May 22 2024 16:59:45 GMT+0000 (Coordinated Universal Time) https://ci.codesandbox.io/setup?installation_id

@radeguzvic #json

star

Wed May 22 2024 16:59:43 GMT+0000 (Coordinated Universal Time) https://ci.codesandbox.io/setup?installation_id

@radeguzvic #json

star

Wed May 22 2024 16:59:40 GMT+0000 (Coordinated Universal Time) https://ci.codesandbox.io/setup?installation_id

@radeguzvic #json

star

Wed May 22 2024 16:59:36 GMT+0000 (Coordinated Universal Time) https://ci.codesandbox.io/setup?installation_id

@radeguzvic #json

star

Wed May 22 2024 16:51:42 GMT+0000 (Coordinated Universal Time)

@taufiq_ali

star

Wed May 22 2024 15:40:37 GMT+0000 (Coordinated Universal Time) https://www.pyramidions.com/mobile-app-development-chennai.html

@Steve_1

star

Wed May 22 2024 15:13:11 GMT+0000 (Coordinated Universal Time) https://ci.codesandbox.io/setup?installation_id

@radeguzvic #json

star

Wed May 22 2024 15:13:07 GMT+0000 (Coordinated Universal Time) https://ci.codesandbox.io/setup?installation_id

@radeguzvic #json

star

Wed May 22 2024 13:57:20 GMT+0000 (Coordinated Universal Time)

@flawed

star

Wed May 22 2024 12:21:03 GMT+0000 (Coordinated Universal Time) https://www.alphacodez.com/paxful-clone-script

@PaulWalker07 #c #c++

Save snippets that work with our extensions

Available in the Chrome Web Store Get Firefox Add-on Get VS Code extension