Skip to content

Commit

Permalink
added more dark themes
Browse files Browse the repository at this point in the history
  • Loading branch information
RabbITCybErSeC committed Sep 11, 2024
1 parent ebfd199 commit e2d7b09
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 32 deletions.
4 changes: 2 additions & 2 deletions tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ module.exports = {
'c-dark-slate-background': colors.slate[950],
'c-dark-slate-header-background': colors.slate[800],
'c-dark-slate-navbar-background': colors.slate[800],
'c-dark-slate-card': colors.slate[800],
'c-dark-slate-border': colors.slate[600],
'c-dark-slate-text': colors.slate[200],
'c-dark-slate-text-dark': colors.slate[600],
'c-dark-slate-documentation-background': colors.slate[900],
'c-dark-background': colors.slate[600],
'c-dark-blue-background': colors.blue[950],


}
},
},
Expand Down
18 changes: 9 additions & 9 deletions views/components/cards/reporting_card.templ
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,13 @@ var reportingCards = []ReportingCardData{
templ executedPlaybooksCard(data ReportingCardData) {
@Card() {
<div class="col-span-12 sm:col-span-6 md:col-span-3">
<div class="flex flex-row bg-white shadow-sm rounded p-4">
<div class="flex flex-row bg-white shadow-sm rounded p-4 dark:bg-c-dark-slate-card">
<div class="flex items-center justify-center flex-shrink-0 h-12 w-12 rounded-xl bg-blue-100 text-blue-600">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-book-open"><path d="M2 3h6a4 4 0 0 1 4 4v14a3 3 0 0 0-3-3H2z"></path><path d="M22 3h-6a4 4 0 0 0-4 4v14a3 3 0 0 1 3-3h7z"></path></svg>
</div>
<div class="flex flex-col flex-grow ml-4">
<div class="text-sm text-gray-500">Executed Playbooks</div>
<div class="font-bold text-lg">{ fmt.Sprint(data.Value) }</div>
<div class="text-sm text-gray-500 dark:text-c-dark-slate-text">Executed Playbooks</div>
<div class="font-bold text-lg dark:text-white">{ fmt.Sprint(data.Value) }</div>
</div>
</div>
</div>
Expand All @@ -47,13 +47,13 @@ templ executedPlaybooksCard(data ReportingCardData) {
templ failedPlaybooksCard(data ReportingCardData) {
@Card() {
<div class="col-span-12 sm:col-span-6 md:col-span-3">
<div class="flex flex-row bg-white shadow-sm rounded p-4">
<div class="flex flex-row bg-white shadow-sm rounded p-4 dark:bg-c-dark-slate-card">
<div class="flex items-center justify-center flex-shrink-0 h-12 w-12 rounded-xl bg-red-100 text-red-600">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-alert-triangle"><path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"></path><line x1="12" y1="9" x2="12" y2="13"></line><line x1="12" y1="17" x2="12.01" y2="17"></line></svg>
</div>
<div class="flex flex-col flex-grow ml-4">
<div class="text-sm text-gray-500">Failed Playbooks</div>
<div class="font-bold text-lg">{ fmt.Sprint(data.Value) }</div>
<div class="text-sm text-gray-500 dark:text-dark-slate-text">Failed Playbooks</div>
<div class="font-bold text-lg dark:text-white">{ fmt.Sprint(data.Value) }</div>
</div>
</div>
</div>
Expand All @@ -63,13 +63,13 @@ templ failedPlaybooksCard(data ReportingCardData) {
templ ongoingPlaybooksCard(data ReportingCardData) {
@Card() {
<div class="col-span-12 sm:col-span-6 md:col-span-3">
<div class="flex flex-row bg-white shadow-sm rounded p-4">
<div class="flex flex-row bg-white shadow-sm rounded p-4 dark:bg-c-dark-slate-card">
<div class="flex items-center justify-center flex-shrink-0 h-12 w-12 rounded-xl bg-orange-100 text-orange-600">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-play"><polygon points="5 3 19 12 5 21 5 3"></polygon></svg>
</div>
<div class="flex flex-col flex-grow ml-4">
<div class="text-sm text-gray-500">Ongoing Playbooks</div>
<div class="font-bold text-lg">{ fmt.Sprint(data.Value) }</div>
<div class="text-sm text-gray-500 dark:text-c-dark-slate-text">Ongoing Playbooks</div>
<div class="font-bold text-lg dark:text-white">{ fmt.Sprint(data.Value) }</div>
</div>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion views/components/table/reporting_table.templ
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ templ reportingTableHeaders() {

templ reportingTableDataRow(row ReportingDataTableRow) {
@Td() {
<a href={ templ.URL(fmt.Sprintf("%s%s", reportingDetailedViewEndpoint, row.ExecutionID)) } class="text-blue-800 hover:text-blue-400">{ row.Name } </a>
<a href={ templ.URL(fmt.Sprintf("%s%s", reportingDetailedViewEndpoint, row.ExecutionID)) } class="text-blue-800 hover:text-blue-400 dark:text-c-dark-slate-text dark:hover:text-white dark:hover:underline">{ row.Name } </a>
}
@Td() {
{ row.StartTime.Format(time.ANSIC) }
Expand Down
14 changes: 7 additions & 7 deletions views/dashboards/home/home.templ
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ templ dummyActivity() {
<div class="p-4">
<div class="flex items-center justify-between mb-4">
<h3 class="text-lg font-semibold text-gray-900 dark:text-white">Latest Activity</h3>
<a href="#" class="inline-flex items-center p-2 text-sm font-medium rounded-lg text-primary-700 hover:bg-gray-100 dark:text-primary-500 dark:hover:bg-gray-700">
<a href="#" class="inline-flex items-center p-2 text-sm font-medium rounded-lg text-primary-700 hover:bg-gray-100 dark:text-white dark:text-primary-500 dark:hover:bg-gray-700">
View all
</a>
</div>
Expand All @@ -111,7 +111,7 @@ templ dummyActivity() {
<time class="mb-1 text-sm font-normal leading-none text-gray-400 dark:text-gray-500">April 2023</time>
<h3 class="text-lg font-semibold text-gray-900 dark:text-white">SOARCA UI Enhancements</h3>
<p class="mb-4 text-base font-normal text-gray-500 dark:text-gray-400">Implemented new user interface designs in Figma to streamline the workflow and enhance user experience for security automation.</p>
<a href="#" class="inline-flex items-center px-4 py-2 text-sm font-medium text-gray-900 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 hover:text-primary-700 focus:z-10 focus:ring-4 focus:outline-none focus:ring-gray-200 focus:text-primary-700 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700 dark:focus:ring-gray-700">
<a href="#" class="inline-flex items-center px-4 py-2 text-sm font-medium text-gray-900 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 hover:text-primary-700 focus:z-10 focus:ring-4 focus:outline-none focus:ring-gray-200 focus:text-primary-700 dark:bg-grey-600 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-v-c- dark:focus:ring-gray-700">
Learn more
<svg class="w-3 h-3 ml-2" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" d="M12.293 5.293a1 1 0 011.414 0l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414-1.414L14.586 11H3a1 1 0 110-2h11.586l-2.293-2.293a1 1 0 010-1.414z" clip-rule="evenodd"></path>
Expand All @@ -123,8 +123,8 @@ templ dummyActivity() {
<time class="mb-1 text-sm font-normal leading-none text-gray-400 dark:text-gray-500">March 2023</time>
<h3 class="text-lg font-semibold text-gray-900 dark:text-white">SOARCA FIN Integration</h3>
<p class="mb-4 text-base font-normal text-gray-500 dark:text-gray-400">Integrate custom integration into your code using the SOARCA Fin Library</p>
<a href="https://flowbite.com/blocks/" class="inline-flex items-center text-xs font-medium hover:underline text-primary-700 sm:text-sm dark:text-primary-500">
Go to SOARCA FIN library
<a href="https://flowbite.com/blocks/" class="inline-flex items-center text-xs font-medium hover:underline text-primary-700 sm:text-sm dark:text-white dark:text-primary-500">
Go to SOARCA FIN library/
<svg class="w-4 h-4 ml-1" fill="none" stroke="currentColor" stroke-width="2" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
<path stroke-linecap="round" stroke-linejoin="round" d="M17 8l4 4m0 0l-4 4m4-4H3"></path>
</svg>
Expand All @@ -147,10 +147,10 @@ templ dummyActivity() {
}

templ headersection() {
@cards.Card(utils.Class("relative bg-gradient-to-r from-blue-600 to-fuchsia-500 shadow-md rounded-lg p-2")) {
@cards.Card(utils.Class("relative bg-gradient-to-r from-blue-600 to-fuchsia-500 shadow-md rounded-lg p-2 dark:bg-c-dark-blue-background dark:bg-none")) {
<div class="h-10 flex items-center">
@icons.NewIcon("user").InsertIcon("ml-3 mr-3 text-white")
<h1 class="text-2xl text-bold text-white">Welcome 'some name' back to SOARCA</h1>
@icons.NewIcon("user").InsertIcon("ml-3 mr-3 text-white dark:text-c-slate-text")
<h1 class="text-2xl text-bold text-white dark:text-c-dark-slate-text">Welcome 'some name' back to SOARCA</h1>
</div>
}
}
Expand Down
4 changes: 2 additions & 2 deletions views/dashboards/reporting/reporting.templ
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@ templ ReportingIndex() {
}

templ banner() {
@cards.Card(utils.Class("relative bg-gradient-to-r from-blue-600 to-fuchsia-500 shadow-md rounded-lg p-2 mb-2")) {
@cards.Card(utils.Class("relative bg-gradient-to-r from-blue-600 to-fuchsia-500 shadow-md rounded-lg p-2 mb-2 dark:bg-c-dark-slate-background/ dark:bg-none")) {
<div class="h-10 flex items-center">
<button onclick="history.back()" class="flex items-center justify-center w-1/2 px-5 py-2 text-sm text-gray-700 transition-colors duration-200 bg-white border rounded-lg gap-x-2 sm:w-auto dark:hover:bg-gray-800 dark:bg-gray-900 hover:bg-gray-100 dark:text-gray-200 dark:border-gray-700">
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-5 h-4 rtl:rotate-180">
<path stroke-linecap="round" stroke-linejoin="round" d="M6.75 15.75L3 12m0 0l3.75-3.75M3 12h18"></path>
</svg>
<span>Go back</span>
</button>
<h1 class="ml-3 text-2xl text-bold text-white">Reporting</h1>
<h1 class="ml-3 text-2xl text-bold text-white dark:text-c-dark-slate-text">Reporting</h1>
</div>
}
}
22 changes: 11 additions & 11 deletions views/dashboards/reporting/reporting_detailed.templ
Original file line number Diff line number Diff line change
Expand Up @@ -71,28 +71,28 @@ templ playbookInfoCard(executionReport reporter.PlaybookExecutionReport) {
<table class="table-auto text-sm text-gray-600">
<tbody>
<tr>
<th class="pr-4 text-left font-semibold dark:text-c-dark-slate-text ">Execution ID:</th>
<td>{ executionReport.ExecutionId }</td>
<th class="pr-4 text-left font-semibold dark:text-c-dark-slate-text">Execution ID:</th>
<td class="dark:text-white">{ executionReport.ExecutionId }</td>
</tr>
<tr>
<th class="font-semibold text-left pr-4 dark:text-c-dark-slate-text ">Description:</th>
<td>{ executionReport.Description }</td>
<th class="font-semibold text-left pr-4 dark:text-c-dark-slate-text">Description:</th>
<td class="dark:text-white">{ executionReport.Description }</td>
</tr>
<tr>
<th class="font-semibold text-left pr-4 dark:text-c-dark-slate-text ">Started:</th>
<td>{ executionReport.Started.Format(time.ANSIC) }</td>
<th class="font-semibold text-left pr-4 dark:text-c-dark-slate-text">Started:</th>
<td class="dark:text-white">{ executionReport.Started.Format(time.ANSIC) }</td>
</tr>
<tr>
<th class="pr-4 text-left font-semibold dark:text-c-dark-slate-text ">Ended:</th>
<td>{ executionReport.Ended.Format(time.ANSIC) }</td>
<th class="pr-4 text-left font-semibold dark:text-c-dark-slate-text">Ended:</th>
<td class="dark:text-white">{ executionReport.Ended.Format(time.ANSIC) }</td>
</tr>
<tr>
<th class="pr-4 text-left font-semibold dark:text-c-dark-slate-text ">Duration:</th>
<td>{ formatDuration(executionReport.Started, executionReport.Ended) }</td>
<td class="dark:text-white">{ formatDuration(executionReport.Started, executionReport.Ended) }</td>
</tr>
<tr>
<th class="pr-4 text-left font-semibold dark:text-c-dark-slate-text ">Status:</th>
<td>{ executionReport.StatusText }</td>
<td class="dark:bg-c-dark-slate-background">{ executionReport.StatusText }</td>
</tr>
</tbody>
</table>
Expand Down Expand Up @@ -226,7 +226,7 @@ templ timelineView(stepResults map[string]reporter.StepExecutionReport) {
<ol class="border-s border-gray-200 dark:border-gray-700">
for _, stepResult := range stepResults {
<li class="mb-5 ms-6">
<span class="absolute -start-3 flex h-6 w-6 items-center justify-center rounded-full bg-white ring-8 ring-white">
<span class="absolute -start-3 flex h-6 w-6 items-center justify-center rounded-full bg-white dark:bg-c-dark-slate-card ring-8 ring-white dark:ring-c-dark-slate-card">
@indicators.ReportingStatusTagNoText(stepResult.Status)
</span>
<h3 class="flex items-center mb-1 text-lg font-semibold text-gray-900 dark:text-white">{ stepResult.Name }</h3>
Expand Down

0 comments on commit e2d7b09

Please sign in to comment.