1// Copyright 2020 Google LLC 2// 3// Licensed under the Apache License, Version 2.0 (the "License"); 4// you may not use this file except in compliance with the License. 5// You may obtain a copy of the License at 6// 7// http://www.apache.org/licenses/LICENSE-2.0 8// 9// Unless required by applicable law or agreed to in writing, software 10// distributed under the License is distributed on an "AS IS" BASIS, 11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12// See the License for the specific language governing permissions and 13// limitations under the License. 14 15syntax = "proto3"; 16 17package google.actions.sdk.v2.interactionmodel.prompt; 18 19import "google/api/field_behavior.proto"; 20 21option go_package = "google.golang.org/genproto/googleapis/actions/sdk/v2/interactionmodel/prompt;prompt"; 22option java_multiple_files = true; 23option java_outer_classname = "StaticImagePromptProto"; 24option java_package = "com.google.actions.sdk.v2.interactionmodel.prompt"; 25 26// An image displayed in the card. 27message StaticImagePrompt { 28 // Possible image display options for affecting the presentation of the image. 29 // This should be used for when the image's aspect ratio does not match the 30 // image container's aspect ratio. 31 enum ImageFill { 32 // ImageFill unspecified. 33 UNSPECIFIED = 0; 34 35 // Fill the gaps between the image and the image container with gray bars. 36 GRAY = 1; 37 38 // Fill the gaps between the image and the image container with white bars. 39 WHITE = 2; 40 41 // Image is scaled such that the image width and height match or exceed the 42 // container dimensions. This may crop the top and bottom of the image if 43 // the scaled image height is greater than the container height, or crop the 44 // left and right of the image if the scaled image width is greater than the 45 // container width. This is similar to "Zoom Mode" on a widescreen TV when 46 // playing a 4:3 video. 47 CROPPED = 3; 48 } 49 50 // Required. The source url of the image. Images can be JPG, PNG and GIF (animated and 51 // non-animated). For example,`https://www.agentx.com/logo.png`. 52 string url = 1 [(google.api.field_behavior) = REQUIRED]; 53 54 // Required. A text description of the image to be used for accessibility, e.g. screen 55 // readers. 56 string alt = 2 [(google.api.field_behavior) = REQUIRED]; 57 58 // Optional. The height of the image in pixels. 59 int32 height = 3 [(google.api.field_behavior) = OPTIONAL]; 60 61 // Optional. The width of the image in pixels. 62 int32 width = 4 [(google.api.field_behavior) = OPTIONAL]; 63} 64