Columns 위젯은 카드 또는 대화상자에 최대 2개의 열을 표시합니다. 각 Column에 위젯을 추가할 수 있으며 위젯은 지정된 순서대로 표시됩니다. Google Chat 앱의 예는 열을 참고하세요.
각 열의 높이는 더 높은 열에 따라 결정됩니다. 예를 들어 첫 번째 열이 두 번째 열보다 높으면 두 열 모두 첫 번째 열의 높이를 갖습니다. 각 열에 서로 다른 수의 위젯이 포함될 수 있으므로 행을 정의하거나 열 간에 위젯을 정렬할 수 없습니다.
열이 나란히 표시됩니다. HorizontalSizeStyle 필드를 사용하여 각 열의 너비를 맞춤설정할 수 있습니다. 사용자의 화면 너비가 너무 좁으면 두 번째 열이 첫 번째 열 아래로 줄바꿈됩니다.
웹에서는 화면 너비가 480픽셀 이하인 경우 두 번째 열이 줄바꿈됩니다.
iOS 기기에서는 화면 너비가 300pt 이하인 경우 두 번째 열이 줄바꿈됩니다.
Android 기기에서 화면 너비가 320dp 이하이면 두 번째 열이 줄바꿈됩니다.
Google Chat 앱 및 Google Workspace 부가기능에서 사용할 수 있습니다. 열을 지원하는 부가기능 UI는 다음과 같습니다.
사용자가 이메일 초안에서 부가기능을 열 때 표시되는 대화상자입니다.
사용자가 Google Calendar 일정의 첨부파일 추가 메뉴에서 부가기능을 열 때 표시되는 대화상자입니다.
// Build a column that is aligned in the center and fills the space:constcolumn=CardService.newColumn().setHorizontalSizeStyle(CardService.HorizontalSizeStyle.FILL_AVAILABLE_SPACE).setHorizontalAlignment(CardService.HorizontalAlignment.CENTER).setVerticalAlignment(CardService.VerticalAlignment.CENTER);constcolumns=CardService.newColumns().addColumn(column).setWrapStyle(CardService.WrapStyle.WRAP);
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["필요한 정보가 없음","missingTheInformationINeed","thumb-down"],["너무 복잡함/단계 수가 너무 많음","tooComplicatedTooManySteps","thumb-down"],["오래됨","outOfDate","thumb-down"],["번역 문제","translationIssue","thumb-down"],["샘플/코드 문제","samplesCodeIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-01-30(UTC)"],[[["The Columns widget allows displaying up to two columns within cards or dialogs, with widgets arranged vertically within each column."],["Column height is determined by the taller column, and widgets cannot be aligned across columns or organized into rows."],["Columns are displayed side-by-side and wrap to a vertical layout on smaller screens based on specified screen width thresholds."],["Customization options include adjusting column width and controlling wrapping behavior with `HorizontalSizeStyle` and `WrapStyle` respectively."],["This widget is available for Google Chat apps and specific Google Workspace Add-ons, like dialogs in email drafts or Calendar event attachments."]]],["The Columns widget displays up to two columns in a card or dialog, with widgets added to each column in a specified order. Column height is determined by the taller column, and widths can be customized. If the screen is too narrow, the second column wraps below the first, with specific pixel/point/dp thresholds for web, iOS, and Android devices. Key actions include adding columns using `addColumn()` and controlling resizing with `setWrapStyle()`. These features are available for Google Chat and Workspace add-ons.\n"]]