首页

Dialogs and alerts

模态对话框的边框、带图标的警告框布局,以及带阴影的简单方框。

Save changes to the document “Untitled” before closing?

<div class="alert-box" role="alertdialog" aria-labelledby="clio-alert-msg" style="width: 340px">
  <span class="alert-icon caution" aria-hidden="true"></span>
  <p id="clio-alert-msg">Save changes to the document “Untitled” before closing?</p>
  <div class="dialog-buttons">
    <button>Don’t Save</button>
    <button>Cancel</button>
    <button class="default">Save</button>
  </div>
</div>
Mac OS 四个年代并排对照
System 6
System 7
Drawing Board
Mac OS 9 Platinum

简单方框

带阴影的方框,用于没有自己边框的信息。

Welcome to Macintosh.

<div class="standard-dialog" style="width: 280px">
  <p style="margin: 0">Welcome to Macintosh.</p>
</div>

Dialogs and alerts 简介

选择器
.modal-dialog .alert-box .standard-dialog .modeless-dialog .alert-icon .dialog-buttons
Token
--clio-dialog-bg --clio-modal-border --clio-modal-frame --clio-plain-dialog-shadow
无障碍
把这些类加在原生 <dialog> 上,并用 showModal() 打开,就有焦点限制和 Escape 键;用 aria-labelledby 给它命名。

也接受: system.css 的标记(.modal-dialog, .alert-box, .standard-dialog, .outer-border, .inner-border, .modal-contents).

证据(15)
每个数值的来源(英文)
年代数值状态来源
System 7Alert frame: 1px black, a raised #ccf/#669 ring, #bbb, a sunken #669/#ccf ring, 1px black (5px, as in System 6)实测clio.css capture, System 7.5.3 in Infinite Mac (npm run capture:system7), frame page-setup
100% identical. An alert without a colour table keeps System 6's black frame (Monitors & Sound alert); clio.css draws the colour one
System 6Modal frame: 1px ink, 2px paper, 2px ink, and no drop shadow实测clio.css capture, System 6.0.8 in Infinite Mac (npm run capture:system6), frame alert
AI System 6 has two recipes, both off (84-clio-write.css:210 has a 1px gap)
System 6Plain box: 1px ink frame and a 2px drop shadow推断not measured
altDBoxProc; none of the 6.0.8 Finder and TeachText dialogs opened for capture (alerts, Standard File, About the Finder) uses it
Classic erasThe alert icon is drawn here, not Apple's调整clio.css
no Apple icons are shipped
Platinum1px black frame over #ddd, inner bevel of three white steps inside #555/#999/#aaa, 1px black drop实测apps/desktop/styles/65-appearance-themes.css:840 (P06)
GUIdebook Mac OS 9.0 About application (about-alert specimen)
Drawing BoardAlerts: the theme's eight Alert pictures (6127-6134) round the outline, edges tiled from their ends, on the window paper from 4px inside实测clio.css capture, Mac OS 8.5 with the 8.5b6 Drawing Board theme in Infinite Mac (npm run capture:drawingboard), frame energy-saver-alert; the theme file's ppat and pxm# resources, decoded by tooling/theme-resources.py, written by tooling/db-art.py and tooling/db-pens.py
every piece found 1:1 round Energy Saver's start-up notice
Drawing BoardMovable modal dialogs (.modeless-dialog, which is a .window) draw the document window's frame: #222 outline, 4px #cdc6bd frame, #777 inner line, 20px title bar over a #555 rule, the #777 band right and below实测clio.css capture, Mac OS 8.5 with Drawing Board (npm run capture:drawingboard), frame copy-progress-5
Finder copy window; Movable_Modal pixmaps found 1:1
Drawing BoardModal dialogs: the Modal pictures (6135-6142), which have the alert's sizes, placed the same way推断the theme file's ppat and pxm# resources, decoded by tooling/theme-resources.py, written by tooling/db-art.py and tooling/db-pens.py
no modal dialog was on screen in the captures
PlatinumSeparator line (.separator, <hr class=separator>): etched, #888 then white one row lower and one column further right实测clio.css capture, Mac OS 9.0 in Infinite Mac, frame hig/platinum9/mouse
100% identical
System 7Separator line: a 3px band of QuickDraw's 50% grey, aligned to the screen实测clio.css capture, System 7.5.3 in Infinite Mac, frame hig/system7/memory
—
System 6Separator line: 1px of ink推断clio.css
—
NeXTSTEPA panel (Info): a window with the key title bar and a close button, no resize bar; its details in a box with no title实测clio.css capture, NeXTStep 3.0 in Infinite Mac (frames in .fidelity/ns30), frame ns30b/infopanel (Workspace's Info panel, 380x264)
fidelity nx-panel-top, nx-panel-foot, nx-box-plain
NeXTSTEPAttention panel: #aaaaaa, the 1px black frame, the key window's title bar with no title and no buttons, no shadow; a groove (#555555 over white) 86 rows in; the buttons 8px from the lower right and 8px apart实测clio.css capture, NeXTStep 3.0 in Infinite Mac (frames in .fidelity/ns30), frame logout-alert (Workspace's Log Out panel, 364x185)
fidelity nx-alert-titlebar, nx-alert-groove, nx-alert-buttons
NeXTSTEPAbove the groove the application's 48px icon and the panel's title (its aria-label) in Helvetica 18; the message centred below推断clio.css capture, NeXTStep 3.0 in Infinite Mac (frames in .fidelity/ns30), frame logout-alert (positions read from the frame; text and icon are not compared)
NeXTSTEP User Interface Guidelines, Release 3 p.84-87
NeXTSTEPThe application's icon, not a symbol: without one the slot stays empty推断NeXTSTEP User Interface Guidelines, Release 3 p.84
AI System 6 shows none either

关于 clio.css

版本 2.0.4

MIT 许可。源代码在 GitHub。

字体:Clio Sans '84、Clio Text '84 和 Clio Sans '97 是按实测点阵新做的字体。ChicagoFLF 的作者是 Robin Casady(公有领域)。Asap 的作者是 Omnibus-Type,Clio Sans NX 取自 Liberation Sans 2,Clio Pixel 取自 TakWolf 的 Fusion Pixel Font,这三种都用 SIL Open Font License 1.1。详情见 THIRD-PARTY.md(英文)。

本项目与 Apple Inc. 没有关联,也未获其认可。Macintosh、Mac OS 和 Chicago 是 Apple Inc. 的商标,这里提到它们只为说明所还原的年代。

查找

输入组件、选择器、token 或数值。索引是英文的,请用英文查找。