Productivity Widget
Focus tools — a pomodoro timer, a habit-streak card, a time-allocation ring panel, and a day planner.
Preview
@props([])
@php
$tasks = [
['task' => 'Daily Scrum Meeting', 'time' => '9:00 AM to 9:30 AM', 'completed' => true],
['task' => 'Review mockup designs', 'time' => '10:00 AM to 11:00 AM', 'completed' => true],
['task' => 'Client report prep', 'time' => '1:00 PM to 2:30 PM', 'completed' => false],
];
$done = collect($tasks)->where('completed', true)->count();
$total = count($tasks);
@endphp
<x-ui.card class="w-full max-w-md flex flex-col">
<div class="flex items-stretch gap-4 p-6">
{{-- Left: summary --}}
<div class="flex flex-col justify-between gap-4 pe-4 border-e border-border">
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
stroke-width="1.5"
stroke-linecap="round"
stroke-linejoin="round"
class="size-6 text-muted-foreground"
aria-hidden="true"
>
<line x1="8" y1="6" x2="21" y2="6" />
<line x1="8" y1="12" x2="21" y2="12" />
<line x1="8" y1="18" x2="21" y2="18" />
<line x1="3" y1="6" x2="3.01" y2="6" />
<line x1="3" y1="12" x2="3.01" y2="12" />
<line x1="3" y1="18" x2="3.01" y2="18" />
</svg>
<div class="flex flex-col">
<span class="text-4xl font-semibold tabular-nums text-foreground">{{ $done }}/{{ $total }}</span>
<span class="text-sm text-muted-foreground">{{ __('tasks done') }}</span>
</div>
</div>
{{-- Right: scrollable task list --}}
<div class="flex-1 max-h-40 overflow-y-auto flex flex-col gap-2">
@foreach ($tasks as $task)
<div class="flex items-start gap-2 rounded-md px-2 py-2">
<x-ui.checkbox class="mt-0.5" :checked="$task['completed']" disabled aria-label="{{ __($task['task']) }}" />
<div class="flex flex-col">
<span @class([
'text-sm text-foreground',
'line-through text-muted-foreground' => $task['completed'],
])>{{ __($task['task']) }}</span>
<span class="text-xs text-muted-foreground">{{ $task['time'] }}</span>
</div>
</div>
@endforeach
</div>
</div>
</x-ui.card>
Installation
php artisan ui:add blocks/productivity-widget-planner
Registry contract
Install confidence
php artisan ui:add blocks/productivity-widget-planner
writes only the generated targets below. The CLI validates each file hash before writing and
prompts before replacing local changes unless --force is used.
- Version
- 1.0.3
- License
- open
- Stability
- stable
- Contract
- v1
- Foundation
- ≥ 1.0.0
| Type | Generated target |
|---|---|
| blade | resources/views/blocks/productivity-widget-planner.blade.php |
Registry dependencies
Package dependencies
composer: jml/brok:^0.2
Use with AI
A brief for your coding agent: what the block is, the install command, how to render it, its props and the rules. Copy it, or open a prompt about this block in an assistant.
# Brok UI block: Productivity Widget Planner (`productivity-widget-planner`)
A day-planner widget with a tasks-done summary and a scrollable checklist of timed tasks.
Brok UI is a Laravel Blade registry. `ui:add` copies this block into the app as plain Blade the app owns; it composes installed `<brok:*>` primitives and semantic design tokens.
## Install
```bash
php artisan ui:add blocks/productivity-widget-planner
```
## Render it
```blade
<x-blocks.productivity-widget-planner />
```
## Use when
- Showing a day-planner card with a tasks-done summary count and a scrollable, read-only checklist of timed tasks.
- Use when you need a static snapshot of a schedule rather than a checklist the user can toggle.
## Avoid when
- Needing an interactive check-in the user can click to mark done; use productivity-widget-habit instead.
## Rules
- Render the installed block with `<x-blocks.productivity-widget-planner />` and pass data through its props; edit the copied file only for structural changes.
- Keep the semantic design tokens (`bg-background`, `text-muted-foreground`); never swap in raw colour utilities.
- Keep the `data-slot` attributes and the logical (start/end) spacing so the markup still mirrors under `dir="rtl"`.
## Links
- Docs: https://brokui.dev/blocks/productivity-widget-planner
- Registry JSON (files, props, contract): https://brokui.dev/r/open/blocks/productivity-widget-planner.json
Working in Claude Code, Cursor or Codex? Give the agent the whole registry through the MCP server or the Brok UI skill.
Guidance
Use when
- Showing a day-planner card with a tasks-done summary count and a scrollable, read-only checklist of timed tasks.
- Use when you need a static snapshot of a schedule rather than a checklist the user can toggle.
Avoid when
- Needing an interactive check-in the user can click to mark done; use productivity-widget-habit instead.
Anti-patterns
- Do not replace semantic props with conflicting utility classes.
- Do not remove labels, focus styles, or state attributes.
- Anatomy
Usage
Render the block as a component, passing data where useful:
<x-blocks.productivity-widget-planner />
Built from primitives
This block composes installed <brok:*> primitives and semantic design
tokens only — it does not reimplement any primitive. Re-theme it (light, dark, admin, customer) by
editing CSS variables; flip the preview to RTL to confirm it mirrors.
Source
The exact, editable file ui:add writes
into your app. The preview above renders this same source — there are no preview-only blocks.
@props([])
@php
$tasks = [
['task' => 'Daily Scrum Meeting', 'time' => '9:00 AM to 9:30 AM', 'completed' => true],
['task' => 'Review mockup designs', 'time' => '10:00 AM to 11:00 AM', 'completed' => true],
['task' => 'Client report prep', 'time' => '1:00 PM to 2:30 PM', 'completed' => false],
];
$done = collect($tasks)->where('completed', true)->count();
$total = count($tasks);
@endphp
<x-ui.card class="w-full max-w-md flex flex-col">
<div class="flex items-stretch gap-4 p-6">
{{-- Left: summary --}}
<div class="flex flex-col justify-between gap-4 pe-4 border-e border-border">
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
fill="none"
stroke="currentColor"
stroke-width="1.5"
stroke-linecap="round"
stroke-linejoin="round"
class="size-6 text-muted-foreground"
aria-hidden="true"
>
<line x1="8" y1="6" x2="21" y2="6" />
<line x1="8" y1="12" x2="21" y2="12" />
<line x1="8" y1="18" x2="21" y2="18" />
<line x1="3" y1="6" x2="3.01" y2="6" />
<line x1="3" y1="12" x2="3.01" y2="12" />
<line x1="3" y1="18" x2="3.01" y2="18" />
</svg>
<div class="flex flex-col">
<span class="text-4xl font-semibold tabular-nums text-foreground">{{ $done }}/{{ $total }}</span>
<span class="text-sm text-muted-foreground">{{ __('tasks done') }}</span>
</div>
</div>
{{-- Right: scrollable task list --}}
<div class="flex-1 max-h-40 overflow-y-auto flex flex-col gap-2">
@foreach ($tasks as $task)
<div class="flex items-start gap-2 rounded-md px-2 py-2">
<x-ui.checkbox class="mt-0.5" :checked="$task['completed']" disabled aria-label="{{ __($task['task']) }}" />
<div class="flex flex-col">
<span @class([
'text-sm text-foreground',
'line-through text-muted-foreground' => $task['completed'],
])>{{ __($task['task']) }}</span>
<span class="text-xs text-muted-foreground">{{ $task['time'] }}</span>
</div>
</div>
@endforeach
</div>
</div>
</x-ui.card>
Ownership & lifecycle
Owner, release state, review evidence and adoption for this item.
- Owner
- Platform UI (@JoshJML)
- Current version
-
1.0.3 - Status
- Stable
- License
-
open - Deprecation
- Not deprecated
- Contract
-
v1 - Foundation
-
≥ 1.0.0