@linzjs/lui 17.17.0 → 17.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/dist/assets/svg-content.d.ts +4 -3
- package/dist/assets/svg-content.tsx +160 -4
- package/dist/components/LuiStaticMessage/LuiStaticMessage.d.ts +3 -2
- package/dist/index.js +5 -3
- package/dist/index.js.map +1 -1
- package/dist/lui.css +5 -4
- package/dist/lui.css.map +1 -1
- package/dist/lui.esm.js +5 -3
- package/dist/lui.esm.js.map +1 -1
- package/dist/scss/Components/Messaging/messaging.scss +4 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## [17.18.1](https://github.com/linz/lui/compare/v17.18.0...v17.18.1) (2022-10-17)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* resized toast icons and recoloured close x button ([#788](https://github.com/linz/lui/issues/788)) ([80990f7](https://github.com/linz/lui/commit/80990f71a8ca60c881423b196f7dd160dbf79d00))
|
|
7
|
+
|
|
8
|
+
# [17.18.0](https://github.com/linz/lui/compare/v17.17.0...v17.18.0) (2022-10-13)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* Added ability to overwrite icon displayed on LuiStaticMessage ([#784](https://github.com/linz/lui/issues/784)) ([86690d2](https://github.com/linz/lui/commit/86690d2504d0369c80e775f560ea596b7a37d4c1))
|
|
14
|
+
|
|
1
15
|
# [17.17.0](https://github.com/linz/lui/compare/v17.16.3...v17.17.0) (2022-10-13)
|
|
2
16
|
|
|
3
17
|
## [17.16.3](https://github.com/linz/lui/compare/v17.16.2...v17.16.3) (2022-10-12)
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
export declare type LuiIconName = string | 'ic_account_circle' | 'ic_add' | 'ic_add_adopt' | 'ic_add_area_interest' | 'ic_add_circle' | 'ic_add_circle_outline' | 'ic_add_irregular_image' | 'ic_add_multiple' | 'ic_add_to_list' | 'ic_annotations' | 'ic_apps' | 'ic_arrow_back' | 'ic_arrow_back_ios' | 'ic_arrow_drop_down' | 'ic_arrow_drop_right' | 'ic_arrow_drop_up' | 'ic_arrow_forward_ios' | 'ic_attach_file' | 'ic_attachment' | 'ic_auth_and_instruct' | 'ic_balance_parcel' | 'ic_blocked' | 'ic_border_color' | 'ic_cancel_clear' | 'ic_certify_and_sign' | 'ic_change_password' | 'ic_check' | 'ic_check_circle' | 'ic_check_circle_outline' | 'ic_checklist' | 'ic_clear' | 'ic_columns' | 'ic_control_point' | 'ic_copy' | 'ic_corporate_fare' | 'ic_create' | 'ic_delete_outline' | 'ic_delete_solid' | 'ic_dollar_round' | 'ic_double_arrow_left' | 'ic_double_arrow_right' | 'ic_double_tick' | 'ic_drag_handle' | 'ic_drag_indicator' | 'ic_draw_irregular_line' | 'ic_enabled_users' | 'ic_error' | 'ic_error_outline' | 'ic_expand_less' | 'ic_expand_more' | 'ic_feedback_lightbulb' | 'ic_feedback_lightbulb_alt' | 'ic_file_attached_outline' | 'ic_filter_list' | 'ic_flag' | 'ic_forward' | 'ic_fullscreen_frame' | 'ic_grid_view' | 'ic_history' | 'ic_hourglass' | 'ic_info' | 'ic_info_outline' | 'ic_insert_invitation' | 'ic_insert_photo' | 'ic_instruments_roles' | 'ic_keyboard_arrow_down' | 'ic_keyboard_arrow_left' | 'ic_keyboard_arrow_right' | 'ic_keyboard_arrow_up' | 'ic_launch_modal' | 'ic_launch_new window_open' | 'ic_layers' | 'ic_left_col' | 'ic_line_arc' | 'ic_line_irregular' | 'ic_line_vector' | 'ic_link' | 'ic_list_add' | 'ic_locate' | 'ic_lock' | 'ic_log_out' | 'ic_manage_adjust' | 'ic_maori_land' | 'ic_mark_linking' | 'ic_marks' | 'ic_menu' | 'ic_message_received' | 'ic_minimise' | 'ic_misclose_error' | 'ic_more_vert' | 'ic_navigate_before' | 'ic_navigate_next' | 'ic_note_add' | 'ic_notice_of_change' | 'ic_numbered_list' | 'ic_office_building_corporate' | 'ic_order_history' | 'ic_parcels_existing' | 'ic_parcels_new' | 'ic_pdf' | 'ic_pen_and_paper_sign' | 'ic_people_outline' | 'ic_person' | 'ic_person_add' | 'ic_picker' | 'ic_placeholder' | 'ic_polygon_selection' | 'ic_pop_back' | 'ic_pre_validation' | 'ic_product_list' | 'ic_publish' | 'ic_release' | 'ic_remove_circle' | 'ic_remove_circle_outline' | 'ic_request' | 'ic_requisitions' | 'ic_round_selection' | 'ic_save_download' | 'ic_saved_area_interest' | 'ic_search' | 'ic_send' | 'ic_send_email_dart' | 'ic_separator' | 'ic_square_selection' | 'ic_submit' | 'ic_survey' | 'ic_survey_report' | 'ic_ta_request_sent' | 'ic_table_columns' | 'ic_tax_statement' | 'ic_tick' | 'ic_tick_and_cross' | 'ic_timeline' | 'ic_title_allocation_swap' | 'ic_tune_setting_configure' | 'ic_unlink' | 'ic_upload' | 'ic_vector_sequence' | 'ic_view' | 'ic_view_list' | 'ic_view_quilt' | 'ic_view_sidebar' | 'ic_view_week' | 'ic_visiblity_off' | 'ic_warning' | 'ic_warning_outline' | 'ic_waves' | 'ic_whats_new_updates' | 'ic_xml_file' | 'ic_zoom_centre' | 'ic_zoom_out' | 'ic_zoom_previous';
|
|
3
|
+
declare type IconNameElementMap = {
|
|
4
|
+
[key in LuiIconName]?: JSX.Element;
|
|
5
|
+
};
|
|
5
6
|
export declare const ICONS: IconNameElementMap;
|
|
6
7
|
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// START OF GENERATED FILE
|
|
1
|
+
// START OF GENERATED FILE;
|
|
2
2
|
|
|
3
3
|
// NOTE: This is a generated file, nothing you do here matters
|
|
4
4
|
// The source of the all.svg file is located at './src/all.svg'
|
|
@@ -7,9 +7,165 @@
|
|
|
7
7
|
|
|
8
8
|
import React from 'react';
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
//add "string" as makes dynamically created icon names not require manual typing
|
|
11
|
+
export type LuiIconName =
|
|
12
|
+
| string
|
|
13
|
+
| 'ic_account_circle'
|
|
14
|
+
| 'ic_add'
|
|
15
|
+
| 'ic_add_adopt'
|
|
16
|
+
| 'ic_add_area_interest'
|
|
17
|
+
| 'ic_add_circle'
|
|
18
|
+
| 'ic_add_circle_outline'
|
|
19
|
+
| 'ic_add_irregular_image'
|
|
20
|
+
| 'ic_add_multiple'
|
|
21
|
+
| 'ic_add_to_list'
|
|
22
|
+
| 'ic_annotations'
|
|
23
|
+
| 'ic_apps'
|
|
24
|
+
| 'ic_arrow_back'
|
|
25
|
+
| 'ic_arrow_back_ios'
|
|
26
|
+
| 'ic_arrow_drop_down'
|
|
27
|
+
| 'ic_arrow_drop_right'
|
|
28
|
+
| 'ic_arrow_drop_up'
|
|
29
|
+
| 'ic_arrow_forward_ios'
|
|
30
|
+
| 'ic_attach_file'
|
|
31
|
+
| 'ic_attachment'
|
|
32
|
+
| 'ic_auth_and_instruct'
|
|
33
|
+
| 'ic_balance_parcel'
|
|
34
|
+
| 'ic_blocked'
|
|
35
|
+
| 'ic_border_color'
|
|
36
|
+
| 'ic_cancel_clear'
|
|
37
|
+
| 'ic_certify_and_sign'
|
|
38
|
+
| 'ic_change_password'
|
|
39
|
+
| 'ic_check'
|
|
40
|
+
| 'ic_check_circle'
|
|
41
|
+
| 'ic_check_circle_outline'
|
|
42
|
+
| 'ic_checklist'
|
|
43
|
+
| 'ic_clear'
|
|
44
|
+
| 'ic_columns'
|
|
45
|
+
| 'ic_control_point'
|
|
46
|
+
| 'ic_copy'
|
|
47
|
+
| 'ic_corporate_fare'
|
|
48
|
+
| 'ic_create'
|
|
49
|
+
| 'ic_delete_outline'
|
|
50
|
+
| 'ic_delete_solid'
|
|
51
|
+
| 'ic_dollar_round'
|
|
52
|
+
| 'ic_double_arrow_left'
|
|
53
|
+
| 'ic_double_arrow_right'
|
|
54
|
+
| 'ic_double_tick'
|
|
55
|
+
| 'ic_drag_handle'
|
|
56
|
+
| 'ic_drag_indicator'
|
|
57
|
+
| 'ic_draw_irregular_line'
|
|
58
|
+
| 'ic_enabled_users'
|
|
59
|
+
| 'ic_error'
|
|
60
|
+
| 'ic_error_outline'
|
|
61
|
+
| 'ic_expand_less'
|
|
62
|
+
| 'ic_expand_more'
|
|
63
|
+
| 'ic_feedback_lightbulb'
|
|
64
|
+
| 'ic_feedback_lightbulb_alt'
|
|
65
|
+
| 'ic_file_attached_outline'
|
|
66
|
+
| 'ic_filter_list'
|
|
67
|
+
| 'ic_flag'
|
|
68
|
+
| 'ic_forward'
|
|
69
|
+
| 'ic_fullscreen_frame'
|
|
70
|
+
| 'ic_grid_view'
|
|
71
|
+
| 'ic_history'
|
|
72
|
+
| 'ic_hourglass'
|
|
73
|
+
| 'ic_info'
|
|
74
|
+
| 'ic_info_outline'
|
|
75
|
+
| 'ic_insert_invitation'
|
|
76
|
+
| 'ic_insert_photo'
|
|
77
|
+
| 'ic_instruments_roles'
|
|
78
|
+
| 'ic_keyboard_arrow_down'
|
|
79
|
+
| 'ic_keyboard_arrow_left'
|
|
80
|
+
| 'ic_keyboard_arrow_right'
|
|
81
|
+
| 'ic_keyboard_arrow_up'
|
|
82
|
+
| 'ic_launch_modal'
|
|
83
|
+
| 'ic_launch_new window_open'
|
|
84
|
+
| 'ic_layers'
|
|
85
|
+
| 'ic_left_col'
|
|
86
|
+
| 'ic_line_arc'
|
|
87
|
+
| 'ic_line_irregular'
|
|
88
|
+
| 'ic_line_vector'
|
|
89
|
+
| 'ic_link'
|
|
90
|
+
| 'ic_list_add'
|
|
91
|
+
| 'ic_locate'
|
|
92
|
+
| 'ic_lock'
|
|
93
|
+
| 'ic_log_out'
|
|
94
|
+
| 'ic_manage_adjust'
|
|
95
|
+
| 'ic_maori_land'
|
|
96
|
+
| 'ic_mark_linking'
|
|
97
|
+
| 'ic_marks'
|
|
98
|
+
| 'ic_menu'
|
|
99
|
+
| 'ic_message_received'
|
|
100
|
+
| 'ic_minimise'
|
|
101
|
+
| 'ic_misclose_error'
|
|
102
|
+
| 'ic_more_vert'
|
|
103
|
+
| 'ic_navigate_before'
|
|
104
|
+
| 'ic_navigate_next'
|
|
105
|
+
| 'ic_note_add'
|
|
106
|
+
| 'ic_notice_of_change'
|
|
107
|
+
| 'ic_numbered_list'
|
|
108
|
+
| 'ic_office_building_corporate'
|
|
109
|
+
| 'ic_order_history'
|
|
110
|
+
| 'ic_parcels_existing'
|
|
111
|
+
| 'ic_parcels_new'
|
|
112
|
+
| 'ic_pdf'
|
|
113
|
+
| 'ic_pen_and_paper_sign'
|
|
114
|
+
| 'ic_people_outline'
|
|
115
|
+
| 'ic_person'
|
|
116
|
+
| 'ic_person_add'
|
|
117
|
+
| 'ic_picker'
|
|
118
|
+
| 'ic_placeholder'
|
|
119
|
+
| 'ic_polygon_selection'
|
|
120
|
+
| 'ic_pop_back'
|
|
121
|
+
| 'ic_pre_validation'
|
|
122
|
+
| 'ic_product_list'
|
|
123
|
+
| 'ic_publish'
|
|
124
|
+
| 'ic_release'
|
|
125
|
+
| 'ic_remove_circle'
|
|
126
|
+
| 'ic_remove_circle_outline'
|
|
127
|
+
| 'ic_request'
|
|
128
|
+
| 'ic_requisitions'
|
|
129
|
+
| 'ic_round_selection'
|
|
130
|
+
| 'ic_save_download'
|
|
131
|
+
| 'ic_saved_area_interest'
|
|
132
|
+
| 'ic_search'
|
|
133
|
+
| 'ic_send'
|
|
134
|
+
| 'ic_send_email_dart'
|
|
135
|
+
| 'ic_separator'
|
|
136
|
+
| 'ic_square_selection'
|
|
137
|
+
| 'ic_submit'
|
|
138
|
+
| 'ic_survey'
|
|
139
|
+
| 'ic_survey_report'
|
|
140
|
+
| 'ic_ta_request_sent'
|
|
141
|
+
| 'ic_table_columns'
|
|
142
|
+
| 'ic_tax_statement'
|
|
143
|
+
| 'ic_tick'
|
|
144
|
+
| 'ic_tick_and_cross'
|
|
145
|
+
| 'ic_timeline'
|
|
146
|
+
| 'ic_title_allocation_swap'
|
|
147
|
+
| 'ic_tune_setting_configure'
|
|
148
|
+
| 'ic_unlink'
|
|
149
|
+
| 'ic_upload'
|
|
150
|
+
| 'ic_vector_sequence'
|
|
151
|
+
| 'ic_view'
|
|
152
|
+
| 'ic_view_list'
|
|
153
|
+
| 'ic_view_quilt'
|
|
154
|
+
| 'ic_view_sidebar'
|
|
155
|
+
| 'ic_view_week'
|
|
156
|
+
| 'ic_visiblity_off'
|
|
157
|
+
| 'ic_warning'
|
|
158
|
+
| 'ic_warning_outline'
|
|
159
|
+
| 'ic_waves'
|
|
160
|
+
| 'ic_whats_new_updates'
|
|
161
|
+
| 'ic_xml_file'
|
|
162
|
+
| 'ic_zoom_centre'
|
|
163
|
+
| 'ic_zoom_out'
|
|
164
|
+
| 'ic_zoom_previous';
|
|
165
|
+
|
|
166
|
+
type IconNameElementMap = {
|
|
167
|
+
[key in LuiIconName]?: JSX.Element;
|
|
168
|
+
};
|
|
13
169
|
|
|
14
170
|
let iconMap: IconNameElementMap = {};
|
|
15
171
|
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
2
|
export interface ILuiStaticMessage {
|
|
3
3
|
level: 'success' | 'info' | 'warning' | 'error';
|
|
4
4
|
closable?: boolean;
|
|
5
|
+
icon?: string;
|
|
5
6
|
className?: string;
|
|
6
|
-
children?:
|
|
7
|
+
children?: ReactNode;
|
|
7
8
|
}
|
|
8
9
|
export declare const LuiStaticMessage: (props: ILuiStaticMessage) => JSX.Element;
|
package/dist/index.js
CHANGED
|
@@ -157,7 +157,7 @@ function __spreadArray(to, from, pack) {
|
|
|
157
157
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
158
158
|
}
|
|
159
159
|
|
|
160
|
-
// START OF GENERATED FILE
|
|
160
|
+
// START OF GENERATED FILE;
|
|
161
161
|
var iconMap = {};
|
|
162
162
|
// @TODO This is a generated file, nothing is safe.
|
|
163
163
|
iconMap['ic_account_circle'] = (React__default["default"].createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24" },
|
|
@@ -528,9 +528,11 @@ var LuiBannerContent = function (props) {
|
|
|
528
528
|
|
|
529
529
|
var LuiStaticMessage = function (props) {
|
|
530
530
|
var _a = React.useState(true), display = _a[0], setDisplay = _a[1];
|
|
531
|
-
var
|
|
531
|
+
var iconName = props.icon
|
|
532
|
+
? props.icon
|
|
533
|
+
: "ic_".concat(getMaterialIconForLevel(props.level));
|
|
532
534
|
return display ? (React__default["default"].createElement("div", { className: clsx("lui-msg-".concat(props.level), props.className), "data-testid": 'static-message-container' },
|
|
533
|
-
React__default["default"].createElement(LuiIcon, { name:
|
|
535
|
+
React__default["default"].createElement(LuiIcon, { name: iconName, alt: "".concat(props.level, " static icon"), size: "lg", className: "lui-msg-status-icon" }),
|
|
534
536
|
props.children,
|
|
535
537
|
(props.closable === undefined || props.closable) && (React__default["default"].createElement("button", { "aria-label": "Close dialog", onClick: function () {
|
|
536
538
|
setDisplay(false);
|