1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
7 "namespace": "omnibox",
8 "description": "The omnibox API allows you to register a keyword with Google Chrome's address bar, which is also known as the omnibox.",
11 "id": "SuggestResult",
13 "description": "A suggest result.",
18 "description": "The text that is put into the URL bar, and that is sent to the extension when the user chooses this entry."
23 "description": "The text that is displayed in the URL dropdown. Can contain XML-style markup for styling. The supported tags are 'url' (for a literal URL), 'match' (for highlighting text that matched what the user's query), and 'dim' (for dim helper text). The styles can be nested, eg. <dim><match>dimmed match</match></dim>."
25 "descriptionStyles": {
29 "description": "An array of style ranges for the description, as provided by the extension.",
32 "name": "matchClassification",
33 "description": "The style ranges for the description, as provided by the extension.",
35 "offset": { "type": "integer" },
36 "type": { "description": "The style type", "type": "string", "enum": ["url", "match", "dim"]},
37 "length": { "type": "integer", "optional": true }
41 "descriptionStylesRaw": {
45 "description": "An array of style ranges for the description, as provided by ToValue().",
48 "name": "matchClassification",
49 "description": "The style ranges for the description, as provided by ToValue().",
51 "offset": { "type": "integer" },
52 "type": { "type": "integer" }
59 "id": "DefaultSuggestResult",
62 "description": "A suggest result.",
67 "description": "The text that is displayed in the URL dropdown. Can contain XML-style markup for styling. The supported tags are 'url' (for a literal URL), 'match' (for highlighting text that matched what the user's query), and 'dim' (for dim helper text). The styles can be nested, eg. <dim><match>dimmed match</match></dim>."
69 "descriptionStyles": {
73 "description": "An array of style ranges for the description, as provided by the extension.",
76 "name": "matchClassification",
77 "description": "The style ranges for the description, as provided by the extension.",
79 "offset": { "type": "integer" },
80 "type": { "description": "The style type", "type": "string", "enum": ["url", "match", "dim"]},
81 "length": { "type": "integer", "optional": true }
85 "descriptionStylesRaw": {
89 "description": "An array of style ranges for the description, as provided by ToValue().",
92 "name": "matchClassification",
93 "description": "The style ranges for the description, as provided by ToValue().",
95 "offset": { "type": "integer" },
96 "type": { "type": "integer" }
105 "name": "sendSuggestions",
108 "description": "A callback passed to the onInputChanged event used for sending suggestions back to the browser.",
110 {"type": "integer", "name": "requestId"},
112 "name": "suggestResults",
114 "description": "An array of suggest results",
116 "$ref": "SuggestResult"
122 "name": "setDefaultSuggestion",
124 "description": "Sets the description and styling for the default suggestion. The default suggestion is the text that is displayed in the first suggestion row underneath the URL bar.",
127 "name": "suggestion",
128 "$ref": "DefaultSuggestResult",
129 "description": "A partial SuggestResult object, without the 'content' parameter."
136 "name": "onInputStarted",
138 "description": "User has started a keyword input session by typing the extension's keyword. This is guaranteed to be sent exactly once per input session, and before any onInputChanged events.",
142 "name": "onInputChanged",
144 "description": "User has changed what is typed into the omnibox.",
153 "description": "A callback passed to the onInputChanged event used for sending suggestions back to the browser.",
156 "name": "suggestResults",
158 "description": "Array of suggest results",
160 "$ref": "SuggestResult"
168 "name": "onInputEntered",
170 "description": "User has accepted what is typed into the omnibox.",
177 "name": "disposition",
179 "enum": ["currentTab", "newForegroundTab", "newBackgroundTab"],
180 "description": "The window disposition for the omnibox query. This is the recommended context to display results. For example, if the omnibox command is to navigate to a certain URL, a disposition of 'newForegroundTab' means the navigation should take place in a new selected tab."
185 "name": "onInputCancelled",
187 "description": "User has ended the keyword input session without accepting the input.",